问题
I am trying to follow the instructions to use local predictions in tensorflow as described here. Running the command gcloud ml-engine local predict --model-dir=~/PycharmProjects/nlc/export/1/ --json-instances=test.json
gives me the error:
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__'".
What do I need to install in order to get the google.cloud.ml
package? All it says on that link is
It requires the TensorFlow SDK be installed locally
Tensorflow is working properly on my system and python -c 'import tensorflow as tf; print(tf.__version__)'
outputs 1.0.1
. I have also made sure to install the python utilities by running pip install -U google-api-python-client
. What else do I need to install?
This is being attempted on a VM running Ubuntu, so that handles the requirement:
Only Debian based systems are supported at this time.
回答1:
This is a known bug with gcloud that will be fixed in tomorrow's (2017/03/15) release. Sometime tomorrow, please run
gcloud components update
Apologies for the inconvenience.
来源:https://stackoverflow.com/questions/42788485/import-error-no-module-named-cloud-ml