Python Tensorflow:由于检查点文件,无法训练我的模型
我正在尝试设置Tensorflow的和下面的 我在训练我的模型时遇到以下错误(它抱怨没有找到检查点文件,但它在那里): Linux格式路径(“/c/ObjectDetection/faster\u rcnn\u resnet101\u coco\u 11\u 06\u 2017/model.ckpt”)Python Tensorflow:由于检查点文件,无法训练我的模型,python,tensorflow,object-detection,Python,Tensorflow,Object Detection,我正在尝试设置Tensorflow的和下面的 我在训练我的模型时遇到以下错误(它抱怨没有找到检查点文件,但它在那里): Linux格式路径(“/c/ObjectDetection/faster\u rcnn\u resnet101\u coco\u 11\u 06\u 2017/model.ckpt”) 操作系统:Windows 10 gitbash命令提示符 Python 3.5.2 tensorflow 1.3.0 正如错误消息所说,这是路径问题,而不是TensorFlow函数问题 即使
- 操作系统:Windows 10
- gitbash命令提示符
- Python 3.5.2
- tensorflow 1.3.0
\
,或将其设为原始字符串。例如:
'C:\\ObjectDetection\\faster_rcnn_resnet101_coco_11_06_2017\\model.ckpt'
# or
r'C:\ObjectDetection\\faster_rcnn_resnet101_coco_11_06_2017\\model.ckpt'
请注意,在粘贴的路径中,它显示的是C:\ObjectDetectionaster\u rcnn\u……
,而不是C:\ObjectDetection\faster\u rcnn\u……
。这是因为\f
指的是转义序列:
>>> print('\f')
>>> ord('\f')
12
>>> print('\\f') # escape the slash
\f
>>> print(r'\f') # or use raw strings with the 'r' prefix
\f
正如错误消息所说,这是路径的问题,而不是TensorFlow函数的问题 即使在Git Bash中,我也使用标准的windows样式路径,即“C:\”而不是“/C/”。此外,您需要转义
\
,或将其设为原始字符串。例如:
'C:\\ObjectDetection\\faster_rcnn_resnet101_coco_11_06_2017\\model.ckpt'
# or
r'C:\ObjectDetection\\faster_rcnn_resnet101_coco_11_06_2017\\model.ckpt'
请注意,在粘贴的路径中,它显示的是C:\ObjectDetectionaster\u rcnn\u……
,而不是C:\ObjectDetection\faster\u rcnn\u……
。这是因为\f
指的是转义序列:
>>> print('\f')
>>> ord('\f')
12
>>> print('\\f') # escape the slash
\f
>>> print(r'\f') # or use raw strings with the 'r' prefix
\f
>>> print('\f')
>>> ord('\f')
12
>>> print('\\f') # escape the slash
\f
>>> print(r'\f') # or use raw strings with the 'r' prefix
\f