π€ AI Summary
Generalized Anomaly Detection (GAD) aims to train a source-domain model that generalizes to unseen target domains for anomaly identification. Existing approaches exclusively leverage source-domain normal samples, overlooking discriminative information embedded in readily available source-domain anomalies. This paper proposes the first GAD paradigm that jointly utilizes both normal and anomalous source samples as references. We design a Residual Mining (RM) module to extract domain-agnostic abnormal patterns and introduce an Anomaly Feature Learning (AFL) mechanism that enables instance-level anomaly localization on query images via residual mapping. Extensive experiments across multiple benchmarks demonstrate substantial improvements over state-of-the-art methods, validating the effectiveness of our transferable anomaly representation learning framework. The code and datasets are publicly released.
π Abstract
Generalist Anomaly Detection (GAD) aims to train a unified model on an original domain that can detect anomalies in new target domains. Previous GAD methods primarily use only normal samples as references, overlooking the valuable information contained in anomalous samples that are often available in real-world scenarios. To address this limitation, we propose a more practical approach: normal-abnormal-guided generalist anomaly detection, which leverages both normal and anomalous samples as references to guide anomaly detection across diverse domains. We introduce the Normal-Abnormal Generalist Learning (NAGL) framework, consisting of two key components: Residual Mining (RM) and Anomaly Feature Learning (AFL). RM extracts abnormal patterns from normal-abnormal reference residuals to establish transferable anomaly representations, while AFL adaptively learns anomaly features in query images through residual mapping to identify instance-aware anomalies. Our approach effectively utilizes both normal and anomalous references for more accurate and efficient cross-domain anomaly detection. Extensive experiments across multiple benchmarks demonstrate that our method significantly outperforms existing GAD approaches. This work represents the first to adopt a mixture of normal and abnormal samples as references in generalist anomaly detection. The code and datasets are available at https://github.com/JasonKyng/NAGL.