Answers.Body: <p>It is correct that to eliminate the false positives, the training must include images that reflect true negative cases. The objective of training is not this.</p>
  
  <blockquote>
    <p>Find the objects of class <span class="math-container">$O$</span> in scene <span class="math-container">$X$</span>.</p>
  </blockquote>
  
  <p>It is this.</p>
  
  <blockquote>
    <p>Find any objects of class <span class="math-container">$O$</span> in scene <span class="math-container">$X$</span>.</p>
  </blockquote>
  
  <p>Training is effective when sample <span class="math-container">$S$</span> is drawn according to the same distribution as will be used for drawing at test time or during actual use.</p>
  
  <p>It is not necessary to annotate the background if the loss function is chosen so that finding nothing when nothing there is indicated as a zero loss and a proper distribution of those cases exist in the training sample.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-12-31T10:56:24.033Z
Answers.Text: Thank you, from a theoretical point of view it is perfectly clear. From a practical point of view, I am not sure whether I should associate background images with empty annotations, as far as MobileNetSSD is concerned. Do you have some information about this?
Answers.UserDisplayName: firion
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-12-29T07:38:41.057Z
Answers.LastActivityDate: 2018-12-29T07:38:41.057Z
Answers.UserDisplayName: Douglas Daseeco
Body: <p>I fine tuned <a href="https://arxiv.org/pdf/1704.04861.pdf" rel="nofollow noreferrer">MobileNetSSD</a> for object detection using a dataset with just one class (~4000 images). All the training images include at least one bounding box related to that class (no empty images). By following the <a href="https://github.com/chuanqi305/MobileNet-SSD" rel="nofollow noreferrer">example</a> with the VOC dataset, the labelmap includes two classes, the background and my custom class. However, as I mentioned, there are no annotations related to the background and I  am not sure if there should be any.</p>
  
  <p>Now my fine tuned network performs very well when objects belonging to my class are present, however there are some false detections with very high confidence when the class is not present. Can this be related to the fact that I don't have empty images in my training set?</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-12-23T13:48:34.753Z
Comments.Text: It could be. It would help if you describe your model and its output (how does it do the object detection?) as well as your training data (number of training samples, relative size of object in images)..
Comments.UserDisplayName: Mark.F
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-12-24T09:52:54.630Z
Comments.Text: The model is the original mobilenet SSD (I linked the paper), where only the number of classes has been modified. I added the number of training images and the link to the mentioned example. As for the relative size of objects, it varies a lot but I don't have precise information about that. I will check and try to provide some more information
Comments.UserDisplayName: firion
Tags: <datasets><object-recognition>
Title: When training an object detection network for one class, should I include empty images in the dataset?
UserDisplayName: firion
ThreadText: # When training an object detection network for one class, should I include empty images in the dataset?
  
  (Asked by: username_0 on 2018-12-21)
  
  I fine tuned [MobileNetSSD](https://arxiv.org/pdf/1704.04861.pdf) for object detection using a dataset with just one class (~4000 images). All the training images include at least one bounding box related to that class (no empty images). By following the [example](https://github.com/chuanqi305/MobileNet-SSD) with the VOC dataset, the labelmap includes two classes, the background and my custom class. However, as I mentioned, there are no annotations related to the background and I am not sure if there should be any.
  
  Now my fine tuned network performs very well when objects belonging to my class are present, however there are some false detections with very high confidence when the class is not present. Can this be related to the fact that I don't have empty images in my training set?
  
  **Tags:** datasets, object-recognition
  
  > **Comments:**
  > **username_1**: It could be. It would help if you describe your model and its output (how does it do the object detection?) as well as your training data (number of training samples, relative size of object in images)..  
  > **username_0**: The model is the original mobilenet SSD (I linked the paper), where only the number of classes has been modified. I added the number of training images and the link to the mentioned example. As for the relative size of objects, it varies a lot but I don't have precise information about that. I will check and try to provide some more information  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_2 on 2018-12-29. Score: 1
  
  It is correct that to eliminate the false positives, the training must include images that reflect true negative cases. The objective of training is not this.
  
  > Find the objects of class $O$ in scene $X$.
  
  It is this.
  
  > Find any objects of class $O$ in scene $X$.
  
  Training is effective when sample $S$ is drawn according to the same distribution as will be used for drawing at test time or during actual use.
  
  It is not necessary to annotate the background if the loss function is chosen so that finding nothing when nothing there is indicated as a zero loss and a proper distribution of those cases exist in the training sample.
  
  > **Comments:**
  > **username_0**: Thank you, from a theoretical point of view it is perfectly clear. From a practical point of view, I am not sure whether I should associate background images with empty annotations, as far as MobileNetSSD is concerned. Do you have some information about this?  
  
  ---
  
  