From 7ea5a4f5d9601ddaa238d8dd50888491ef96ca67 Mon Sep 17 00:00:00 2001 From: sleepfin Date: Fri, 28 Apr 2017 15:07:08 +0800 Subject: [PATCH] Wrong file directory I have downloaded the dataset of VOC2007 and find out that the directory of images is "./VOC2007/JPEGImages/xxxxxx.jpg" And I think your path will be "./VOC2007JPEGImages/xxxxxx.jpg" This change works for me. --- datasets/pascalvoc_to_tfrecords.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/datasets/pascalvoc_to_tfrecords.py b/datasets/pascalvoc_to_tfrecords.py index 9ac20169b..d4dcae6c9 100644 --- a/datasets/pascalvoc_to_tfrecords.py +++ b/datasets/pascalvoc_to_tfrecords.py @@ -79,7 +79,7 @@ def _process_image(directory, name): width: integer, image width in pixels. """ # Read the image file. - filename = directory + DIRECTORY_IMAGES + name + '.jpg' + filename = directory + '/' + DIRECTORY_IMAGES + name + '.jpg' image_data = tf.gfile.FastGFile(filename, 'r').read() # Read the XML annotation file.