You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the forward path of the MultiBoxLoss() class the amount of present ground truth boxes in every image is calculated:
n_objects = boxes[i].size(0)
overlap = find_jaccard_overlap(boxes[i],self.priors_xy) # (n_objects, 8732)
# For each prior, find the object that has the maximum overlap
overlap_for_each_prior, object_for_each_prior = overlap.max(dim=0) # (8732)
When I try to calculate the loss for images w/o any objects, this throws the following error:
IndexError: max(): Expected reduction dim 0 to have non-zero size.
I guess the current code doesn't work for a training dataset that contains empty images, right?
The used dataset for this tutorial (PascalVOCDataset) doesn't cover that case.
The text was updated successfully, but these errors were encountered:
Hi,
In the forward path of the MultiBoxLoss() class the amount of present ground truth boxes in every image is calculated:
When I try to calculate the loss for images w/o any objects, this throws the following error:
IndexError: max(): Expected reduction dim 0 to have non-zero size.
I guess the current code doesn't work for a training dataset that contains empty images, right?
The used dataset for this tutorial (PascalVOCDataset) doesn't cover that case.
The text was updated successfully, but these errors were encountered: