Skip to content
This repository has been archived by the owner on Jul 14, 2021. It is now read-only.

theblackcat102/yt_trending_backend

Repository files navigation

Visualize the trending tags from youtube trending list across 30+ countries

This is the backend service serving the final visualization. You can check out the frontend youtube-viz-demo

Setup

This project is setup using fastapi and served using uvicorn. Data uses Peewee ORM with Postgresql 10.

you need to create a config file .env in the root path with the following fields:

DATABASE="DB_NAME"
DB_USER="DB_USER"
HOST="DB_IP_ADDRESS"
PORT="DB_PORT"
PASSWORD="DB_PASSWORD"

Then setup the environment and you

virtualenv -p python3 env
source env/bin/activate
pip install -r requirements.txt

Initialize the database table

python models.py

you may also want to execute the fn.sql and setup.sql if you want to speed things up such as keyword search etc

This backend also relies on fuzzystrmatch extension for finding similar tags.

Once you have populate the table with data you can run the server using this command

uvicorn main:app

Here's some showcase of the final visualization results

Landing page

Race chart

Tag Header page

Tag Stats

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published