当前位置:网站首页>目标检测中的损失函数与正负样本分配:RetinaNet与Focal loss
目标检测中的损失函数与正负样本分配:RetinaNet与Focal loss
2022-07-07 00:26:00 【cartes1us】
RetinaNet
在目标检测领域,单阶段算法精度第一次超过双阶段,就是RetinaNet。
网络结构:
作者设计的网络结构没有太大创新,文中是这样说的:
The design of our RetinaNet detector shares many similarities with
previous dense detectors, in particular the concept of ‘anchors’
introduced by RPN [3] and use of features pyramids as in SSD [9] and
FPN [4]. We emphasize that our simple detector achieves top results
not based on innovations in network design but due to our novel loss.
检测头是分类与BBox回归解耦的,并且是基于锚框的,经过FPN后输出五层不同尺度的特征图,每层分别对应32~512尺度的锚框,并且每层根据scale和ratios的不同组合有9种锚框,最终整个网络的锚框尺寸是32 ~ 813之间。使用网络预测的相对锚框的偏移量来计算BBox的方法与Faster R-CNN相同。下图是霹雳吧啦的图。
论文中的结构图如下,只示意了由FPN引出的三种尺度的特征图,W,H,K,A分别代表特征图宽,高,分类数量(不包含背景类),锚框数量(9)。 
正负样本匹配
正样本:预测的BBox 与gt IoU>=0.5,
负样本:预测的BBox 与gt IoU<0.4,
其他样本舍弃
前景,背景数量不平衡问题
CE损失的变种
本作的最大创新:Focal loss,改写经典的交叉熵损失,应用在class subnet分支,使易分类样本的损失的权重极大降低,形式很优美。论文中 γ \gamma γ推荐取2,若 γ \gamma γ取0,则FL就退化为了CE。
损失:

第一项分类损失中是计算所有样本(包括正负)的Focal loss,然后除去正样本数量 N p o s N_{pos} Npos。BBox回归损失是Fast R-CNN中提出的smooth L1 loss。
未完待续
边栏推荐
猜你喜欢

Leakage relay jelr-250fg

Preliminary practice of niuke.com (9)

The year of the tiger is coming. Come and make a wish. I heard that the wish will come true

Leetcode: maximum number of "balloons"
![[PM products] what is cognitive load? How to adjust cognitive load reasonably?](/img/75/2277e0c413be561ec963b44679eb75.jpg)
[PM products] what is cognitive load? How to adjust cognitive load reasonably?

The 2022 China low / no code Market Research and model selection evaluation report was released

JSP setting header information export to excel

常用消息队列有哪些?

软件测试面试技巧

Three level menu data implementation, nested three-level menu data
随机推荐
MySQL-CentOS7通过YUM安装MySQL
Flinksql 读写pgsql
Flink SQL realizes reading and writing redis and dynamically generates hset key
SAP ABAP BDC (batch data communication) -018
微信小程序蓝牙连接硬件设备并进行通讯,小程序蓝牙因距离异常断开自动重连,js实现crc校验位
How to get free traffic in pinduoduo new store and what links need to be optimized in order to effectively improve the free traffic in the store
Message queue: how to handle repeated messages?
分布式事务解决方案之2PC
Leetcode: maximum number of "balloons"
Differences and introduction of cluster, distributed and microservice
The 2022 China low / no code Market Research and model selection evaluation report was released
4. Object mapping Mapster
拼多多新店如何获取免费流量,需要从哪些环节去优化,才能有效提升店内免费流量
SAP ABAP BDC(批量数据通信)-018
Paper reading [MM21 pre training for video understanding challenge:video captioning with pre training techniqu]
Zero sequence aperture of leakage relay jolx-gs62 Φ one hundred
ForkJoin最全详解(从原理设计到使用图解)
【已解决】记一次EasyExcel的报错【读取xls文件时全表读不报错,指定sheet名读取报错】
淘寶商品詳情頁API接口、淘寶商品列錶API接口,淘寶商品銷量API接口,淘寶APP詳情API接口,淘寶詳情API接口
基于NCF的多模块协同实例