Fast Anomaly Detection for Vision-Based Industrial Inspection Using Cascades of Null Subspace PCA Detectors - Muhammad Bilal; Muhammad Shehzad Hanif (Sensors)
Anomaly detection in industrial imaging is critical for ensuring quality and reliability in automated manufacturing processes. While recently several methods have been reported in the literature that have demonstrated impressive detection performance on standard benchmarks, they necessarily rely on computationally intensive CNN architectures and post-processing techniques, necessitating access to high-end GPU hardware and limiting practical deployment in resource-constrained settings. In this study, we introduce a novel anomaly detection framework that leverages feature maps from a lightweight convolutional neural network (CNN) backbone, MobileNetV2, and cascaded detection to achieve notable accuracy as well as computational efficiency. The core of our method consists of two main components. First is a PCA-based anomaly detection module that specifically exploits near-zero variance features. Contrary to traditional PCA methods, which tend to focus on the high-variance directions that encapsulate the dominant patterns in normal data, our approach demonstrates that the lower variance directions (which are typically ignored) form an approximate null space where normal samples project near zero. However, the anomalous samples, due to their inherent deviations from the norm, lead to projections with significantly higher magnitudes in this space. This insight not only enhances sensitivity to true anomalies but also reduces computational complexity by eliminating the need for operations such as matrix inversion or the calculation of Mahalanobis distances for correlated features otherwise needed when normal behavior is modeled as Gaussian distribution. Second, our framework consists of a cascaded multi-stage decision process. Instead of combining features across layers, we treat the local features extracted from each layer as independent stages within a cascade. This cascading mechanism not only simplifies the computations at each stage by quickly eliminating clear cases but also progressively refines the anomaly decision, leading to enhanced overall accuracy. Experimental evaluations on MVTec and VisA benchmark datasets demonstrate that our proposed approach achieves superior anomaly detection performance (99.4% and 91.7% AUROC respectively) while maintaining a lower computational overhead compared to other methods. This framework provides a compelling solution for practical anomaly detection challenges in diverse application domains where competitive accuracy is needed at the expense of minimal hardware resources.