I have some questions about the calculation of mIoU in the core/utils/score.py
I will be very grateful if you could give me a favor.
In my understanding, the codes below calcluate the area_inter and area_union for all images in a batch:
area_inter = area_inter_image1+area_inter_image2+...+area_inter_imageN
area_union = area_union_image1+area_union_image2+...+area_union_imageN
Then the IoU = area_inter / area_union
But I think it should be:
IoU = mean(area_inter_image1/area_union_image1+area_inter_image2/area_union_image2+...+area_inter_imageN/area_union_imageN)
If my understanding is wrong, please point it out, thank you!
I have some questions about the calculation of mIoU in the core/utils/score.py
I will be very grateful if you could give me a favor.
In my understanding, the codes below calcluate the area_inter and area_union for all images in a batch: area_inter = area_inter_image1+area_inter_image2+...+area_inter_imageN area_union = area_union_image1+area_union_image2+...+area_union_imageN Then the IoU = area_inter / area_union
But I think it should be: IoU = mean(area_inter_image1/area_union_image1+area_inter_image2/area_union_image2+...+area_inter_imageN/area_union_imageN)
If my understanding is wrong, please point it out, thank you!
def batch_intersection_union(output, target, nclass) """mIoU"""
inputs are numpy array, output 4D, target 3D