GithubHelp home page GithubHelp logo

alanzchen / nosedive Goto Github PK

View Code? Open in Web Editor NEW
8.0 5.0 6.0 25 KB

Calculate your Nosedive rating based on your Facebook profile - Inspired by Black Mirror S03E01

License: GNU General Public License v3.0

Python 28.27% CSS 26.11% JavaScript 11.80% HTML 33.82%
parody python flask facebook score reactions rating blackmirror

nosedive's Introduction

Nosedive - Inspired by Black Mirror S03E01

The website Nosedive is a parody of Black Mirror S03E01 Nosedive. It calculates a Nosedive rating based on your history on Facebook.

How Does It Work?

It grabs a user's posts and reactions thereof to calculate his/her rating. The Nosedive rating consists of two parts:

  1. The base score: the popularity of the user. Since the "reaction" on Facebook is neutral, there is no way to get an inference of a numerical rate merely from the "reactions" from a post. Therefore, it uses popularity as an approximation of the "rating" concept in the show.
  2. The bonus score: high-rate-user effect. In the show, the higher the rating of your friend is, the more powerful he/she is. It would be cumbersome to recursively calculate a complete Nosedive rating. In the implementation, it takes the base score as the weight of a user.

See the implementation in algorithm.py.

Privacy

You can check algorithm.py to see attributes it stores in the database.

If you have any concern, there is a way to remove your data: simply call /remove/your_id with a valid access token and your data will be removed from the database.

Credits

The main front-end is taken from Ahmed Tarek (http://codepen.io/ahmedtarek2134/pen/ggYmXp).

The odometer is taken from Benjamin (http://codepen.io/maggiben/pen/nmIso).

Everything else is licensed under GPLv3 License unless stated elsewhere.

nosedive's People

Contributors

alanzchen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

nosedive's Issues

Invalid response from facebook

Hey after accept Facebook login popup I get this

[2017-02-03 18:05:48,035] ERROR in app: Exception on /login/authorized [GET]
Traceback (most recent call last):
  File "/Applications/MAMP/www/nosedive/venv/lib/python2.7/site-packages/flask/app.py", line 1982, in wsgi_app
    response = self.full_dispatch_request()
  File "/Applications/MAMP/www/nosedive/venv/lib/python2.7/site-packages/flask/app.py", line 1614, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/Applications/MAMP/www/nosedive/venv/lib/python2.7/site-packages/flask/app.py", line 1517, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/Applications/MAMP/www/nosedive/venv/lib/python2.7/site-packages/flask/app.py", line 1612, in full_dispatch_request
    rv = self.dispatch_request()
  File "/Applications/MAMP/www/nosedive/venv/lib/python2.7/site-packages/flask/app.py", line 1598, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/Applications/MAMP/www/nosedive/venv/lib/python2.7/site-packages/flask_oauth.py", line 429, in decorated
    data = self.handle_oauth2_response()
  File "/Applications/MAMP/www/nosedive/venv/lib/python2.7/site-packages/flask_oauth.py", line 407, in handle_oauth2_response
    type='invalid_response', data=data)
OAuthException: Invalid response from facebook
Invalid response from facebook

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.