我已按照以下说明在本地设置 google-cloud-ml:MAC/LINUX
但是在使用此命令验证设置时出现以下错误
curl https://raw.githubusercontent.com/GoogleCloudPlatform/cloudml-samples/master/tools/check_environment.py | python
Traceback(最近一次调用最后一次):文件“”,第 70 行,在文件“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/google/cloud/ml/init .py ”中,第 16 行,从 google.cloud.ml.dataflow._analyzer 导入 AnalyzeModel 文件“ /Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/google/cloud/ml/dataflow/init.py”,第 22 行,从 _ml_transforms 导入 DeployVersion 文件“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/google/cloud/ml/dataflow/_ml_transforms.py”,第 24 行,在 import _ml_functions as ml_func File "/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/google/cloud/ml/dataflow/_ml_functions.py",第 25 行,来自 google.cloud .ml.io.coders 导入 TrainingJobResult 文件“ /Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/google/cloud/ml/io/init.py”,第 21 行,从转换导入 LoadFeatures 文件“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/google/cloud/ml/io/transforms.py”,第 23 行,在从 google.cloud.ml.dataflow.io 导入 tfrecordio 文件“ /Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/google/cloud/ml/dataflow/io/init .py ”,第 15 行,在导入 tfrecordio 文件中“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/google/cloud/ml/dataflow/io/tfrecordio.py”,第 16 行,在_crc32c_fn = snappy._crc32c # pylint: disable=protected-access AttributeError: 'module' 对象没有属性 '_crc32c'
看起来谷歌云的数据流库有一些问题。
我尝试使用以下命令升级数据流库
pip install --upgrade google-api-python-client
但现在,另一个错误。以下是堆栈跟踪:
Traceback(最近一次调用最后一次):文件“”,第 70 行,在文件“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/google/cloud/ml/init .py ”中,第 16 行,从 google.cloud.ml.dataflow._analyzer 导入 AnalyzeModel 文件“ /Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/google/cloud/ml/dataflow/init .py ”,第 17 行,从 _analyzer 导入分析模型文件“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/google/cloud/ml/dataflow/_analyzer.py”,第 19 行,在将apache_beam导入为梁文件“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/apache_beam/init.py”,第 78 行,从 apache_beam 导入 io 文件“ /Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/apache_beam/io/init.py”,第 21 行,从 apache_beam.io.avroio 导入 * 文件“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/apache_beam/io/avroio.py”,第 29 行,从 apache_beam.io 导入 filebasedsource 文件“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/apache_beam/io/filebasedsource.py”,第 32 行,从 apache_beam.io 导入 concat_source文件“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/apache_beam/io/concat_source.py”,第 24 行,从 apache_beam.io 导入 iobase 文件“/Users/pratyusha/miniconda2 /envs/cloudml/lib/python2.7/site-packages/apache_beam/io/iobase.py",第 853 行,从 apache_beam.runners.dataflow.native_io.iobase 导入 * 文件"/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/apache_beam/runners/init .py”,第 23 行,从 apache_beam.runners.dataflow_runner 导入 DataflowRunner 文件“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/apache_beam/runners/dataflow_runner.py”,行32,从 apache_beam.internal 导入 json_value 文件“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/apache_beam/internal/json_value.py”,第 20 行,从 apitools.base。 py import extra_types 文件“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/apitools/base/py/init .py ”,第 23 行,从 apitools.base.py.credentials_lib 导入* 文件“/Users/pratyusha/miniconda2/envs/cloudml/lib/python2.7/site-packages/apitools/base/py/credentials_lib.py”,第 50 行,从 oauth2client 导入locked_file