By Rayyan Shaik, Esther Amao, Helen Nguyen
Our Neural Network's results:
- Accuracy: 68%
- F1 Scores: 48%, 77%, 0% for classes 0, 1 and 2 respectively
This repository contains the code required to scrape the following:
- List of pops songs (names & artists) by year
- Lyrics and lyrics meta-data per song
- Weekly streaming data (global & US) per song
- selenium
- lyricsgenius
- python-dotenv
- Genius API Key required
-
Simplying running
main.py
viapy main.py
orpython3 main.py
should be sufficient to begin a general scrape -
In
main.py
you can adjust theyears
variable range to change the range of years queried (if playlists within the range exist). -
All scraping functions run their own data-cleaning utilities ensure all the data is standardized and usable
- Run the file
song_scraper.py
- Adjust the variable
year_range
to scrape the desired range of playlists for songs
- Adjust the variable
- Run the file
lyrics_scraper.py
config['TOKEN']
needs to be set to your Genius.com API key
- Run the file
spotify_plays_scraper.py