MemeDensity Save

:trollface: CLI tool to let you know amount of memes in facebook feed.

Project README

M E M E   D E N S I T Y

Tells you the approximate amount of memes in your facebook newsfeed.

alt tag

Preface

Since April 2016, Facebook has been automatically adding alt tags to all images with keywords representing the content of the images:

<img csrc="https://facebook.com/some-url.jpg"
alt="Image may contain: golf, grass, outdoor and nature"
width="316" height="237">

They are labeling the images using a Deep ConvNet built by Facebook's FAIR team team.

On one hand, this is really great. It improves accessibility for blind users who depend on screen readers which are only capable of processing text. But raises privacy concerns too.

Thank you ageitgey for originally finding out about this.
Anyhow, this script uses this addition by Facebook to it's advantage. MemeDensity reads alt tags of the images in your newsfeed and lets you know the quantity of memes on your feed.
Since Facebook doesn't directly allow fetching the newsfeed from its API, this script uses Selenium and PhantomJS to simulate a surf through the newsfeed.

Dependencies

PhantomJS or any other webdriver.

MacOS

brew install phantomjs

Linux

sudo apt-get install phantomjs

Windows

Download and set in environment variables

Installing

From Source:

Check out the latest release

or
$ git clone https://github.com/kalbhor/MemeDensity
$ cd MemeDensity
$ python setup.py install

From PyPI:

$ pip install memedensity

If you'll be using a different webdriver (Not PhantomJS), simply edit MemeDensity/command_line.py and add your webdriver

driver = webdriver.PhantomJS()

Options

optional arguments:
  -h, --help            show this help message and exit
  -C, --count           How many times to scroll newsfeed (default = 5)
  -L, --login           Input login credentials
  -v, --verbose         Shows meme urls

Usage

$ memedensity

Contributing

Currently this project is in its infancy and issues are bound to arise. If the script throws an exception, please make sure to check your running processes to see whether the webdriver has been closed or not. To contribute, post issues without hesitation and open pull requests to add/improve features.

License

MIT

Open Source Agenda is not affiliated with "MemeDensity" Project. README Source: kalbhor/MemeDensity
Stars
44
Open Issues
1
Last Commit
7 years ago
Repository
License
MIT

Open Source Agenda Badge

Open Source Agenda Rating