为Cloud ML

时间:2016-11-29 23:52:52

标签: shell google-cloud-platform google-cloud-ml google-cloud-shell

我正在尝试为使用Cloud ML的Google云项目设置google云外壳环境。

我按照设置页面上的说明进行操作:

Getting Setup | Google Cloud Machine Learning

我在cloud shell

中执行了此命令
  

卷曲   https://raw.githubusercontent.com/GoogleCloudPlatform/cloudml-samples/master/tools/setup_cloud_shell.sh   | bash的

ouput trace的最后一部分是:

  
      
  • 回声'成功!您的环境具有所需的工具和依赖项。成功!您的环境具有所需的工具和   的依赖关系。
  •   

此命令:

  

export PATH = $ {HOME} /.local / bin:$ {PATH}

不产生任何产品。

最后检查环境的命令:

  

卷曲   https://raw.githubusercontent.com/GoogleCloudPlatform/cloudml-samples/master/tools/check_environment.py   |蟒

生成此输出:

vineetkaushik053@cloudshell:~$ curl https://raw.githubusercontent.com/GoogleCloudPlatform/cloudml-samples/master/tools/check_environment.py | python
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  3814  100  3814    0     0  17274      0 --:--:-- --:--:-- --:--:-- 17257
You are using pip version 8.1.1, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
You are using pip version 8.1.1, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Your active configuration is: [cloudshell-11180]
ERROR: Unable to list Cloud ML models: {
  "error": {
    "code": 400,
    "message": "Field: parent Error: Name should be in the form of 'projects/your-project-id'",
    "status": "INVALID_ARGUMENT",
    "details": [
      {
        "@type": "type.googleapis.com/google.rpc.BadRequest",
        "fieldViolations": [
          {
            "field": "parent",
            "description": "Name should be in the form of 'projects/your-project-id'"
          }
        ]
      }
    ]
  }
}

什么时候应该生产:

“成功!您的环境配置正确。”当脚本成功完成时。

请告诉我如何解决这个问题,以便我可以转到设置的下一部分。

1 个答案:

答案 0 :(得分:3)

解决了这一点。

需要为环境设置项目。您可以使用此命令:

  

gcloud config set project your-project-ID

相关问题