gluon-cv icon indicating copy to clipboard operation
gluon-cv copied to clipboard

Why isn't negative sampling used during the training of ssd detector?

Open allgrom opened this issue 6 years ago • 2 comments

Hi! Why isn't negative sampling used during the training of ssd detector?

self._target_generator = SSDTargetGenerator(
            iou_thresh=iou_thresh, stds=box_norm, negative_mining_ratio=-1, **kwargs)

allgrom avatar Sep 24 '18 18:09 allgrom

TLDR. It's moved to MultiBoxLoss. Reason: OHEM is dependent on prediction value, but we want to pre-compute all targets using cpu cores during data loading. Instead we can use cpu to compute all targets and mask out negative samples in MultiBoxLoss

zhreshold avatar Sep 24 '18 20:09 zhreshold

Thank you!

allgrom avatar Sep 25 '18 11:09 allgrom