当前位置:网站首页>CVPR21-无监督异常检测《CutPaste:Self-Supervised Learning for Anomaly Detection and Localization》
CVPR21-无监督异常检测《CutPaste:Self-Supervised Learning for Anomaly Detection and Localization》
2022-07-28 17:23:00 【我是大黄同学呀】
原文地址
论文阅读方法
初识
本文主要提出了一个新的增广方法“CutPaste”,并基于此方法提出了一个两阶段的无监督异常检测方法,① 构建分类器区分正常样本与异常样本,作为代理任务(proxy task)学习特征表示;② 根据训练好的网络提取特征,用于检测异常。此方法在MVTec数据集上表现达到新SOTA(检测任务96.6AUC,定位任务96AUC)。
CutPaste:从图像中随机剪切一个块区域,然后随机粘贴在图像的某个区域上。
相知
核心技术

CutPaste
上图展示了正常样本、异常样本以及Cutout和CutPaste等增广方法。作者首先将Cutout应用到两阶段框架中,这看起来似乎是一个可以用简单滤波器就能解决的分类问题,但令人意外的是其竟然可以学习到一些判别性特征,用于异常检测。因此作者将任务变得更难,更改尺度以及变换颜色(Scar),这进一步提升了性能,见下文的实验结果。
作者在此基础上进一步提出了CutPaste:1. 从原图中以某个面积比和长宽比剪切一小块矩形区域;2. 对这个图像块进行选择和颜色抖动;3. 粘贴回原图的某个位置。此外,也产生了scar变体,虽然这两个操作很相似,但产生的图像效果却很不一样,因此采用3分类,将Cutpaste和Cutpaste-scar视为两个类,效果又得到了进一步提升。
异常分数的计算
本文采用简单的带参数密度估计方法(无参数估计需要大量样本,计算复杂度较高)GDE(高斯核的密度估计器),如下所示:

Patch-Level
为了精确的定位,使用Patch-level的方式,使用patch级的图像块作为输入。训练前先从原始图像随机裁剪一个图像块作为输入,然后剩下的操作与之前一样。对于每个图像块,得到异常分数后,使用高斯平滑(Gaussian Smoothing)将分数传递到每个像素点上。
具体实验为:将图像缩放至256x256,patch大小为64x64,测试时,步长为4密集预测,得到异常得分后,首先进行高斯模糊然后再上采样到原图。
最后整个框架如下所示:
理论分析
这一部分很重要,提升了论文高度,也给我带来了很大启发
CutPaste的成功可以从两方面分析,一是从异常曝光(outlier exposure)的角度,相比使用自然图像作为异常样本,CutPaste直接在训练时构建,并且任务更难,这进一步促使模型去学习这种不规律性。
另一方面,CutPaste可以看作是一种对于真实异常的模拟,从t-SNE图可以看出,构造的CutPaste虽然与真实异常样本没有重叠,但它却很好地拉远了正常样本和异常样本在特征空间上的距离。
实验分析

这里主要就放上
Detection任务的实验结果,更多请参看原文
回顾
初看本文时,CVPR还没放榜,后来再调研的时候,发现他们中了。从整篇文章来看,方法确实简单有效,而且立意很高,实验也做得很完善。
不过也有一些值得改进的地方,比如object类随机的cutpaste有可能直接把背景区域又粘贴在背景上?这样强行把他们分成不同的类别是否会损害表征的学习呢?这种增广形式又是否能很好地适应于每个任务呢?
其实文章也告诉我们答案了,对于object的某些类,效果确实就是不好(甚至在fine-tuning的时候效果反而比pre-trained更差了)
开源代码(非官方)
代码官方尚未开源,这里先附上一份非官方代码,感谢作者的无私奉献。
https://github.com/Runinho/pytorch-cutpaste
边栏推荐
- Swiftui swift forward geocoding and reverse geocoding (tutorial with source code)
- 【图像隐藏】基于DCT、DWT、LHA、LSB的数字图像信息隐藏系统含各类攻击和性能参数附matlab代码
- Application of time series database in intelligent power consumption field
- How long does software testing take?
- 当CNN遇见Transformer《CMT:Convolutional Neural Networks Meet Vision Transformers》
- DevCon. Exe export output to the specified file
- Live broadcast platform software development, JS implementation by alphabetical order
- How to obtain data on mobile phones and web pages after the SCM data is uploaded to Alibaba cloud Internet of things platform?
- 力扣 1331. 数组序号转换
- Random finite set RFs self-study notes (6): an example of calculation with the formula of prediction step and update step
猜你喜欢

What if svchost.exe of win11 system has been downloading?

Learn from Li Mu in depth -softmax return

剑指 Offer II 109. 开密码锁
![[physical application] Wake induced dynamic simulation of underwater floating wind turbine wind field with matlab code](/img/31/e4cd4c261a7fc5cfa731976314530b.png)
[physical application] Wake induced dynamic simulation of underwater floating wind turbine wind field with matlab code

BM16 删除有序链表中重复的元素-II

uwb模块实现人员精确定位,超宽带脉冲技术方案,实时厘米级定位应用

How many of the top ten test tools in 2022 do you master

Libgdx learning path 01: libgdx introduction and running tutorial

BM11 链表相加(二)

Nips18(AD) - 利用几何增广的无监督异常检测《Deep Anomaly Detection Using Geometric Transformations》
随机推荐
【物理应用】大气吸收损耗附matlab代码
[physical application] atmospheric absorption loss with matlab code
GPIO port configuration of K60
About ASM redundancy
The wechat installation package has expanded 575 times in 11 years, and the up owner: "98% of the documents are garbage"; Apple App store was exposed to a large number of pornographic apps; Four techn
C language (high-level) character function and string function + Exercise
Application of time series database in intelligent power consumption field
3、 Uni app fixed or direct to a certain page
Creating new projects and adding your own programs
[operation] differences between Oracle, MySQL and sqlserver
Is zero basic software testing training reliable?
图书管理数据库系统设计
Applet applet jump to official account page
Swiftui swift forward geocoding and reverse geocoding (tutorial with source code)
Wechat solves the problem of long press selected style
Can zero basis software testing work?
From Bayesian filter to Kalman filter (I)
BM16 delete duplicate elements in the ordered linked list -ii
How big is it suitable for learning software testing?
【雷达】基于核聚类实现雷达信号在线分选附matlab代码