ShuangXieIrene / ssds.pytorch

Repository for Single Shot MultiBox Detector and its variants, implemented with pytorch, python3.
MIT License
566 stars 165 forks source link

_expand function in data_augment.py #62

Closed dhananjaisharma10 closed 5 years ago

dhananjaisharma10 commented 5 years ago

Hi!

I was going through the data_augment.py file which uses the _expand function. It enlarges the image where all the pixels are equal to the mean of the images in the dataset and then equates a portion of this bigger image to the original image. Can someone explain the significance of this technique?

Thanks!

foreverYoungGitHub commented 5 years ago

Cause the first step in preprocess in minus the mean value to the original image, that is the reason why setting the background to mean value. The second part is doing the data argumentation to achieve the better performance in different scale of image.