R 谷歌预测api“;“你好,预测”;辅导的
我已经浏览了Google Prediction API教程和“hello Prediction- 但是,在开发人员控制台中培训模型时,我的请求失败,输出如下: 请求:R 谷歌预测api“;“你好,预测”;辅导的,r,prediction,R,Prediction,我已经浏览了Google Prediction API教程和“hello Prediction- 但是,在开发人员控制台中培训模型时,我的请求失败,输出如下: 请求: POST https://www.googleapis.com/prediction/v1.6/projects/959568262740/trainedmodels?key={YOUR_API_KEY} { "id": "language_id", "storageDataLocation": "http://storag
POST https://www.googleapis.com/prediction/v1.6/projects/959568262740/trainedmodels?key={YOUR_API_KEY}
{
"id": "language_id",
"storageDataLocation": "http://storage.googleapis.com/2341234/language_id.txt"
}
答复:
400 OK
- Show headers -
{
"error": {
"errors": [
{
"domain": "global",
"reason": "invalid",
"message": "Training data file is empty.",
"locationType": "other",
"location": "id"
}
],
"code": 400,
"message": "Training data file is empty."
}
}
我已经使用OAuth 2.0实现了授权请求:-还有什么我应该做的,或者在Google PRediction API v 1.6和教程之间可能已经做了更改。任何指向此主题的其他教程或文章的链接都非常有价值,因此可以自己调试!您的storageDataLocation不正确。 当您转到Google开发者控制台中的Overview选项卡时,您会发现您的项目ID:xxxxx(示例),并且您存储的bucket名为yyy(示例) 然后替换“storageDataLocation:”xxxxx/yyyy“。应该可以解决此问题。您需要Google存储的相对路径,而不是绝对web路径