Skip to main content
QUICK REVIEW

[论文解读] A Unified Model for Multi-class Anomaly Detection

Zhiyuan You, Lei Cui|arXiv (Cornell University)|Jun 8, 2022
Anomaly Detection Techniques and Applications被引用 87
一句话总结

UniAD 提出一个统一框架,在多类中无需微调就能检测并定位异常,解决基于重建的方法中的身份捷径问题,采用逐层查询解码、邻域掩蔽注意力和特征抖动。

ABSTRACT

Despite the rapid advance of unsupervised anomaly detection, existing methods require to train separate models for different objects. In this work, we present UniAD that accomplishes anomaly detection for multiple classes with a unified framework. Under such a challenging setting, popular reconstruction networks may fall into an "identical shortcut", where both normal and anomalous samples can be well recovered, and hence fail to spot outliers. To tackle this obstacle, we make three improvements. First, we revisit the formulations of fully-connected layer, convolutional layer, as well as attention layer, and confirm the important role of query embedding (i.e., within attention layer) in preventing the network from learning the shortcut. We therefore come up with a layer-wise query decoder to help model the multi-class distribution. Second, we employ a neighbor masked attention module to further avoid the information leak from the input feature to the reconstructed output feature. Third, we propose a feature jittering strategy that urges the model to recover the correct message even with noisy inputs. We evaluate our algorithm on MVTec-AD and CIFAR-10 datasets, where we surpass the state-of-the-art alternatives by a sufficiently large margin. For example, when learning a unified model for 15 categories in MVTec-AD, we surpass the second competitor on the tasks of both anomaly detection (from 88.1% to 96.5%) and anomaly localization (from 89.5% to 96.8%). Code is available at https://github.com/zhiyuanyou/UniAD.

研究动机与目标

  • 推动并实现使用单一模型对多类对象进行异常检测,而非分别使用单类模型。
  • 识别并缓解基于重建的异常检测中的“身份捷径”问题,特别是在统一的多类设置下。
  • 开发能够在防止轻易重建异常的同时,保持多类分布建模的架构与训练策略。
  • 在统一的多对多设置下,在标准基准(MVTec-AD 和 CIFAR-10)上展示最先进的性能。

提出的方法

  • 采用带有固定骨干特征提取器的基于变换器的特征重建框架。
  • 引入一个 Neighbor Masked Attention (NMA) 模块,在重建过程中防止输入信息向输出泄漏。
  • 实现 Layer-wise Query Decoder (LQD),在每个解码层利用可学习的查询嵌入,增强对多类分布的建模。
  • 应用 Feature Jittering (FJ) 来扰动输入特征,将重建任务转化为去噪,提高对嘈杂输入的鲁棒性。
  • 使用原始特征与重建特征之间的标准 MSE 损失进行训练,通过重建差异实现异常定位。
  • 使用固定的 EfficientNet-B4 作为多阶段特征提取骨干,并在各阶段拼接特征以进行重建。

实验结果

研究问题

  • RQ1在不进行针对具体类别的微调的情况下,单一统一模型是否能有效检测并定位多类对象的异常?
  • RQ2在统一的多类设置中,如何让基于重建的异常检测避免身份捷径?
  • RQ3像查询嵌入、掩蔽注意力和特征抖动这样的架构选择,是否比标准变换器在异常检测上有更好表现?
  • RQ4在统一设置下,这些组件对异常检测精度和定位的影响是多少?
  • RQ5在统一设置与分离设置下,UniAD 相对于最先进方法在 MVTec-AD 和 CIFAR-10 上的表现如何?

主要发现

  • 在统一设置下,UniAD 在 MVTec-AD 上实现了最先进的异常检测与定位,在两个任务上均显著超过此前最好的方法。
  • 在 15 类的统一模型中,MVTec-AD 的异常检测 AUROC 从 88.1%(之前最佳)提升到 96.5%,定位从 89.5% 提升到 96.8%。
  • 在统一设置下,单个 UniAD 模型在各类别上保持高性能且无需微调,与分开情况下的性能相比降幅很小。
  • 逐层查询嵌入、邻域掩蔽注意力和特征抖动共同贡献了出色的性能,消融实验证实了每个组件的重要性。
  • 在统一设置下的 CIFAR-10 上,UniAD 在四个类别组合中优于基线,平均 AUROC 达到 87.2%,且不需要辅助离群暴露。

更好的研究,从现在开始

从阅读论文到最终审阅,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。