SSD(Single Shot MultiBox Detector):create_list.sh io.cpp:187 Could not open or find file

今天在为SSD训练自己的数据时执行caff/data/VOC0712/create_list.sh时报了好多这个错误:

E0412 16:28:31.653440 5008 io.cpp:187] Could not open or find file/home/guyadong/data/VOCdevkit/facedata/JPEGImages/070010

就是找不到指定的图像文件,但观察上面的log发现,get_image_size要打开的文件是070010,没有.jpg后缀,所以自然是找不到,查了半天总算找到原因。 根本的原因是VOC2007/ImageSets/Main/下的训练文件 test.txt,trainval.txt(我在windows下用程序生成的)的分行符是windows格式的换行(0d0a)(\r\n),而create_list.sh则按unix格式换行(0a)(\n)来处理的,导致生成的临时文件(caffe/data/VOC0712/test.txt,val.txt)的换行都是错的,如下图.jpg被错误换行了:

如下绿框标记图修改caff/data/VOC0712/create_list.sh,即解决 问题

修改后再执行create_list.sh,则临时文件caff/data/VOC0712/test.txt,va.txt的内容就正确换行了

再执行create_list.sh则一切正常

guyadong@gyd-u16:~/tmp/cafe-ssd$ ./data/facedata/create_list.sh Create list for facedata trainval… Create list for facedata test… I0412 16:47:31.735117 5915 get_image_size.cpp:61] A total of 64152 images. I0412 16:47:32.441088 5915 get_image_size.cpp:100] Processed 1000 files. I0412 16:47:33.163386 5915 get_image_size.cpp:100] Processed 2000 files. I0412 16:47:33.793678 5915 get_image_size.cpp:100] Processed 3000 files. I0412 16:47:34.383620 5915 get_image_size.cpp:100] Processed 4000 files. I0412 16:47:35.021188 5915 get_image_size.cpp:100] Processed 5000 files. I0412 16:47:35.678146 5915 get_image_size.cpp:100] Processed 6000 files. I0412 16:47:36.291211 5915 get_image_size.cpp:100] Processed 7000 files. I0412 16:47:36.902132 5915 get_image_size.cpp:100] Processed 8000 files. I0412 16:47:37.620117 5915 get_image_size.cpp:100] Processed 9000 files. I0412 16:47:38.415658 5915 get_image_size.cpp:100] Processed 10000 files. I0412 16:47:39.196408 5915 get_image_size.cpp:100] Processed 11000 files. I0412 16:47:39.955487 5915 get_image_size.cpp:100] Processed 12000 files. I0412 16:47:40.751711 5915 get_image_size.cpp:100] Processed 13000 files. I0412 16:47:41.587662 5915 get_image_size.cpp:100] Processed 14000 files. I0412 16:47:42.361137 5915 get_image_size.cpp:100] Processed 15000 files. I0412 16:47:43.185786 5915 get_image_size.cpp:100] Processed 16000 files. I0412 16:47:44.023108 5915 get_image_size.cpp:100] Processed 17000 files. I0412 16:47:44.839643 5915 get_image_size.cpp:100] Processed 18000 files. I0412 16:47:45.613772 5915 get_image_size.cpp:100] Processed 19000 files. I0412 16:47:46.467950 5915 get_image_size.cpp:100] Processed 20000 files. I0412 16:47:47.240926 5915 get_image_size.cpp:100] Processed 21000 files. I0412 16:47:48.030536 5915 get_image_size.cpp:100] Processed 22000 files. I0412 16:47:48.808050 5915 get_image_size.cpp:100] Processed 23000 files. I0412 16:47:49.573930 5915 get_image_size.cpp:100] Processed 24000 files. I0412 16:47:50.296659 5915 get_image_size.cpp:100] Processed 25000 files. I0412 16:47:51.137468 5915 get_image_size.cpp:100] Processed 26000 files. I0412 16:47:51.965564 5915 get_image_size.cpp:100] Processed 27000 files. I0412 16:47:52.748363 5915 get_image_size.cpp:100] Processed 28000 files. I0412 16:47:53.545373 5915 get_image_size.cpp:100] Processed 29000 files. I0412 16:47:54.313802 5915 get_image_size.cpp:100] Processed 30000 files. I0412 16:47:55.063397 5915 get_image_size.cpp:100] Processed 31000 files. I0412 16:47:55.833818 5915 get_image_size.cpp:100] Processed 32000 files. I0412 16:47:56.593185 5915 get_image_size.cpp:100] Processed 33000 files. I0412 16:47:57.318747 5915 get_image_size.cpp:100] Processed 34000 files. I0412 16:47:58.106588 5915 get_image_size.cpp:100] Processed 35000 files. I0412 16:47:58.874009 5915 get_image_size.cpp:100] Processed 36000 files. I0412 16:47:59.662654 5915 get_image_size.cpp:100] Processed 37000 files. I0412 16:48:00.391137 5915 get_image_size.cpp:100] Processed 38000 files. I0412 16:48:01.253373 5915 get_image_size.cpp:100] Processed 39000 files. I0412 16:48:02.372660 5915 get_image_size.cpp:100] Processed 40000 files. I0412 16:48:03.551955 5915 get_image_size.cpp:100] Processed 41000 files. I0412 16:48:05.022789 5915 get_image_size.cpp:100] Processed 42000 files. I0412 16:48:06.376894 5915 get_image_size.cpp:100] Processed 43000 files. I0412 16:48:07.373198 5915 get_image_size.cpp:100] Processed 44000 files. I0412 16:48:08.421833 5915 get_image_size.cpp:100] Processed 45000 files. I0412 16:48:09.321070 5915 get_image_size.cpp:100] Processed 46000 files. I0412 16:48:10.618541 5915 get_image_size.cpp:100] Processed 47000 files. I0412 16:48:11.719383 5915 get_image_size.cpp:100] Processed 48000 files. I0412 16:48:13.171823 5915 get_image_size.cpp:100] Processed 49000 files. I0412 16:48:14.412339 5915 get_image_size.cpp:100] Processed 50000 files. I0412 16:48:15.605201 5915 get_image_size.cpp:100] Processed 51000 files. I0412 16:48:16.961227 5915 get_image_size.cpp:100] Processed 52000 files. I0412 16:48:18.067579 5915 get_image_size.cpp:100] Processed 53000 files. I0412 16:48:18.919296 5915 get_image_size.cpp:100] Processed 54000 files. I0412 16:48:19.524323 5915 get_image_size.cpp:100] Processed 55000 files. I0412 16:48:20.154620 5915 get_image_size.cpp:100] Processed 56000 files. I0412 16:48:20.755278 5915 get_image_size.cpp:100] Processed 57000 files. Premature end of JPEG file I0412 16:48:21.353775 5915 get_image_size.cpp:100] Processed 58000 files. Premature end of JPEG file I0412 16:48:21.967610 5915 get_image_size.cpp:100] Processed 59000 files. I0412 16:48:22.725572 5915 get_image_size.cpp:100] Processed 60000 files. I0412 16:48:23.532981 5915 get_image_size.cpp:100] Processed 61000 files. I0412 16:48:24.299060 5915 get_image_size.cpp:100] Processed 62000 files. I0412 16:48:25.078511 5915 get_image_size.cpp:100] Processed 63000 files. I0412 16:48:25.844919 5915 get_image_size.cpp:100] Processed 64000 files. I0412 16:48:25.968722 5915 get_image_size.cpp:105] Processed 64152 files.

