Import Error: no module named cloud.ml

Import Error: no module named cloud.ml

我正在尝试按照说明在 tensorflow 中使用局部预测,如 here 所述。 运行 命令 gcloud ml-engine local predict --model-dir=~/PycharmProjects/nlc/export/1/ --json-instances=test.json 给我错误:

ERROR: (gcloud.ml-engine.local.predict) Cannot import google.cloud.ml. Please verify "python -c 'import google.cloud.ml'" works. Please verify the installed cloudml sdk version with: "python -c 'import google.cloud.ml as cloudml; print cloudml.__version__'".

我需要安装什么才能获得 google.cloud.ml 软件包?它在 link 上说的是

It requires the TensorFlow SDK be installed locally

Tensorflow 在我的系统上正常工作并且 python -c 'import tensorflow as tf; print(tf.__version__)' 输出 1.0.1。我还确保通过 运行 pip install -U google-api-python-client 安装 python 实用程序。我还需要安装什么?

这是在 VM 运行 Ubuntu 上尝试的,以便处理要求:

Only Debian based systems are supported at this time.

这是 gcloud 的一个已知错误,将在明天 (2017/03/15) 的版本中修复。明天某个时候,请运行

gcloud components update

对于给您带来的不便,我们深表歉意。