Search code examples
tensorflowcaffedetectionobject-detection

Is the object location in train effect the results for Faster RCNN?


Has enyone try the effect of the location per class in faster rcnn?

In case my train data has one of the object classes always in one area of the frame, lets say in the top right of the image, and on the evaluation dataset I have one image that this object is on other area, down left, Is the Faster RCNN capable to handle with this case?

Or if I want my network to find all of the classes in all of the frame areas I need to provide example in the train dataset that cover all the areas?


Solution

  • Quoting faster-RCNN paper:

    An important property of our approach is that it is translation invariant, both in terms of the anchors and the functions that compute proposals relative to the anchors. If one translates an object in an image, the proposal should translate and the same function should be able to predict the proposal in either location. This translation-invariant property is guaranteed by our method*

    *As is the case of FCNs [7], our network is translation invariant up to the network’s total stride

    So the short answer is that you'll probably be ok with the object is mostly at a certain location in the train set and somewhere else in the test set.

    A bit longer answer is that the location may have side affects that may affect the accuracy and it will probably be better to have the object in different locations; however you can try to add - for testing purposes - N test samples to the train set and see what is the accuracy change in the test set -N remaining samples.