本文参与腾讯云自媒体分享计划,欢迎正在阅读的你也加入,一起分享。

发表于

我来说两句

0 条评论
登录 后参与评论

相关文章

来自专栏java沉淀

springboot入门之路(一)

1873
来自专栏Netkiller

hyperledger v1.0.5 区块链运维入门

hyperledger v1.0.5 区块链运维入门 摘要 你网上搜索hyperledger大部分文章是讲解开发环境的安装与配置,没有一篇关于怎样运维区块链的文...

4338
来自专栏SeanCheney的专栏

Scrapy-Redis分布式抓取麦田二手房租房信息与数据分析准备工作租房爬虫二手房分布式爬虫数据分析及可视化

试着通过抓取一家房产公司的全部信息,研究下北京的房价。文章最后用Pandas进行了分析,并给出了数据可视化。 ---- 准备工作 麦田房产二手房页面(http:...

5477
来自专栏Laoqi's Linux运维专列

MySQL高可用架构之MHA

2143
来自专栏乐沙弥的世界

Oracle 闪回特性(FLASHBACK DROP & RECYCLEBIN)

--==============================================

623
来自专栏数据库新发现

Oracle诊断案例-Spfile案例一则

情况说明: 系统:SUN Solaris8 数据库版本:9203 问题描述:工程人员报告,数据库在重新启动时无法正常启动.检查发现UNDO表空间丢失. 问题诊断...

713
来自专栏杨建荣的学习笔记

11g备库无法开启ADG的原因分析 (r7笔记第62天)

今天碰到一个有些奇怪的问题,但是奇怪的现象背后都是有本质的因果。 下午在做一个环境的检查时,发现备库是在mount阶段,这可是一个11gR2的库,没有ADG实在...

3474
来自专栏杨建荣的学习笔记

重启数据库的一场闹剧(r5笔记第68天)

在几周前,某个测试环境在尝试impdp导入dump的时候报了错误,有个DBA立马做了kill session的操作,但是持续了5个小时,session状态还是K...

3009
来自专栏生信技能树

小鼠全基因组数据分析

We performed WGS on a CRISPR–Cas9-edited mouse to identify all off-target mutati...

1192
来自专栏杨建荣的学习笔记

数据迁移部分问题总结(r2第3天)

按照计划在周二开始了数据迁移,本来之前也做了不少的准备工作。但是还是在迁移的过程中出现了一些问题。简单做一个总结。 1.constraint导致的数据rej...

2757

扫码关注云+社区