How can I Compare 2 Audio Files Programmatically?

后端 未结 7 1649
误落风尘
误落风尘 2020-12-12 17:18

I want to compare 2 audio files programmatically. For example: I have a sound file in my iPhone app, and then I record another one. I want to check if the existing sound mat

相关标签:
7条回答
  • 2020-12-12 17:51

    That's called Audio Fingerprinting. There exist some open source projects from which you can get some ideas. Take a look here: Audio Fingerprint - MusicBrainz.

    0 讨论(0)
  • 2020-12-12 17:55

    I know the question has been asked a long time ago, but a clear answer could help someone else.

    1. The libraries from Echoprint ( website: echoprint.me/start ) will help you solve the following problems :

      • De-duplicate a big collection
      • Identify (Track, Artist ...) a song on a hard drive or on a server
      • Run an Echoprint server with your data
      • Identify a song on an iOS device

      PS: For more music-oriented features, you can check the list of APIs here.

    2. If you want to implement Fingerprinting by yourself, you should read the docs listed as references here, and probably have a look at musicip-libofa on Google Code

    Hope this will help ;)

    0 讨论(0)
  • 2020-12-12 17:55

    I got interested and i found another solution in Java over sourge forge. yo can retrieve the code from SVN.

    http://sourceforge.net/projects/comparisong/

    give it a look and let me know if it worked for you.

    cheers

    0 讨论(0)
  • 2020-12-12 17:59

    Sounds like Shazam might help.

    There are a few articles on the web talking about this, including this one that I read a while ago.

    Using the Shazam technique for analysis would provide a great starting point for side-by-side comparison.

    0 讨论(0)
  • 2020-12-12 18:02

    Have a server doing audio fingerprinting computation that is not suitable for mobile device anyway. And then your mobile app uploads your files to the server and gets the analysis result for display. So I don't think programming language implementing it matters much. Following are a few AF implementations.

    Java: http://www.redcode.nl/blog/2010/06/creating-shazam-in-java/

    VC++: http://code.google.com/p/musicip-libofa/

    c#: http://www.codeproject.com/KB/WPF/duplicates.aspx

    0 讨论(0)
  • 2020-12-12 18:14
    • Apply bandpass filter to reduce noise
    • Normalize for amplitude
    • Calculate the cross-correlation

    It can be fairly Mhz intensive.

    The DSP details are in the well known text:

    • Digital Signal Processing by Alan V. Oppenheim and Ronald W. Schafer
    0 讨论(0)
提交回复
热议问题