【发布时间】:2018-04-20 07:35:07
【问题描述】:
我正在使用 UBUNTU 16.04 并且我有安装程序 tensorflow,现在我正在尝试安装对象检测 API。 我已经从 git 克隆了 API,所以它给了我一个包含以下树的存储库:models/research/ 从研究仓库中,我遵循了官方 git 的所有步骤,我可以运行测试。然后我做了:
`sudo python setup.py install`
我还从源代码编译了 protoc 编译器以获得最新版本:3.5.1
我已经收集了我的数据并创建了 tf 记录并将它们放入数据存储库中。
我将配置文件放在培训存储库中。
我将数据、训练和模型文件存储库复制到
models/researches/object-detection/
然后我尝试运行 train.py 脚本以使用我自己的数据进行训练,但我收到以下错误,我真的迷路了,也许我做错了什么。有人知道吗?
`python train.py --logtostderr --train_dir=training/ --pipeline_config_path=training/ssd_mobilenet_v1_coco.config
/usr/local/lib/python2.7/dist-packages/h5py/__init__.py:36: FutureWarning: Conversion of the second argument of issubdtype from `float` to `np.floating` is deprecated. In future, it will be treated as `np.float64 == np.dtype(float).type`.
from ._conv import register_converters as _register_converters
WARNING:tensorflow:From /usr/local/lib/python2.7/dist-packages/tensorflow/contrib/learn/python/learn/datasets/base.py:198: retry (from tensorflow.contrib.learn.python.learn.datasets.base) is deprecated and will be removed in a future version.
Instructions for updating:
Use the retry module or similar alternatives.
Traceback (most recent call last):
File "train.py", line 167, in <module>
tf.app.run()
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/app.py", line 126, in run
_sys.exit(main(argv))
File "train.py", line 92, in main
FLAGS.pipeline_config_path)
File "/home/jimmy/Desktop/ObjectDetecAPI/models/research/object_detection/utils/config_util.py", line 92, in get_configs_from_pipeline_file
proto_str = f.read()
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/lib/io/file_io.py", line 120, in read
self._preread_check()
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/lib/io/file_io.py", line 80, 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 516, in __exit__
c_api.TF_GetCode(self.status.status))
tensorflow.python.framework.errors_impl.NotFoundError: training/ssd_mobilenet_v1_coco.config; No such file or directory
'
`/usr/local/lib/python2.7/dist-packages/h5py/__init__.py:36: FutureWarning: Conversion of the second argument of issubdtype from `float` to `np.floating` is deprecated. In future, it will be treated as `np.float64 == np.dtype(float).type.
from ._conv import register_converters as _register_converters
WARNING:tensorflow:From /usr/local/lib/python2.7/dist-packages/tensorflow/contrib/learn/python/learn/datasets/base.py:198: retry (from tensorflow.contrib.learn.python.learn.datasets.base) is deprecated and will be removed in a future version.
Instructions for updating:
Use the retry module or similar alternatives.
Traceback (most recent call last):
File "train.py", line 167, in <module>
tf.app.run()
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/app.py", line 126, in run
_sys.exit(main(argv))
File "train.py", line 92, in main
FLAGS.pipeline_config_path)
File "/home/jimmy/Desktop/ObjectDetecAPI/models/research/object_detection/utils/config_util.py", line 92, in get_configs_from_pipeline_file
proto_str = f.read()
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/lib/io/file_io.py", line 120, in read
self._preread_check()
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/lib/io/file_io.py", line 80, 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 516, in __exit__
c_api.TF_GetCode(self.status.status))
tensorflow.python.framework.errors_impl.NotFoundError: training/ssd_mobilenet_v1_coco.config; No such file or directory`
但我很确定我有一个培训存储库,里面有一个配置文件。
【问题讨论】:
标签: python tensorflow deep-learning object-detection