|
I am currently working on a program that analyses the user's mp3 library and finds inconsistencies in the ID3 tags. As you may know, a common ID3 tag is BPM, or the beats per minute of the song. I have been looking around trying to find the best way to programmatically calculate the BPM of a song.
Then I found pyechonest, the Python wrapper for the Echo Nest API. So installed the packed and threw together a simple little script.
Here it is:
from pyechonest import config
import echonest.audio
config.ECHO_NEST_API_KEY = 'my api key'
song = echonest.audio.LocalAnalysis('A Flock of Seagulls - I Ran (So Far Away).mp3')
print song.analysis.tempo
To my dismay, every song that is analyzed seems to be analyzed not on the local machine, but instead uploaded to a central server where the actual work is done.
I guess this is just how the API is designed, but I was wondering if there is any way to have the analysis done on the local machine. Why? Well if I am analyzing an 80gb library, the upload time would be astronomical and would really put a damper on the efficiency of my program.
Does anyone know if there is a way to get Echo Nest to run locally or another Python library to calculate the BPM of a song?
|