Music Suggestion System
CS 250 Final Project
Matt Jones, Travis Thomas, Xingbang Liu
suggestions flickr photo by Jurgen Appelo shared under a Creative Commons (BY) license
Motivation
Why Music Suggestion System?
- Build off of previous labs
- Spotify & Pandora
Algorithms
Collaborative filtering
- Memory-based
$$cos(A) = \frac{\vec a \cdot \vec b} {|\vec a| \times |\vec b|}$$
- Model-based
$$R_{user,song}= Q_{user,factor} P^T_{factor,song}$$
Background/Overview
Repository structure overview
Like List
Explore
- Store our Cloud list (music.csv) into a 2D ArrayList
- song<>(String) in exploreSongs<>(String)
- randomly pick 5 songs
- if user likes, then update "y" (in music.csv) by using BufferedWriter
- add line to liked.csv by using FileWriter
Music Suggestion
- Not done yet
- Melody score (1-10 representing speed)
- Calculate mean score from liked.csv
- Linear search in music.csv
- Randomly select 2 songs
Math Evaluation
- By running
System.nanoTime()
four times, I got:
in nano seconds | bubble sort | exchange sort |
1. | 186,525 | 106,856 |
2. | 156,695 | 111,009 |
3. | 156,318 | 110,631 |
4. | 239,386 | 110,254 |
mean | 184,731 | 109,688 |
- $$O(n^{2})$$
Conclusion
- Making good progress
- inheritance
- Biggest Challenge - Overwriting Y in the music.csv
2d arrayList, Test.csv