Chris Shyi
c518556126
Draw audio feature bar charts
Started work on drawing the bar charts for audio features.
7 years ago
Kevin Mok
05b5cc404a
Trying to get correct artist breakdown in genres
Counts are off since there are multiple artists on a track.
7 years ago
Chris Shyi
4698663a85
Rewrite generate_random_string()
Rewrote generate_random_string() in a more Pythonic fashion.
7 years ago
Chris Shyi
3e35e52f45
Retrieve audio feature data from frontend
Added user_secret field to User. Set up a basic JavaScript function for
querying audio feature data from the frontend.
7 years ago
Chris Shyi
9d43048067
Clean up views.py and utils.py further
views.py and utils.py were cleaned up further to remove any obsolete usage of
library_stats.
7 years ago
Kevin Mok
ea5990d048
Fixed duplicate key error in save_track_obj
Can't create Track object without the artists/user so get_or_create
doesn't work properly.
7 years ago
Chris Shyi
797115e9cb
Clean up utils.py to use database
Uses of the original library_stats dictionary in utils.py were either removed or commented out, replaced by the saving of models into the database.
7 years ago
Kevin Mok
79aedc655d
Trying to pass artist data from db to frontend
7 years ago
Kevin Mok
cdcc33c014
Setup Track table, modified models to data
Recreated migrations from scratch to fix bug with initializing Track
objects.
7 years ago
Chris Shyi
27718743d7
Change artists field in Track
artists is now a ManyToManyField in Track, which is cleaner than
using a unique_together clause in the Meta class.
7 years ago
Chris Shyi
b735887899
Bug fixes
Server crashes as of the last commit, now fixed.
7 years ago
Kevin Mok
549af96db7
Setup Artist table
Removed printing of library_stats.
7 years ago
Chris Shyi
248e9b0ab6
Change database settings
Edited settings.py to use PostgreSQL. Made some minor changes
in views.py to incorporate the new models.
7 years ago
Kevin Mok
e07fd0965a
Added Vim folds to models.py and utils.py
7 years ago
Kevin Mok
c831e5b9a8
Initial design for database
Before considering Django models.
7 years ago
Chris Shyi
e01331f951
Process library_stats
library_stats is now processed into a format that's more easily consumed
by D3. Need to finalize format for popularity data.
7 years ago
Chris Shyi
46df571855
Compute the average and std_dev for popularity
Modified the structure and code in utils.py so that library_stats now
has a record of the mean and standard deviation of popularity.
7 years ago
Chris Shyi
c9de0395a4
Refactor helper functions in views.py
Refactored helper functions in views.py into utils.py. Instead of having
a global dictionary object for user library data, helper functions now
mutate a dictionary passed in as a parameter.
7 years ago
Kevin Mok
96b7bfb2bb
Display genre counts on user_data page
Able to pass dict info successfully from backend to webpage.
7 years ago
Chris Shyi
4b263532d1
Added missing space on line #222
7 years ago
Kevin Mok
6e1671b0f2
Fixed improper retrieval of value from API JSON
7 years ago
Chris Shyi
ec3fb3f959
Fix get_audio_features() bug
Fixed bug where the parameters passed in the wrong order for
get_audio_features().
7 years ago
Chris Shyi
4066c96c94
Changed signature of get_audio_features() for consistency
Switched around the ordering of the parameters so that they are
consistent with other data acquisition helper functions.
7 years ago
Chris Shyi
a5780387e1
Made minor changes to variable names
7 years ago
Chris Shyi
d7002f7571
Implement audio feature statistics calculation
Implemented the calculation average and standard deviation of audio features.
7 years ago
Chris Shyi
bbc713e729
Implement audio feature helper functions
Implemented helper functions for updating audio feature statistics.
7 years ago
Chris Shyi
7b153649bf
Implement online standard deviation algorithm
Implemented Welford's method for calculating standard deviation as data
points arrive.
7 years ago
Kevin Mok
f94a861b84
Calculate genre counts once for each artist ( #1 )
Versus last commit that incremented genres every track. Also now only
stores ID for artist rather than all their genres.
7 years ago
Kevin Mok
cb75a0b2bb
Implemented get_genre functionality ( #1 )
Code actually in increase_artist_count. Updates genre counts with
each track from the artist.
7 years ago
Kevin Mok
0ca846805c
Wrote parse_library and get_track_info ( #1 )
Initialized library_stats with top-level keys and default values.
7 years ago
Chris Shyi
41eca1c891
Get soundtrack musical features
Implemented get_features() to retrieve musical features for soundtracks
7 years ago
Chris
bf65ae3f4d
Use different URI for user data
The user_data page is now located at /user_data, instead of /callback as
before. Closes #7 .
7 years ago
Chris
c0fe7a61af
Implement User Login
Closes #6 . User can now log in and be redirected to a data display
page(needs to be fleshed out).
7 years ago
Chris
588fc4bfc0
datetime object not JSON serializable
Fixed error where a datetime object cannot be stored in request.sessions
as it was not JSON serializable.
7 years ago
Chris
a96f429691
Obtain tokens from Spotify
Code now successfully obtains tokens from the Spotify API.
7 years ago
Chris
ef5c3b2647
Implement User Authorization
Completed step 1 of the Authorization Code Flow documented by the
Spotify API.
7 years ago
Chris
1f63c2d2e7
Initial commit
Sets up basic Django app directory structure.
7 years ago