我在创建自己的模型以识别图像上的宠物时遇到问题。我正在跟踪牛津宠物识别器演练,但我被这个错误所困扰。
python object_detection/dataset_tools/create_pet_tf_record.py --data_dir=/home/cyber/Downloads/broji/annotations --output_dir=/home/cyber/Downloads/broji/output
Traceback (most recent call last):
File "object_detection/dataset_tools/create_pet_tf_record.py", line 318, in <module>
tf.app.run()
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/app.py", line 124, in run
_sys.exit(main(argv))
File "object_detection/dataset_tools/create_pet_tf_record.py", line 271, in main
label_map_dict = label_map_util.get_label_map_dict(FLAGS.label_map_path)
File "/usr/local/lib/python2.7/dist-packages/tensorflow/models/research/object_detection/utils/label_map_util.py", line 164, in get_label_map_dict
label_map = load_labelmap(label_map_path)
File "/usr/local/lib/python2.7/dist-packages/tensorflow/models/research/object_detection/utils/label_map_util.py", line 133, in load_labelmap
label_map_string = fid.read()
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/lib/io/file_io.py", line 119, in read
self._preread_check()
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/lib/io/file_io.py", line 79, in _preread_check
compat.as_bytes(self.__name), 1024 * 512, status)
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/framework/errors_impl.py", line 473, in __exit__
c_api.TF_GetCode(self.status.status))
tensorflow.python.framework.errors_impl.NotFoundError: data/pet_label_map.pbtxt; No such file or directory