A music recommendation system
Project description
MUSIC_RECOMMENDATION
A music recommendation system using Spotify's API and cosine similarity to suggest songs based on a user's chosen track.
Features
- Fetches top 50 tracks from Spotify Japan Weekly Ranking
- Analyzes track features such as danceability, energy, loudness, etc.
- Recommends similar tracks based on cosine similarity
Installation
-
Clone the repository:
git clone https://github.com/sayamiyaji/MUSIC_RECOMMENDATION.git cd MUSIC_RECOMMENDATION
-
Create a virtual environment and activate it:
python -m venv music source music/bin/activate
-
Install the required packages:
pip install -r requirements.txt
Usage
-
Set up your Spotify API credentials:
- Create an application on the Spotify Developer Dashboard
- Obtain your
client_idandclient_secret
-
Export your Spotify API credentials:
export SPOTIPY_CLIENT_ID='your_client_id' export SPOTIPY_CLIENT_SECRET='your_client_secret' export SPOTIPY_REDIRECT_URI='http://localhost:8080'
-
Run the web application:
python -m your_project.app
-
Open your web browser and go to
http://localhost:5000
Project Structure
music-recommendation/ ├── data/ # データ保存用 ├── notebooks/ # Jupyter Notebooks用 ├── src/ # ソースコード │ ├── init.py │ └── recommender.py ├── requirements.txt # 必要なパッケージリスト └── README.md # プロジェクト説明
Contributing
- Fork the repository
- Create a new branch (
git checkout -b feature-foo) - Commit your changes (
git commit -am 'Add some foo') - Push to the branch (
git push origin feature-foo) - Create a new Pull Request
License
This project is licensed under the MIT License - see the LICENSE file for details.
Acknowledgements
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file MUSIC_RECOMMENDATION-0.1.0.tar.gz.
File metadata
- Download URL: MUSIC_RECOMMENDATION-0.1.0.tar.gz
- Upload date:
- Size: 4.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.9.16
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f868e28af75cd93fb7372a2d3e75f3e1a8ad3ad815cc0f4ff5b36076db4464e3
|
|
| MD5 |
a919b2a8d18a7ace6f10b107ceef4142
|
|
| BLAKE2b-256 |
25c4278e843e03a1a9204d07a7b556a2146ecc5fe603d13c90d76d4556b526f0
|
File details
Details for the file MUSIC_RECOMMENDATION-0.1.0-py3-none-any.whl.
File metadata
- Download URL: MUSIC_RECOMMENDATION-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.9.16
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7d2a924fd0c7c06e984ae6b51e1a835ff4bf965ca839c462595993a044a427f4
|
|
| MD5 |
faa752733f39b926165ccfc670c4cbb5
|
|
| BLAKE2b-256 |
08486794571e28bedfcfbaab24628b9a745228fb4b8d3bd3dd124329bcda2224
|