Many of you will be aware of the mobile application called Shazam, which allows your phone to identify nearly any song playing in close vicinity. Incredibly, we often get into deep chats about how Shazam works, never actually doing the obvious and asking Google. That’s why I’ve finally gone and done it – I’ve found it all out – Just like that!
So I went to Google and asked ‘How Does Shazam Work?” and it spat out a myriad of search results, one of which read, “That Tune, Named – How does the music-identifying app Shazam work its magic?” I really am amazed that I never did this before.
So here it is, my friends. Enjoy:
Last week, Shazam announced that more than 50 million people worldwide have used the service—up from 35 million at the start of the year. The company also said that it’s received an undisclosed investment from the fabled Silicon Valley venture-capital firm KPCB. Shazam’s success seems justified—it’s the one app you can show to iPhone skeptics to get them to reconsider their position (though Shazam is also available on Android, BlackBerry, Windows Mobile, and pretty much any other phone). Yet for all the acclaim it garners, Shazam’s inner workings are pretty mysterious. How does it actually ID your song? How does the company make money? (Here’s one hint: iPhone users should expect to see a pay version soon.) And what are the long-term prospects for a firm whose sole purpose is satisfying an acute, very occasional need?
First, a short explanation of how Shazam works. The company has a library of more than 8 million songs, and it has devised a technique to break down each track into a simple numeric signature—a code that is unique to each track. “The main thing here is creating a ‘fingerprint’ of each performance,” says Andrew Fisher, Shazam’s CEO. When you hold your phone up to a song you’d like to ID, Shazam turns your clip into a signature using the same method. Then it’s just a matter of pattern-matching—Shazam searches its library for the code it created from your clip; when it finds that bit, it knows it’s found your song.OK, but how does Shazam make these fingerprints? As Avery Wang, Shazam’s chief scientist and one of its co-founders, explained to Scientific American in 2003, the company’s approach was long considered computationally impractical—there was thought to be too much information in a song to compile a simple signature. But as he wrestled with the problem, Wang had a brilliant idea: What if he ignored nearly everything in a song and focused instead on just a few relatively “intense” moments? Thus Shazam creates a spectrogram for each song in its database—a graph that plots three dimensions of music: frequency vs. amplitude vs. time. The algorithm then picks out just those points that represent the peaks of the graph—notes that contain “higher energy content” than all the other notes around it, as Wang explained in an academic paper he published to describe how Shazam works (PDF). In practice, this seems to work out to about three data points per second per song.
You’d think that ignoring nearly all of the information in a song would lead to inaccurate matches, but Shazam’s fingerprinting technique is remarkably immune to disturbances—it can match songs in noisy environments over bad cell connections. Fisher says that the company has also recently found a way to match music that has been imperceptibly sped up (as club DJs sometimes do to match a specific tempo or as radio DJs do to fit in a song before an ad break). And it can tell the difference between different versions of the same song. I just tried it on three different versions of “Landslide”—the original by Fleetwood Mac and covers by the Smashing Pumpkins and the Dixie Chicks—and it nailed each one.
Great – now you’re smarter than you were before you arrived at 2oceansvibe.
[imagesource:netflix] Keira Knightley takes centre stage in Netflix's latest spy thrill...
[imagesource:freemalaysiatoday] The weather's gone mad, all thanks to the dirty energy ...
[imagesource:flickr] One of Cape Town’s most vibrant, food-filled streets is embracin...
[imagesource:x/@KensingtonRoyal] You might have noticed the traffic being a little more...
[imagesource:freemalaysiatoday.com] A Cape Town e-hailing driver is about to make his g...