How Does Padding Impact Performance?
Hello,
In the current preprocessing pipeline, the input images are padded. I'm curious if you have done any experiments without padding, and if so, how does it impact the mAP score?
I'm also curious about the reasoning behind choosing to pad the images. Is it to preserve box ratios? If so, is it worth the tradeoff paid in the vastly fewer pixels to be working with?
Thanks!
Padding has not much effect on mAP, actually. Detection backbone have some requirements(every stage has its own stride, or refer this) , so padding image to given size is necessry.
I made a quick n dirty test to remove the padding. Seems some is still necessary to guarantee that the dimensions are divisible by 32, but otherwise it worked OK and inferences were sped up significantly.
There were however weird, very small, offsets in the output when doing this. Not sure if this padding is strictly necessary or if it can be removed as long as you tweak the post-processing a bit.
If i remember correctly I tried this on 16:10 or 16:9 images.
@rsomani95 did you pursue this any further?