YOLO3算法loU框标-1问题
收藏
def label_objectness_ignore(label_objectness, iou_above_thresh_indices):
# 注意:这里不能简单的使用 label_objectness[iou_above_thresh_indices] = -1,
# 这样可能会造成label_objectness为1的点被设置为-1了
# 只有将那些被标注为0,且与真实框IoU超过阈值的预测框才被标注为-1
negative_indices = (label_objectness < 0.5)
ignore_indices = negative_indices * iou_above_thresh_indices
label_objectness[ignore_indices] = -1
return label_objectness
请问怎么理解ignore_indices = negative_indices * iou_above_thresh_indices?
0
收藏
请登录后评论
在负样本中,如果有iou大于阈值的,就认为这些样本不是负样本
而是非正非负样本,在算损失函数时非正非负样本好像不记入