Skip to content

An end-to-end application to engage music fans by recommending select number of songs based on user’s song preference

Notifications You must be signed in to change notification settings

johnnychiuchiu/Music-Recommender

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

83 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Music-Recommender

license

Project Charter

The goal of the project is to build a music recommender application from scratch.

  • Vision: Engage music fans by recommending select number of songs based on user’s song and genre preference.
  • Mission: The goal of the project is to help people discover the music they may enjoy by providing them a list of recommended songs according to their favorite musicians and songs. This will be done using a collaborative filtering or a latent factor recommender model that is trained with the Million Song Dataset.
  • SuccessCriteria: Successfully deployed a web application that dynamically shows a recommended list of songs according to users’ input.

For this project, we used Pivotal Tracker, an Agile Project Management Software, to keep track of the overall progress. The pivotal tracker page for this project can be reached by clicking on this link.

Suggested steps to deploy app

  1. Clone repository.

  2. Use conda to create virtual environment

    > Music-Recommender$ conda create -n musicproject python=3
    > Music-Recommender$ source activate musicproject
    
  3. Install required packages

    > (musicproject) Music-Recommender$ pip install -r requirements.txt
    
  4. Set up music.env file with the following structure

    export DATABASE_URL=XXX
    export HOST=XXX    
    export USER=XXX
    export PASSWORD=XXX
    export DBNAME=XXX    
    export PORT=XXX
    
  5. Set environment variables from file

    source music.env
    
  6. Get data and save it into your mySQL database

    > (musicproject) Music-Recommender$ cd src/database   
    > (musicproject) database$ python create_db.py  
    > (musicproject) database$ python insert_data.py
    

    Note that the data is downloaded from the url provided by the company Turi using the following two hyperlinks. Download User Listening History Data and Download Song Meta Data.

  7. (OPTIONAL) If you want to run unit tests before launch the application, run the following commands:

    > (musicproject) Music-Recommender$ cd test/
    > (musicproject) Music-Recommender$ pytest
    > (musicproject) Music-Recommender$ cd ..   
    
  8. Launch the application

    > (musicproject) Music-Recommender$ python application.py
    

Application Screenshot

Documentation

  • modelSelectionAndTuning.ipynb: Jupyter Notebook that contains a walkthrough of the overall model building, model selection and parameter tuning. [jupyter notebook]

  • latentFactorModel.ipynb: An old version of the overall model building process. [jupyter notebook]

  • Step by step guide for database, environment and sphinx documentation set up. [Github Wiki]

  • You can find the slides for this project here.

Project Organization

├── LICENSE
│
├── README.md          <- The top-level README for developers using this project.
│    
├── requirements.txt   <- The requirements file for reproducing the analysis environment, e.g. generated with `pip freeze > requirements.txt`               
│
├── pic                <- some picture for demo purpose
│
├── web                <- HTML and CSS files
│    
├── form               <- user form selection files
│   
├── data               <- Data files
│
├── src                <- Source code for use in this project.
│   ├── __init__.py    <- Makes src a Python module
│   │
│   ├── database       <- Scripts to download and generate data
│   │
│   ├── models         <- Scripts to train models and then use trained models to make predictions
│   │
│   └── notebooks      <- Jupyter notebooks. Used to reate exploratory, results oriented visualizations,  and parameter tuning                     
├── docs               <- A default Sphinx project; see sphinx-doc.org for details
│  
├── test               <- Unit tests
│  
├── log                <- Logging files

About

An end-to-end application to engage music fans by recommending select number of songs based on user’s song preference

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published