mscnn icon indicating copy to clipboard operation
mscnn copied to clipboard

why `width_ / spatial_scale_` in roi_pooling layer?

Open zimenglan-sysu-512 opened this issue 9 years ago • 1 comments

```

// clipping roi_start_w = max(roi_start_w,0); roi_start_h = max(roi_start_h,0); int img_width = round(width_/spatial_scale_); int img_height = round(height_/spatial_scale_); roi_end_w = min(img_width-1,roi_end_w); roi_end_h = min(img_height-1,roi_end_h);

here, why `width_ / spatial_scale_`?

zimenglan-sysu-512 avatar Sep 06 '16 13:09 zimenglan-sysu-512

It is a bug. It should be roi_end_w = min(width, roi_end_w). It is identical to the case without clipping. But there is another clipping constraint in lines 67-70. To make sure the others can achieve exactly the same results with the pre-trained models, we just leave this bug unfixed for now.

zhaoweicai avatar Sep 14 '16 21:09 zhaoweicai