Metadata-Version: 2.1
Name: socialysis
Version: 0.0.0
Summary: Tool for analyzing and extracting insights from Facebook Messenger conversations
Home-page: https://github.com/abdulrahmankhayal/socialysis
Author: Abdul-Rahman Khayyal
License: MIT
Platform: UNKNOWN
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Operating System :: OS Independent
Description-Content-Type: text/markdown
Requires-Dist: arabic-reshaper
Requires-Dist: emoji
Requires-Dist: imojify
Requires-Dist: librosa
Requires-Dist: matplotlib
Requires-Dist: numpy
Requires-Dist: opencv-python
Requires-Dist: pandas (>=1.4.1)
Requires-Dist: Pillow
Requires-Dist: python-bidi
Requires-Dist: regex
Requires-Dist: tldextract
Requires-Dist: tqdm
Requires-Dist: wordcloud

# IMOJIFY



a python library that maps almost every emoji to its color image

it's used to get visual representation of emoji unicode



imojify can be used to solve the problem of plotting emojis as labels in python plotting libraries



## Installation



    `pip install imojify`



## Quickstart



### Get emoji Image



```python

from PIL import Image

from imojify import imojify

Image.open(imojify.get_img_path('😂'))

```

![output](https://raw.githubusercontent.com/abdulrahmankhayal/imojify/main/media/emoji.png)







multiple emoji is also supported 



```python

from PIL import Image

from imojify import imojify

Image.open(imojify.get_img_path('😂😂😂😂'))

```

![output](https://raw.githubusercontent.com/abdulrahmankhayal/imojify/main/media/Mulit_emoji.png)







### Plotting emojis in matplotlib



```python

from imojify import imojify

from matplotlib import pyplot as plt 

from matplotlib.offsetbox import OffsetImage,AnnotationBbox

def offset_image(cords, emoji, ax):

    img = plt.imread(imojify.get_img_path(emoji))

    im = OffsetImage(img, zoom=0.08)

    im.image.axes = ax

    ab = AnnotationBbox(im, (cords[0], cords[1]),  frameon=False, pad=0)

    ax.add_artist(ab)







emjis = ['😂', '🤣', '😔', '😏','😍', '🥰', '😘']

values =[30, 50, 15, 29, 15, 50, 12]



fig, ax = plt.subplots(figsize=(12,8))

ax.bar(range(len(emjis)), values, width=0.5,align="center")

ax.set_xticks(range(len(emjis)))

ax.set_xticklabels([])

ax.tick_params(axis='x', which='major', pad=26)

ax.set_ylim((0, ax.get_ylim()[1]+10))



for i, e in enumerate(emjis):

    offset_image([i,values[i]+5], e, ax)

```

![output](https://raw.githubusercontent.com/abdulrahmankhayal/imojify/main/media/plt_emoji.png)





