2

This question is an extension of this one.

TLDR; I'm trying to train the TS Object Detection API using my own dataset. For proof of concept, I decided to adhere my dataset to the Pascal VOC 2012 benchmark.

At the moment, I am trying to create a TFRecord from my Pascal VOC annotations.

Looking at this line in their create_pascal_tf_record.py script, they're just grabbing the aeroplane's descriptor; lack of a better word, text file. Why is this so? What about the other classes' descriptors?

Side Note

This file; titled aeroplane_train.txt, was included along with the Pascal VOC 2012 dataset inside VOC2012/ImageSets/Main/.

A peek into the file shows that the first column represents an image name and the -1 or 1 states whether that particular image consists of the class(aeroplane) we're interested in.

Partial contents of the aeroplane_train.txt file:

2008_000008 -1
2008_000015 -1
2008_000019 -1
2008_000023 -1
2008_000028 -1
2008_000033  1
2008_000036 -1
2008_000037  1
2008_000041 -1
2008_000045 -1
2008_000053 -1
2008_000060 -1
2008_000066 -1
2008_000070 -1
2008_000074 -1
2008_000085 -1
2008_000089 -1
2008_000093 -1
2008_000095 -1
2008_000096 -1
2008_000097 -1
2008_000099 -1
2008_000103 -1
2008_000105 -1
2008_000109 -1
2008_000112 -1
2008_000128 -1
2008_000131 -1
2008_000132 -1
2008_000141 -1
Juan Carlos Ramirez
  • 2,054
  • 1
  • 7
  • 22
eshirima
  • 3,837
  • 5
  • 37
  • 61

1 Answers1

7

I answered a similar question here. The punchline is that we currently only look at the first column of the aeroplane_train.txt file (which is the same as the other xxx_train.txt files) and lets us figure out the path for each image in the training set.

Jonathan Huang
  • 1,560
  • 9
  • 12
  • 1
    Thank you so much.. I decided to share [my experience](https://stackoverflow.com/questions/44973184/train-tensorflow-object-detection-on-own-dataset/44973203#44973203) after successfully getting it to work. Would be awesome to have your two cents on how I'd've made better for future reference. – eshirima Jul 07 '17 at 14:27
  • May i ask, the significance of adding a boolean value after the image, why bother because we have the images listed in trainval.txt and test.txt. why even seperate out each class. Do the images followed by -1, taken as negative images for that class which I think will further help for lower FPs. ? – shruti Jan 26 '18 at 13:13
  • why is this file named aeroplane? I don't have aeroplanes in my dataset. – Stepan Yakovenko Jul 12 '19 at 12:15