Introduction
In automated industrial inspection, identifying anomalies is a critical but challenging task. While "normal" samples are abundant, defects are rare and unpredictable, creating a significant data imbalance that makes traditional supervised learning impractical. Unsupervised methods, which learn exclusively from defect-free samples, are the preferred alternative. However, existing models often struggle to balance the detection of subtle texture irregularities (e.g., scratches) with complex object-level defects (e.g., missing components). They are also frequently sensitive to non-defect variations like lighting or positioning.
SCL-VI (Self-supervised Context Learning for Visual Inspection) addresses these challenges by introducing a robust framework that learns deep semantic context through a "jigsaw puzzle" pretext task. By combining context-aware feature extraction with a novel affinity-augmentation module, the system distinguishes between true anomalies and harmless natural variations.
Methodology
The SCL-VI framework is built upon three core components designed to capture both local detail and global structure:
- Context Learning Feature Extraction: To establish a baseline for "normality," the model performs a pretext task where it predicts the relative positions of patches within a 3x3 grid. Unlike previous methods that only compare surrounding patches to a center block, SCL-VI compares any two random patches, forcing a more flexible understanding of product structure. To prevent the model from relying on simple edge continuities, random jittering and color dithering are applied.
- Patchwise Feature Discrimination: Utilizing the Support Vector Data Description (SVDD) algorithm, the model maps normal image features into high-dimensional hyperspheres. During the inspection phase, any feature falling significantly outside these spheres is flagged as an outlier.
- Affinity-Augmented Fusion Module: This module improves stability by calculating a weighted average of the top $N$ most similar normal features rather than relying on a single nearest neighbor. This "panel of experts" approach smooths out noise and reduces false positives caused by unusual but normal training samples.
Experimental Results
The researchers evaluated SCL-VI on the MVTec AD benchmark, which includes 15 categories of textures and objects. The model established a new state-of-the-art, achieving a 95.8% AUROC for detection and a 96.8% AUROC for segmentation (localization). Notably, the model maintained high performance across both textures (98.32%) and objects (94.56%), overcoming the historical trade-off between these categories.
Beyond benchmarks, SCL-VI demonstrated practical utility on real-world datasets like Suede Silicon Wafers (SSW), achieving 99.9% detection accuracy. This significantly outperformed traditional reconstruction-based methods like AE-SSIM, which reached only 67.8% on the same data.
Conclusion
SCL-VI provides a powerful, self-supervised solution for industrial visual inspection. By leveraging context learning and affinity-augmented fusion, it achieves superior accuracy and robustness against noise. While extremely slender or low-contrast defects remain a challenge for patch-based methods, future work on multi-scale encoders and enhanced preprocessing aims to further refine the detection of these subtle flaws in high-resolution environments.
Summary updated