Key signature detection of an mp3 file Java APIs -
is there apis can detect key signature of given mp3 file? found 1 named echo-nest , not working.
it gives following error in console
=========================================================================
exception in thread "main" com.echonest.api.v3.echonestexception: java.io.filenotfoundexception: http://developer.echonest.com/api/get_metadata?md5=09adfa373f1e0742e650336d2833463d&analysis_version=3&version=3&api_key=bcmyqjmjlqtgcsx9d @ com.echonest.api.v3.track.trackapi.getmetadata(trackapi.java:345) @ com.echonest.api.v3.track.trackapi.getanalysisstatus(trackapi.java:618) @ com.echonest.api.v3.track.trackapi.isknowntrack(trackapi.java:628) @ com.echonest.api.v3.track.trackapi.uploadtrack(trackapi.java:135) @ test.main(test.java:25) caused by: java.io.filenotfoundexception: http://developer.echonest.com/api/get_metadata?md5=09adfa373f1e0742e650336d2833463d&analysis_version=3&version=3&api_key=bcmyqjmjlqtgcsx9d @ sun.net.www.protocol.http.httpurlconnection.getinputstream(unknown source) @ com.echonest.api.util.commander.sendcommandraw(commander.java:267) @ com.echonest.api.util.commander.sendcommand(commander.java:179) @ com.echonest.api.v3.echonestcommander.sendcommand(echonestcommander.java:269) @ com.echonest.api.v3.echonestcommander.sendcommand(echonestcommander.java:252) @ com.echonest.api.v3.track.trackapi.getmetadata(trackapi.java:331) ... 4 more
======================================================================= code gives error note: api key exact 1 gave.
import java.io.file; import java.net.url; import java.util.list; import com.echonest.api.v3.echonestexception; import com.echonest.api.v3.artist.artist; import com.echonest.api.v3.artist.artistapi; import com.echonest.api.v3.artist.scored; import com.echonest.api.v3.track.trackapi; import com.echonest.api.v3.track.trackapi.analysisstatus; public class test { public static void main(string[] args) throws echonestexception { string my_echo_nest_api_key = "bcmyqjmjlqtgcsx9d"; trackapi trackapi = new trackapi(my_echo_nest_api_key); string id = trackapi.uploadtrack(new file("c://low.mp3"), false); analysisstatus status = trackapi.waitforanalysis(id, 60000); if (status == analysisstatus.complete) { system.out.println("key in song: " + trackapi.getkey(id)); } } }
======================================================================
echo-nest api download link: https://echo-nest-java-api.googlecode.com/files/echo-nest-java-api-1.3.zip
Comments
Post a Comment