Breaking the Bias: Recalibrating the Attention of Industrial Anomaly Detection
Xin Chen, Liujuan Cao, Shengchuan Zhang, Xiewu Zheng, Yan Zhang
TL;DR
Industrial anomaly detection under unsupervised learning faces attention bias toward variable regions in normal samples. The paper proposes RAAD, a two-stage framework that first reduces bias via hierarchical quantization and then enhances defect sensitivity through fine-tuning, guided by Hierarchical Quantization Scoring (HQS) which allocates bit-width across network layers. Evaluations across 32 datasets (including MVTec AD, MVTec LOCO-AD, and VisA) show RAAD improves both image-level detection (AUROC) and pixel-level localization (AU-PRO/PRO) and outperforms state-of-the-art baselines, while enabling efficient on-device inference through mixed-precision quantization. The approach combines a lightweight teacher-student PDN with an autoencoder to balance local and global cues, delivering robust performance with reduced computational demands for industrial inspection tasks.
Abstract
Due to the scarcity and unpredictable nature of defect samples, industrial anomaly detection (IAD) predominantly employs unsupervised learning. However, all unsupervised IAD methods face a common challenge: the inherent bias in normal samples, which causes models to focus on variable regions while overlooking potential defects in invariant areas. To effectively overcome this, it is essential to decompose and recalibrate attention, guiding the model to suppress irrelevant variations and concentrate on subtle, defect-susceptible areas. In this paper, we propose Recalibrating Attention of Industrial Anomaly Detection (RAAD), a framework that systematically decomposes and recalibrates attention maps. RAAD employs a two-stage process: first, it reduces attention bias through quantization, and second, it fine-tunes defect-prone regions for improved sensitivity. Central to this framework is Hierarchical Quantization Scoring (HQS), which dynamically allocates bit-widths across layers based on their anomaly detection contributions. HQS dynamically adjusts bit-widths based on the hierarchical nature of attention maps, compressing lower layers that produce coarse and noisy attention while preserving deeper layers with sharper, defect-focused attention. This approach optimizes both computational efficiency and the model' s sensitivity to anomalies. We validate the effectiveness of RAAD on 32 datasets using a single 3090ti. Experiments demonstrate that RAAD, balances the complexity and expressive power of the model, enhancing its anomaly detection capability.
