AttributeError:'模块'对象没有属性' LookupTensor'

时间:2018-03-11 05:57:49

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

我正在尝试使用Tensorflow在Google Cloud中运行培训工作。我尝试通过运行以下命令来运行培训。

gcloud ml-engine jobs submit training training_1 \
--job-dir=gs://object-detection-bucket-test/train \
--packages dist/object_detection-0.1.tar.gz,slim/dist/slim-0.1.tar.gz \
--module-name object_detection.train \
--region us-central1 \
--config object_detection/samples/cloud/cloud.yml \
--runtime-version=1.2 \
-- \
--train_dir=gs://object-detection-bucket-test/train \
--pipeline_config_path=gs://object-detection-bucket-test/data/ssd_mobilenet_v1_coco.config

但是当我开始工作时,我收到以下错误。知道为什么吗?

副本主机0退出时的非零状态为1.终止原因:错误。回溯(最近一次调用最后一次):文件" /usr/lib/python2.7/runpy.py",第174行,在_run_module_as_main" main",fname,loader,pkg_name)文件" /usr/lib/python2.7/runpy.py",第72行,在run_globals文件中的_run_code exec代码" /root/.local/lib/python2.7/site-packages/ object_detection / train.py",第167行,在tf.app.run()文件" /usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/app.py&# 34;,第48行,在run _sys.exit中(main(_sys.argv [:1] + flags_passthrough))文件" /root/.local/lib/python2.7/site-packages/object_detection/train。 py",第163行,在主worker_job_name中,is_chief,FLAGS.train_dir)文件" /root/.local/lib/python2.7/site-packages/object_detection/trainer.py" ;,第235行,在train train_config.prefetch_queue_capacity,data_augmentation_options)文件" /root/.local/lib/python2.7/site-packages/object_detection/trainer.py" ;,第59行,在create_input_queue tensor_dict = create_tensor_dict_fn()文件" /root/.local/ lib / python2.7 / site-packages / object_detection / train.py",第120行,在get_next dataset_builder.build(config)中。)get_next()文件" /root/.local/lib/python2。 7 / site-packages / object_detection / builders / dataset_builder.py",第138行,在构建label_map_proto_file = label_map_proto_file)文件" /root/.local/lib/python2.7/site-packages/object_detection/data_decoders /tf_example_decoder.py" ;,第210行,在init slim_example_decoder.LookupTensor中(AttributeError:' module'对象没有属性' LookupTensor'副本工作程序0退出时的非零状态为1.终止原因:错误。回溯(最近一次调用最后一次):文件" /usr/lib/python2.7/runpy.py",第174行,在_run_module_as_main" main",fname,loader,pkg_name)文件" /usr/lib/python2.7/runpy.py",第72行,在run_globals文件中的_run_code exec代码" /root/.local/lib/python2.7/site-packages/ object_detection / train.py",第167行,在tf.app.run()文件" /usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/app.py&# 34;,第48行,在run _sys.exit中(main(_sys.argv [:1] + flags_passthrough))文件" /root/.local/lib/python2.7/site-packages/object_detection/train。 py",第163行,在主worker_job_name中,is_chief,FLAGS.train_dir)文件" /root/.local/lib/python2.7/site-packages/object_detection/trainer.py" ;,第235行,在train train_config.prefetch_queue_capacity,data_augmentation_options)文件" /root/.local/lib/python2.7/site-packages/object_detection/trainer.py" ;,第59行,在create_input_queue tensor_dict = create_tensor_dict_fn()文件" /root/.local/ lib / python2.7 / site-packages / object_detection / train.py",第120行,在get_next dataset_builder.build(config)中。)get_next()文件" /root/.local/lib/python2。 7 / site-packages / object_detection / builders / dataset_builder.py",第138行,在构建label_map_proto_file = label_map_proto_file)文件" /root/.local/lib/python2.7/site-packages/object_detection/data_decoders /tf_example_decoder.py" ;,第210行,在init slim_example_decoder.LookupTensor中(AttributeError:' module'对象没有属性' LookupTensor'副本工作者1退出时的非零状态为1.终止原因:错误。回溯(最近一次调用最后一次):文件" /usr/lib/python2.7/runpy.py",第174行,在_run_module_as_main" main",fname,loader,pkg_name)文件" /usr/lib/python2.7/runpy.py",第72行,在run_globals文件中的_run_code exec代码" /root/.local/lib/python2.7/site-packages/ object_detection / train.py",第167行,在tf.app.run()文件" /usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/app.py&# 34;,第48行,在run _sys.exit中(main(_sys.argv [:1] + flags_passthrough))文件" /root/.local/lib/python2.7/site-packages/object_detection/train。 py",第163行,在主worker_job_name中,is_chief,FLAGS.train_dir)文件" /root/.local/lib/python2.7/site-packages/object_detection/trainer.py" ;,第235行,在train train_config.prefetch_queue_capacity,data_augmentation_options)文件" /root/.local/lib/python2.7/site-packages/object_detection/trainer.py" ;,第59行,在create_input_queue tensor_dict = create_tensor_dict_fn()文件" /root/.local/ lib / python2.7 / site-packages / object_detection / train.py",第120行,在get_next dataset_builder.build(config)中。)get_next()文件" /root/.local/lib/python2。 7 / site-packages / object_detection / builders / dataset_builder.py",第138行,在构建label_map_proto_file = label_map_proto_file)文件" /root/.local/lib/python2.7/site-packages/object_detection/data_decoders /tf_example_decoder.py" ;,第210行,在init slim_example_decoder.LookupTensor中(AttributeError:' module'对象没有属性' LookupTensor'副本工作者2退出时的非零状态为1.终止原因:错误。回溯(最近一次调用最后一次):文件" /usr/lib/python2.7/runpy.py",第174行,在_run_module_as_main" main",fname,loader,pkg_name)文件" /usr/lib/python2.7/runpy.py",第72行,在run_globals文件中的_run_code exec代码" /root/.local/lib/python2.7/site-packages/ object_detection / train.py",第167行,在tf.app.run()文件" /usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/app.py&# 34;,第48行,在run _sys.exit中(main(_sys.argv [:1] + flags_passthrough))文件" /root/.local/lib/python2.7/site-packages/object_detection/train。 py",第163行,在主worker_job_name中,is_chief,FLAGS.train_dir)文件" /root/.local/lib/python2.7/site-packages/object_detection/trainer.py" ;,第235行,在train train_config.prefetch_queue_capacity,data_augmentation_options)文件" /root/.local/lib/python2.7/site-packages/object_detection/trainer.py" ;,第59行,在create_input_queue tensor_dict = create_tensor_dict_fn()文件" /root/.local/ lib / python2.7 / site-packages / object_detection / train.py",第120行,在get_next dataset_builder.build(config)中。)get_next()文件" /root/.local/lib/python2。 7 / site-packages / object_detection / builders / dataset_builder.py",第138行,在构建label_map_proto_file = label_map_proto_file)文件" /root/.local/lib/python2.7/site-packages/object_detection/data_decoders /tf_example_decoder.py" ;,第210行,在init slim_example_decoder.LookupTensor中(AttributeError:' module'对象没有属性' LookupTensor'副本工作者3退出时的非零状态为1.终止原因:错误。回溯(最近一次调用最后一次):文件" /usr/lib/python2.7/runpy.py",第174行,在_run_module_as_main" main",fname,loader,pkg_name)文件" /usr/lib/python2.7/runpy.py",第72行,在run_globals文件中的_run_code exec代码" /root/.local/lib/python2.7/site-packages/ object_detection / train.py",第167行,在tf.app.run()文件" /usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/app.py&# 34;,第48行,在run _sys.exit中(main(_sys.argv [:1] + flags_passthrough))文件" /root/.local/lib/python2.7/site-packages/object_detection/train。 py",第163行,在主worker_job_name中,is_chief,FLAGS.train_dir)文件" /root/.local/lib/python2.7/site-packages/object_detection/trainer.py" ;,第235行,在train train_config.prefetch_queue_capacity,data_augmentation_options)文件" /root/.local/lib/python2.7/site-packages/object_detection/trainer.py" ;,第59行,在create_input_queue tensor_dict = create_tensor_dict_fn()文件" /root/.local/ lib / python2.7 / site-packages / object_detection / train.py",第120行,在get_next dataset_builder.build(config)中。)get_next()文件" /root/.local/lib/python2。 7 / site-packages / object_detection / builders / dataset_builder.py",第138行,在构建label_map_proto_file = label_map_proto_file)文件" /root/.local/lib/python2.7/site-packages/object_detection/data_decoders /tf_example_decoder.py" ;,第210行,在init slim_example_decoder.LookupTensor中(AttributeError:' module'对象没有属性' LookupTensor'副本工作者4退出时的非零状态为1.终止原因:错误。回溯(最近一次调用最后一次):文件" /usr/lib/python2.7/runpy.py",第174行,在_run_module_as_main" main",fname,loader,pkg_name)文件" /usr/lib/python2.7/runpy.py",第72行,在run_globals文件中的_run_code exec代码" /root/.local/lib/python2.7/site-packages/ object_detection / train.py",第167行,在tf.app.run()文件" /usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/app.py&# 34;,第48行,在run _sys.exit中(main(_sys.argv [:1] + flags_passthrough))文件" /root/.local/lib/python2.7/site-packages/object_detection/train。 py",第163行,在主worker_job_name中,is_chief,FLAGS.train_dir)文件" /root/.local/lib/python2.7/site-packages/object_detection/trainer.py" ;,第235行,在train train_config.prefetch_queue_capacity,data_augmentation_options)文件" /root/.local/lib/python2.7/site-packages/object_detection/trainer.py" ;,第59行,在create_input_queue tensor_dict = create_tensor_dict_fn()文件" /root/.local/ lib / python2.7 / site-packages / object_detection / train.py",第120行,在get_next dataset_builder.build(config)中。)get_next()文件" /root/.local/lib/python2。 7 / site-packages / object_detection / builders / dataset_builder.py",第138行,在构建label_map_proto_file = label_map_proto_file)文件" /root/.local/lib/python2.7/site-packages/ object_detection / data_decoders / tf_example_decoder.py",第210行,在init slim_example_decoder.LookupTensor中(AttributeError:' module'对象没有属性' LookupTensor'

1 个答案:

答案 0 :(得分:0)

已发布并最终在this github问题中回答。将运行时升级到1.5+应解决它。