1
votes

I have a problem during the train.py execution.

This is the command line : python train.py --logtosderr --train_dir=training/ --pipeline_config_path=training/ssd_inception_v2_coco.config

This is the result :

WARNING:tensorflow:From /home/vivien/.conda/envs/tensorflow_cpu/lib/python3.6/site-packages/tensorflow/python/platform/app.py:125: main (from main) is deprecated and will be removed in a future version. Instructions for updating: Use object_detection/model_main.py. WARNING:tensorflow:From /home/vivien/analyse_video/TensorFlow/models/research/object_detection/legacy/trainer.py:266: create_global_step (from tensorflow.contrib.framework.python.ops.variables) is deprecated and will be removed in a future version. Instructions for updating: Please switch to tf.train.create_global_step WARNING:tensorflow:num_readers has been reduced to 1 to match input file shards. INFO:tensorflow:depth of additional conv before box predictor: 0 INFO:tensorflow:depth of additional conv before box predictor: 0 INFO:tensorflow:depth of additional conv before box predictor: 0 INFO:tensorflow:depth of additional conv before box predictor: 0 INFO:tensorflow:depth of additional conv before box predictor: 0 INFO:tensorflow:depth of additional conv before box predictor: 0 Traceback (most recent call last): File "train.py", line 184, in tf.app.run() File "/home/vivien/.conda/envs/tensorflow_cpu/lib/python3.6/site-packages/tensorflow/python/platform/app.py", line 125, in run _sys.exit(main(argv)) File "/home/vivien/.conda/envs/tensorflow_cpu/lib/python3.6/site-packages/tensorflow/python/util/deprecation.py", line 250, in new_func return func(*args, **kwargs) File "train.py", line 180, in main graph_hook_fn=graph_rewriter_fn) File "/home/vivien/analyse_video/TensorFlow/models/research/object_detection/legacy/trainer.py", line 393, in train train_config.load_all_detection_checkpoint_vars)) File "/home/vivien/analyse_video/TensorFlow/models/research/object_detection/meta_architectures/ssd_meta_arch.py", line 1321, in restore_map for variable in variables_helper.get_global_variables_safely(): File "/home/vivien/analyse_video/TensorFlow/models/research/object_detection/utils/variables_helper.py", line 174, in get_global_variables_safely with tf.init_scope(): AttributeError: module 'tensorflow' has no attribute 'init_scope'

thank's

1

1 Answers

1
votes

Using the commit d530ac5 for the tensorflow/models github repo solved the issue for me. Refer to this link.