I am training a pre built tensorflow based model for custom object detection. I want to detect only 1 type of object. I have taken lot of images from different angles and in different light conditions. I am training on K80 Nvidia GPU. Everything is working and when I train I can see the loss function falling to 0.3. But the loss values drops very quickly to under 1 when I start training. I am using SSD mobile Net as the base configuration for the model. When I try to test the model, it just draws a big square on the input image, rather than detecting the desired object in the image. Basically, it fails to detect the object.

I tried to train the model with a different set of images of mac n chesse which had lot of variations. Then the model worked fine and detected images of mac n chesse in the input image. But when I have pictures of single object then the model fails to detect. Please help me understand what I am doing wrong here


1 Answer 1


Most likely, not trained enough, keep training.

  1. have at least 500~600 well-labelled images for one Class.
  2. use tensorboard to observe loss trend, keep training till loss doesn't change much. 10K steps normally would do.
  3. try another model, SDD may not be able to extract enough features for certain Class. try Fast RCNN, or inception or hybird model.
  • $\begingroup$ I have to run the model on android phone. That's why SDD seems to be the only option. $\endgroup$
    – Vikas
    Commented Jul 7, 2018 at 11:30
  • $\begingroup$ You didn't mention exact objects you tried, so general answers here. 1. size matters, try reduce resolution to 640*400 or 400*300 before feed into TF. 2. well-labelled images matters, try to have various light condition, orientations, backgrounds, camera angles, etc. 3. share your pipeline.conf see if any misconfigurations $\endgroup$
    – Denny Wang
    Commented Jul 9, 2018 at 19:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.