我尝试执行train.py时发生错误

问题描述 投票:0回答:1

当我执行python train.py --logtostderr --train_dir = training / --pipeline_config_path = training / faster_rcnn_inception_v2_pets.config我收到此错误:

WARNING:tensorflow:不包含TensorFlow contrib模块在TensorFlow 2.0中。有关更多信息,请参见:*https://github.com/tensorflow/community/blob/master/rfcs/20180907-contrib-sunset.md*https://github.com/tensorflow/addons* https://github.com/tensorflow/io(用于与I / O相关的操作)关于此处未列出的功能,请提出问题。

警告:tensorflow:来自train.py:55:名称tf.logging.set_verbosity不推荐使用。请改用tf.compat.v1.logging.set_verbosity。

警告:tensorflow:来自train.py:55:名称tf.logging.INFO为不推荐使用。请改为使用tf.compat.v1.logging.INFO。

警告:tensorflow:来自train.py:167:名称tf.app.run为不推荐使用。请改用tf.compat.v1.app.run。

警告:tensorflow:来自train.py:89:名称tf.gfile.MakeDirs为不推荐使用。请改用tf.io.gfile.makedirs。

W1212 22:01:57.353342 3060 deprecation_wrapper.py:119]来自train.py:89:不建议使用名称tf.gfile.MakeDirs。请用改为使用tf.io.gfile.makedirs。

警告:tensorflow:来自c:\ users \ aamir \ desktop \ models \ research \ object_detection \ utils \ config_util.py:86:不建议使用名称tf.gfile.GFile。请使用tf.io.gfile.GFile代替。

W1212 22:01:57.354341 3060 deprecation_wrapper.py:119]来自c:\ users \ aamir \ desktop \ models \ research \ object_detection \ utils \ config_util.py:86:不建议使用名称tf.gfile.GFile。请使用tf.io.gfile.GFile代替。

警告:tensorflow:来自train.py:94:名称tf.gfile.Copy为不推荐使用。请改用tf.io.gfile.copy。

W1212 22:01:57.358338 3060 deprecation_wrapper.py:119]来自train.py:94:名称tf.gfile.Copy已过时。请用改为tf.io.gfile.copy。

警告:tensorflow:来自c:\ users \ aamir \ desktop \ models \ research \ object_detection \ anchor_generators \ grid_anchor_generator.py:59:to_float(来自tensorflow.python.ops.math_ops)已弃用并将在将来的版本中删除。更新说明:使用改为tf.cast。 W1212 22:01:57.401396 3060 deprecation.py:323]从c:\ users \ aamir \ desktop \ models \ research \ object_detection \ anchor_generators \ grid_anchor_generator.py:59:to_float(来自tensorflow.python.ops.math_ops)已弃用并将在将来的版本中删除。更新说明:使用改为tf.cast。 INFO:tensorflow:小数位数为0会禁用正则化功能。I1212 22:01:57.406377 3060 regularizers.py:98]比例尺为0停用正则化。 INFO:tensorflow:小数位数为0会禁用正则化功能。 I121222:01:57.406377 3060regularizers.py:98]比例尺0禁用正则化。警告:tensorflow:从c:\ users \ aamir \ desktop \ models \ research \ object_detection \ trainer.py:228:create_global_step(来自tensorflow.contrib.framework.python.ops.variables)已弃用,将在以后的版本中删除。更新说明:请切换到tf.train.create_global_step W1212 22:01:57.408376 3060deprecation.py:323]来自c:\ users \ aamir \ desktop \ models \ research \ object_detection \ trainer.py:228:create_global_step(来自tensorflow.contrib.framework.python.ops.variables)已弃用,将在以后的版本中删除。更新说明:请切换到tf.train.create_global_step警告:tensorflow:从c:\ users \ aamir \ desktop \ models \ research \ object_detection \ data_decoders \ tf_example_decoder.py:104:不建议使用名称tf.FixedLenFeature。请用改为使用tf.io.FixedLenFeature。

