对于检测目标为dog
的蓝色检测框,和ground truth_dog(黄色框)的IoU>0.5,为True Positive(TP)
![image-20230517081718287](https://gitee.com/dctwan/blog-image/raw/master/image-20230517081718287.png)
对于检测目标为dog
的蓝色检测框,和ground truth_dog(黄色框)的IoU<0.5,为False Positive(FP)
![image-20230517082004244](https://gitee.com/dctwan/blog-image/raw/master/image-20230517082004244.png)
对于检测目标为Non
的蓝色检测框,和ground truth_dog(黄色框)的IoU>0.5,为False Negative(FN)
![image-20230517082140889](https://gitee.com/dctwan/blog-image/raw/master/image-20230517082140889.png)
Precision(精准度),检测器检测出来是dog且真实是dog占所有检测器认为是dog的比例
\[P = \frac{TP}{TP+FP} \]Recall(召回率),检测器检测出是dog且真实是dog占所有真实是dog的比例
\[R = \frac{TP}{TP+FN} \]对于IoU>0.5,0.5是阈值threshold,随着阈值的改变,会影响TP、FP、FN,进而影响P和R,从threshold=0开始,递增改变threshold,计算出针对每个threshold的P和R,描点(P,R)作图,即PR曲线
![image-20230517083139822](https://gitee.com/dctwan/blog-image/raw/master/image-20230517083139822.png)
更高的P和R是我们追求的目标,但二者是矛盾的关系,追求更高的P则R必然会下降,反之亦然
为了权衡选择,将PR曲线下的面积作为衡量标准,即AP(Average Precision)
目标检测问题可能需要检测多个类别:dog,bicycle,car...,计算每个类别的AP然后取平均值即为mAP
参考:https://blog.csdn.net/qianbin3200896/article/details/103990474
标签:mAP,检测,0.5,dog,TP,AP,threshold From: https://www.cnblogs.com/dctwan/p/17407450.html