Industrial anomaly detection (IAD) algorithms are essential for implementing automated quality inspection. Dataset diversity serves as the foundation for developing comprehensive detection algorithms. Existing IAD datasets focus on the diversity of objects and defects, overlooking the diversity of domains within the real data. To bridge this gap, this study proposes the Casting Surface Defect Detection (CSDD) dataset, containing 12,647 high-resolution gray images and pixel-precise ground truth labels for all defect samples. Compared to existing datasets, CSDD has the following two characteristics: 1.) The target samples are unaligned and have complex and variable context information. 2.) The defects in the CSDD dataset samples are subtle and confusable by factors such as oil contamination, processing features, and machining marks, illustrating the challenge of detecting real casting defects in an industrial context. Based on this dataset, we observe that current state-of-the-art (SOTA) IAD methods face challenges when there is considerable variation in sample context information. Furthermore, these methods encounter difficulties when abnormal samples are scarce, particularly those samples with subtle and confusable defects. To address this issue, we propose a novel method called Realistic Synthetic Anomalies (RSA), which enhances the model’s capacity to construct a normal sample distribution by generating a large number of realistic synthetic anomalies. Experimental results demonstrate that the model trained to classify synthetic anomalies from normal samples achieves the highest accuracy for casting surface defect detection and significantly improves detection accuracy for subtle and confusable defects. The CSDD dataset and code of RSA are available at https://github.com/18894269590/RSA.
Interactive devices such as touch screens have gained widespread usage in daily life; this has directed the attention of researchers to the quality of screen glass. Consequently, defect detection in screen glass is essential for improving the quality of smartphone screens. In recent years, defect detection methods based on deep learning have played a crucial role in improving detection accuracy and robustness. However, challenges have arisen in achieving high-performance detection due to the small size, irregular shapes and low contrast of defects. To address these challenges, this paper proposes CE-SGNet, a Context-Enhanced Network with a Spatial-aware Graph, for smartphone screen defect detection. It consists of two novel components: the Adaptive Receptive Field Attention Module (ARFAM) and the Spatial-aware Graph Reasoning Module (SGRM). The ARFAM enhances defect features by adaptively extracting contextual information to capture the most relevant contextual region of defect features. The SGRM constructs a region-to-region graph and encodes region features with spatial relationships. The connections among defect regions are enhanced during the propagation process through a graph attention network. By enriching the feature representations of defect regions, the CE-SGNet can accurately identify and locate defects of various shapes and scales. Experimental results demonstrate that the CE-SGNet achieves outstanding performance on two public datasets.
Industrial anomaly detection is a challenging open-set task that aims to identify unknown anomalous patterns deviating from normal data distribution. To avoid the significant memory consumption and limited generalizability brought by building separate models per class, we focus on developing a unified framework for multi-class anomaly detection. However, under this challenging setting, conventional reconstruction-based networks often suffer from an identity mapping problem, where they directly replicate input features regardless of whether they are normal or anomalous, resulting in detection failures. To address this issue, this study proposes a novel framework termed Collaborative Reconstruction and Repair (CRR), which transforms the reconstruction to repairation. First, we optimize the decoder to reconstruct normal samples while repairing synthesized anomalies. Consequently, it generates distinct representations for anomalous regions and similar representations for normal areas compared to the encoder's output. Second, we implement feature-level random masking to ensure that the representations from decoder contain sufficient local information. Finally, to minimize detection errors arising from the discrepancies between feature representations from the encoder and decoder, we train a segmentation network supervised by synthetic anomaly masks, thereby enhancing localization performance. Extensive experiments on industrial datasets that CRR effectively mitigates the identity mapping issue and achieves state-of-the-art performance in multi-class industrial anomaly detection.
Multi-class Unsupervised Anomaly Detection algorithms (MUAD) are receiving increasing attention due to their relatively low deployment costs and improved training efficiency. However, the real-world effectiveness of MUAD methods is questioned due to limitations in current Industrial Anomaly Detection (IAD) datasets. These datasets contain numerous classes that are unlikely to be produced by the same factory and fail to cover multiple structures or appearances. Additionally, the defects do not reflect real-world characteristics. Therefore, we introduce the Heterogeneous Same-Sort Industrial Anomaly Detection (HSS-IAD) dataset, which contains 8,580 images of metallic-like industrial parts and precise anomaly annotations. These parts exhibit variations in structure and appearance, with subtle defects that closely resemble the base materials. We also provide foreground images for synthetic anomaly generation. Finally, we evaluate popular IAD methods on this dataset under multi-class and class-separated settings, demonstrating its potential to bridge the gap between existing datasets and real factory conditions. The dataset is available at https://github.com/Qiqigeww/HSS-IAD-Dataset.