W1212 22:01:57.413390 3060 deprecation_wrapper.py:119]来自c:\ users \ aamir \ desktop \ models \ research \ object_detection \ data_decoders \ tf_example_decoder.py:104:不建议使用名称tf.FixedLenFeature。请用改为使用tf.io.FixedLenFeature。

警告:tensorflow:来自c:\ users \ aamir \ desktop \ models \ research \ object_detection \ data_decoders \ tf_example_decoder.py:119:不建议使用名称tf.VarLenFeature。请用改为使用tf.io.VarLenFeature。

W1212 22:01:57.414372 3060 deprecation_wrapper.py:119]来自c:\ users \ aamir \ desktop \ models \ research \ object_detection \ data_decoders \ tf_example_decoder.py:119:不建议使用名称tf.VarLenFeature。请用改为使用tf.io.VarLenFeature。

追踪(最近一次通话):文件“ train.py”,第167行,在tf.app.run()文件“ C:\ Users \ Aamir \ Anaconda3 \ lib \ site-packages \ tensorflow \ python \ platform \ app.py”,40行_run(main = main,argv = argv,flags_parser = _parse_flags_tolerate_undef)文件“ C:\ Users \ Aamir \ Anaconda3 \ lib \ site-packages \ absl \ app.py”,行299,在跑_run_main(main,args)文件“ C:\ Users \ Aamir \ Anaconda3 \ lib \ site-packages \ absl \ app.py”,第250行,在_run_mainsys.exit(main(argv))文件“ train.py”,行163,在main中worker_job_name,is_chief,FLAGS.train_dir)文件“ c:\ users \ aamir \ desktop \ models \ research \ object_detection \ trainer.py”,235号线,在火车上train_config.prefetch_queue_capacity,data_augmentation_options)文件“ c:\ users \ aamir \ desktop \ models \ research \ object_detection \ trainer.py”,第59行,在create_input_queue中tensor_dict = create_tensor_dict_fn()文件“ train.py”,第120行,位于get_next中dataset_builder.build(config))。get_next()文件“ c:\ users \ aamir \ desktop \ models \ research \ object_detection \ builders \ dataset_builder.py”,138行,正在构建label_map_proto_file = label_map_proto_file)文件“ c:\ users \ aamir \ desktop \ models \ research \ object_detection \ data_decoders \ tf_example_decoder.py”,第195行,在init中use_display_name)文件“ c:\ users \ aamir \ desktop \ models \ research \ object_detection \ utils \ label_map_util.py”,第149行,位于get_label_map_dict中label_map = load_labelmap(label_map_path)文件“ c:\ users \ aamir \ desktop \ models \ research \ object_detection \ utils \ label_map_util.py”,第129行,在load_labelmap中label_map_string = fid.read()文件“ C:\ Users \ Aamir \ Anaconda3 \ lib \ site-packages \ tensorflow \ python \ lib \ io \ file_io.py”,第122行,处于读取状态self._preread_check()文件“ C:\ Users \ Aamir \ Anaconda3 \ lib \ site-packages \ tensorflow \ python \ lib \ io \ file_io.py”,_preread_check中的第84行compat.as_bytes(self .__ name),1024 * 512)tensorflow.python.framework.errors_impl.NotFoundError:NewRandomAccessFile创建/打开失败:C:/用户/阿米尔/桌面/模型/研究/object_detection/training/object-detection.pbtxt: 该系统找不到指定的文件。 ;没有这样的文件或目录

请帮助解决问题>

<<

在代码中的某处,您使用文件C:/Users/Aamir/Desktop/models/research/object_detection/training/object-detection.pbtxt但它不见了。也许此文件位于其他文件夹中,或者您有错字]
tensorflow object-detection object-detection-api
1个回答
© www.soinside.com 2019 - 2024. All rights reserved.