Skip to content
Know the gender of your Instagram followers!
Python HTML JavaScript
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
adab
app
data
naive_bayes
screenshots
svm
thirdparty/InstagramAPI
xgb
.gitignore
LICENSE.md
README.md
cache.py
progress.py
requirements.txt

README.md

Follower Gender Classifier

🏡
Know the gender of your followers!
A project to support my thesis.

Introduction

The goal is to determine how many of your Instagram follower(s) are male/female.

Consist of several parts:

  • The frontend built with socketio, flask, html & javascript
  • and 4 different implementation of classifier algorithm: xgboost, support vector machine, naive bayes, and adaboost

Quick Repository Overview

adab/

Implementing AdaBoost using sklearn library.

app/

Main entrypoint for the Flask application (this project).

data/

Data dump(s) or saved pickle files.

screenshots/

You know... screenshots.

naive_bayes/

Implementing naive bayes algorithm using nltk library.

svm

Implementing Support Vector Machine algorithm using sklearn library.

thirdparty/

Third-party related library supporting this project.

xgb

Implementing eXtreme gradient boosting algorithm using xgboost library.

Screenshot

screenshot1

Getting Started

export IG_USERNAME=
export IG_PASSWORD=

# To limit the number of processed comments data:
#   follower_limit x media_per_follower x comments_per_media
#
# Defaults to 5000
export COMPUTE_THRESHOLD=

Assuming you have virtualenv and python3-pip installed:

  • virtualenv venv && source venv/bin/activate
  • pip3 install -r requirements.txt
  • Get into python3 interactive mode and run:
Python 3.5.2 (default, Nov 12 2018, 13:43:14)
[GCC 5.4.0 20160609] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import nltk
>>> nltk.download('punkt')
[nltk_data] Downloading package punkt to /home/william/nltk_data...
[nltk_data]   Unzipping tokenizers/punkt.zip.
True
  • cd app && python3 app.py
$ python3 app.py -h
usage: app.py [-h] [-p PORT] [-o HOST] [-d] [-e ENV] [-s SECRET]

optional arguments:
  -h, --help            show this help message and exit
  -p PORT, --port PORT  specifies the port to listen on
  -o HOST, --host HOST  specifies the interface address to listen on
  -d, --debug           specifies the debug mode
  -e ENV, --env ENV     specifies the env for flask to run
  -s SECRET, --secret SECRET
                        specifies the session secret key

Python Version

$ python --version
Python 3.7.1

Contributing

Pull requests for new features, bug fixes, and suggestions are welcome!

License

GNU General Public License v3.0

You can’t perform that action at this time.