Pyechonest Remix Echo Nest API错误2:2 |不允许使用API​​密钥

时间:2016-08-19 18:45:52

标签: api echonest

我希望由于将Echonest API迁移到Spotify API,我现在在尝试检索from echonest.remix.audio import AudioAnalysis AudioAnalysis(str(track_md5)) 对象时收到错误。

但我不确定如何或在何处更改我从Echonest API调用Spotify API的API。

代码基本上是:

 protected Void doInBackground(Void... arg0) {


    Socket socket = null;

    try {
        socket = new Socket(dstAddress, dstPort);

        Scanner r = new Scanner(new InputStreamReader(socket.getInputStream()));

        while (true) {


            //MASTER
            valores[0] = r.nextLine();
            valores[1] = r.nextLine();
            valores[2] = r.nextLine();
            valores[3] = r.nextLine();
            valores[4] = r.nextLine();
            valores[5] = r.nextLine();
            valores[6] = r.nextLine();
            valores[7] = r.nextLine();
            valores[8] = r.nextLine();
            valores[9] = r.nextLine();
            valores[10] = r.nextLine();
            valores[11] = r.nextLine();
            valores[12] = r.nextLine();

            //SLAVE
            valores[13] = r.nextLine();
            valores[14] = r.nextLine();
            valores[15] = r.nextLine();
            valores[16] = r.nextLine();
            valores[17] = r.nextLine();
            valores[18] = r.nextLine();
            valores[19] = r.nextLine();
            valores[20] = r.nextLine();
            valores[21] = r.nextLine();
            valores[22] = r.nextLine();
            valores[23] = r.nextLine();
            valores[24] = r.nextLine();
            valores[25] = r.nextLine();

            r.useDelimiter("\\zfish");
            while (r.hasNext()) {
                valores[26] = r.next();
            }

            publishProgress(valores[0], valores[1], valores[2], valores[3], valores[4], valores[5], valores[6], valores[7], valores[8], valores[9], valores[10], valores[11], valores[12],
                    valores[13], valores[14], valores[15], valores[16], valores[17], valores[18], valores[19], valores[20], valores[21], valores[22], valores[23], valores[24], valores[25], valores[26]);
        }

    } catch (UnknownHostException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();

    } catch (IOException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();

    } finally {
        if (socket != null) {
            try {
                socket.close();
            } catch (IOException e) {
                // TODO Auto-generated catch block
                e.printStackTrace();
            }
        }
    }

    return null;

}

pyechonest和remix仍然有效吗?如果是这样,我需要在哪里进行配置更改?

我想我错过了一些明显的东西。

0 个答案:

没有答案