Hi, you have within your implementation the condition h > 0 and w > 0 to filter every object out which does not satisfy it. But it seems only possible to hit a 0 on w or h if the down_ratio is larger than the image shape or if the labels from the fetched dataset have <= 0 width or height.
Have you observed such values in one of your used datasets or do you use preprocessing which can cause bbox w and h values to be <= 0?
Plus you seem to use reg_mask to "register" valid objects within the dataset. Is there a reason you called it reg_mask? Do you not use it for loss calculations on wh and re-id too?
Hi, you have within your implementation the condition h > 0 and w > 0 to filter every object out which does not satisfy it. But it seems only possible to hit a 0 on w or h if the down_ratio is larger than the image shape or if the labels from the fetched dataset have <= 0 width or height.
Have you observed such values in one of your used datasets or do you use preprocessing which can cause bbox w and h values to be <= 0?
Plus you seem to use reg_mask to "register" valid objects within the dataset. Is there a reason you called it reg_mask? Do you not use it for loss calculations on wh and re-id too?