This project implements a Shazam-like music recognition application using Python. The application processes sound files to generate spectrograms and fingerprints, then matches them to a repository of songs. The key features include:
-
Spectrogram Generation: Given any sound file (either song, vocals, or music), the program generates its spectrogram for the first 30 seconds.
-
Feature Extraction: The application extracts key features from each spectrogram and hashes them using perceptual hash functions to create a unique fingerprint for each song.
-
Song Matching: The application compares the fingerprint of an input file to the repository and lists the closest matches with a similarity index in a sorted table displayed in the GUI.
-
Weighted File Combination: The user can select two files and create a weighted average of them. The new file is then treated as a new sound input, and the closest songs are found based on the new fingerprint.
- Spectrogram Analysis: The program generates spectrograms for full songs, music-only, and vocals-only files.
- Feature Hashing: Extracted features are hashed into a shorter sequence using perceptual hash functions.
- Similarity Index: The application calculates a similarity index between the input file and repository songs.
- Weighted Average: Allows weighted combination of two files, enabling the generation of new audio inputs.
- Graphical User Interface (GUI): A user-friendly interface that displays results in a sortable table.
Demo.video.mp4
-
Clone the repository:
git clone https://github.com/yourusername/shazam-app.git
-
Navigate to the project directory:
cd shazam-app
-
Install the required dependencies:
pip install -r requirements.txt
-
Run the application:
python app.py
-
Upload a sound file to generate its spectrogram and find the closest matches.
-
Use the slider to create a weighted average of two selected files and search for similar songs.
This project is licensed under the MIT License. See the LICENSE file for details.