当前位置:网站首页>YOLOv5解析 | 参数与性能指标
YOLOv5解析 | 参数与性能指标
2022-06-13 06:33:00 【K同学啊】
传参
conf_thres:Confidence Threshold,置信度阈值,即以下图片上的值。只显示预测概率超过conf_thres的预测结果。

iou_thres:Intersect over Union Threshold,交并比阈值。- IOU值:预测框大小∩真实框大小 / 预测框大小∪真实框大小。预测框与真实框的交集与并集的取值。
- iou_thres在detect.py中:
- 越大,则容易将对于同一个物品的不同预测结果 当成 对多个物品的多个预测结果,导致一个物品出现了多个预测结果。
- 越小,则容易将对于多个物品的不同预测结果 当成 对同一个物品的不同预测结果,导致多个物品只出现了一个预测结果。
评估参数
P(Precision),精确率,对类A来说(下面提到的都是被预测成A的):- P = 正确数 / 预测总数
- 或 P = 正确数/ 正确数+错误数
- 即,预测的东西正确了多少百分比。
R(Recall),召回率,对类A来说(下面提到的都是被归为A类的):- R = 预测正确数 / 真实A类总数。
- 或 R = 预测正确数 / 被预测到的A + 未被预测到的A
- 即,预测的东西找到了多少百分比。
F1(F-Measure),F值,P与R的调和平均- F=1/(λ1P+(1−λ)1R),λ = 0.5时,简化为F1
- F1 = 2PR / (P + R)
例:对于一个二分类问题来说:
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
要对动物进行分类,分为猫与非猫两类。样本中,猫有350份,非猫有150份。预测出了400份被认为是猫,其中,正确的有300份,错误的有100份。则:P = 300 / 400 = 0.75、R = 300 / 350 ≈ 0.86
PR图:横坐标是R值,纵坐标是P值,曲线表示当召回率为R时,精确率P的大小。
例:假设测试集图片数量为一百张,且测试了一百张。
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
- 当A类的R值设为0时,表示以某精确度P1计算,没有检测到A类。
- 当A类的R值设为0.1时,表示以某精确度P2计算,检测到了A类总数的10%。
. . . . . . .以此类推,当A类的R值设为1时,表示以某精确度P11计算,检测到了所有的A类标签。可以看出,随R值的升高,A被预测到的数量也会增加,即那些可能性较低的A类也逐渐被预测出来。因此,可以判断P值是随着R的升高而降低。P值如果设为100,即要求被标记出来的区域一定属于A类,这种概率非常低,所以可能一个A类都识别不出来,进而导致R值为0。而若P值设为0.1,则要求被标记出来的区域只要有百分十的概率属于A类即可,那么将有很多A类被标记,R值也进一步提高。因此,PR图左下方的面积越大,则表示模型对该数据集的效果越好。
AP(Average Precision):以某种方式计算AP值来表达PR图的面积mAP(mean Average Precision):每个类的AP值的平均数。用于表达多类标签预测的性能,如AP一样,mAP越高,性能越好。[email protected]:当IoU为0.5时的mAP。[email protected] : .95:当IoU为range(0.5 : 0.95 : 0.05)时的mAP的平均数。
边栏推荐
- Win10 drqa installation
- Kotlin basic objects, classes and interfaces
- The causes of font and style enlargement when the applet is horizontal have been solved
- Dynamic link library nesting example
- 景联文科技:数据采集标注行业现状及解决方案
- Kotlin collaboration channel
- Notepad++ settings delete current line shortcut
- MFS详解(六)——MFS Chunk Server服务器安装与配置
- 105. constructing binary trees from preorder and inorder traversal sequences
- Notifyitemchanged flash back
猜你喜欢
![[system analysis and design] college student association management system](/img/8f/a23dbdcba7c6afe7d7ce3abba2865c.jpg)
[system analysis and design] college student association management system

十六、IO流(二)
![[2022 college entrance examination season] what I want to say as a passer-by](/img/d7/3813b944dc2df182455d475a3669fb.jpg)
[2022 college entrance examination season] what I want to say as a passer-by

Notepad++ settings delete current line shortcut

【sketchup 2021】草图大师中CAD文件的导入与建模(利用cad图纸在草图大师中建立立面模型)、草图大师导出成品为dwg格式的二维、三维、立面效果到cad中打开预览】

Jetpack - basic use of room

JS case Xiaomi second kill countdown New Year Countdown

RN Metro packaging process and sentry code monitoring

【2022高考季】作为一个过来人想说的话

Jinglianwen technology provides voice data acquisition and labeling services
随机推荐
vue3路由缓存组件状态以及设置转场动画
Thread correlation point
The processing and application of C language to documents
【sketchup 2021】草图大师的图像输出与渲染之样式说明【边线设置、平面设置、背景设置、水印设置、建模设置、天空背景创建天空、利用水印背景创建天空(重要)】
Do you want to carry out rapid steel mesh design and ensure the quality of steel mesh? Look here
Brief introduction to basic usage of echart
Failed to extract manifest from apk: processexception:%1 is not a valid Win32 Application.
SSM框架整合--->简单后台管理
An article allows you to quickly understand the fission growth password of social e-commerce user marketing and avoid stepping on the pit
1154. 一年中的第几天
[virtual machine] VMware virtual machine occupies too much space. Solution
Glide usage notes
Subtotal of constraintlayout
【sketchup 2021】草图大师中CAD文件的导入与建模(利用cad图纸在草图大师中建立立面模型)、草图大师导出成品为dwg格式的二维、三维、立面效果到cad中打开预览】
Kotlin basic objects, classes and interfaces
[SketchUp 2021] CAD file import and modeling in the sketch master (establish elevation model in the sketch master by using CAD drawings), and the sketch master exports 2D, 3D and elevation effects of
MFS详解(七)——MFS客户端与web监控安装配置
Win10 drqa installation
Thread pool learning
Ijkplayer code walkthrough player network video data reading process details