Gaussian Anomaly Detection by Modeling the Distribution of Normal Data in Pretrained Deep Features
Oliver Rippel,Patrick Mertens,Eike Konig,Dorit Merhof
DOI: https://doi.org/10.1109/tim.2021.3098381
IF: 5.6
2021-01-01
IEEE Transactions on Instrumentation and Measurement
Abstract:Anomaly detection (AD) in images is a fundamental computer vision problem and refers to identifying images that deviate significantly from normality. State-of-the-art AD algorithms commonly learn a model of normality from scratch using task-specific datasets in either semisupervised or self-supervised manner. We follow an alternative approach and model the distribution of normal data in deep feature representations learned from ImageNet via a multivariate Gaussian (MVG). This lightweight approach achieves a new state of the art in AD on the public MVTec AD dataset. In addition to the empirical benefits, we give a clear motivation for the seemingly simplistic approach via the ties between deep generative and discriminative modeling revealed recently. We further elucidate why ImageNet representations are discriminative in the transfer learning AD setting using the principal component analysis. Here, we find that the principal components containing little variance in normal data are the ones crucial for discriminating between normal and anomalous instances, giving an explanation for the unreasonable effectiveness of our approach. We also investigate setting the working point of our approach by selecting acceptable false-positive rate thresholds based on the MVG assumption and the resistance of our approach to unlabeled anomalies in the dataset. Finally, we investigate whether our approach is prone to exploiting spurious correlations using explainable AI techniques. Code is publicly available at https://github.com/ORippler/gaussian-ad-mvtec.
engineering, electrical & electronic,instruments & instrumentation
What problem does this paper attempt to address?