Skip to content

Conversation

@chenmingxiang110
Copy link

In case the best_gt_idx is not found

@weros21
Copy link

weros21 commented Jan 27, 2025

for idx, gt in enumerate(ground_truth_img): iou = intersection_over_union( torch.tensor(detection[3:]), torch.tensor(gt[3:]), box_format=box_format, ) if iou > best_iou: best_iou = iou best_gt_idx = idx

Have you also noticed something strange here that we not verify that best_gt_idx is not used yet ?

I think it is correct

for idx, gt in enumerate(ground_truth_img): iou = intersection_over_union( torch.tensor(detection[3:]), torch.tensor(gt[3:]), box_format=box_format, ) if amount_bboxes[detection[0]][idx] == 0 and iou > best_iou: best_iou = iou best_gt_idx = idx
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants