Giter Site home page Giter Site logo

melissab1238 / ubcgrades-dash Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 2.44 MB

Jan 2023: Recreating ubcgrades.com using (python) plotly's dash and incorportating genAI chat to data analysis.

Jupyter Notebook 95.63% Python 4.29% Dockerfile 0.08%
generativeai openai pandasai plotly plotly-dash ubc

ubcgrades-dash's Introduction

UBC Grades - Dash

Building off of the original incredible ubcgrades.com project, I am utilizing Plotly's Dash system to analyze and visualize UBC grade data with less code.

Data sources

From the ubcgrades.com API, I can receive grades distributions as json objects, then transform them into dataframes for python and plotly to manage.

For example https://ubcgrades.com/api/v3/grades/UBCV/2022S

Docker-dash

Instructions from docker-dash...

Build and run

prod version is served by gunicorn instead of the flask dev server.

# dev
docker build -f Dockerfile.dev -t ubcdash-dev .
docker run -p 8050:8050 -v "$(pwd)"/app:/app --rm ubcdash-dev

# prod
docker build -f Dockerfile -t ubcdash-prod .
docker run -p 8050:8050 -v "$(pwd)"/app:/app --rm ubcdash-prod

Access the page

Go to http://localhost:8050 in browser.

Switch debug mode in Dockerfile

ENV DASH_DEBUG_MODE True # False

Development

Install the app requirements for development to get better editor support.

poetry install

Optional: clean initialization of poetry:

poetry init
cat app/requirements.txt | xargs poetry add

Playground jupyter notebook

see my playground jupyter notebook for current progress

Screenshots

Example output 2

Future developments

  • tidy up imports with requirements.txt
  • create a dash app mvp
  • showcase sample plotly charts in screenshots
  • refine openai outputs
  • create dash app with charts that match what is currently on ubcgrades.com
  • find/make a chatgpt interface on dash
  • improve markdown on ipynb file
  • separate out helper functions
  • improve UI of charts
  • host application and database and functions on the cloud. Ex: GCP Cloud Run, Cloud Store, Cloud Functions. Or Render.com. Docker image would be great too.

Curent priorities

  • filter dropdowns
  • show "OVERALL" section by defaul
  • year x axis only has 3 options 2021, 2022, 2023. Not 2021.5
  • capitalize labels (axis, legend)
  • give larger marker to the "OVERALL" vs the sections - not sure if this is possible (conditional markers)

Questions I'd like to be able to answer

  • SELECT campus, subject, course where average > 90
  • questions: what courses in 3rd and 4th year can I take that have the highest average?
  • what courses have the lowest fail rate? (<50 or <55%)
  • how do grades compare between sections of the same class?
  • how do grades compare between profs over the years/classes?
  • does class size influence grades?
  • what subjects (CPSC, MATH, etc) have the highest averages?
  • what MATH 1xx courses have the highest and lowest averages?

ubcgrades-dash's People

Contributors

melissab1238 avatar

Watchers

 avatar

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.