This is a song listening and music recognition project based on audio fingerprint algorithm.


First of all, you should have installed MySql software, Python version 3.7 and pip.

pip install numpy termcolor pyaudio wave pydub librosa pymysql matplotlib

How to use

There are two steps : database building and query. The songs used for database building are placed in the dataset / key directory, and the songs queried and predicted are placed in the dataset / query directory. In addition, you can also run record_ file to record music clips and save them to dataset / record_music and predict them.

  1. Run to initialize your database
  1. Run to get the result of music recognition
  1. Done!


This project provides multi-threaded running mode. If you want to speed up library building and song prediction, please run and

How is it work

This project is to implement the algorithm in <>. This paper is placed in the referPaper directory.


  • Python 3.7
  • numpy
  • termcolor
  • wave
  • pydub
  • pyaudio
  • librosa
  • pymysql
  • matplotlib
  • MySql software and workbench


  • if you want to contribute to codes, create pull request.
  • if you find any bugs or error, create an issue.


This project is licensed under the GNU GPLv3 License


View Github