Contrastive Predictive Coding for Anomaly Detection
arXiv:2107.07820
Abstract
Reliable detection of anomalies is crucial when deploying machine learning models in practice, but remains challenging due to the lack of labeled data. To tackle this challenge, contrastive learning approaches are becoming increasingly popular, given the impressive results they have achieved in self-supervised representation learning settings. However, while most existing contrastive anomaly detection and segmentation approaches have been applied to images, none of them can use the contrastive losses directly for both anomaly detection and segmentation. In this paper, we close this gap by making use of the Contrastive Predictive Coding model (arXiv:1807.03748). We show that its patch-wise contrastive loss can directly be interpreted as an anomaly score, and how this allows for the creation of anomaly segmentation masks. The resulting model achieves promising results for both anomaly detection and segmentation on the challenging MVTec-AD dataset.
arXiv comment7 pages, ICML 2021 Workshop on Uncertainty and Robustness in Deep Learning
References in corpus (11)
- A Simple Framework for Contrastive Learning of Visual Representations
- Learning deep representations by mutual information estimation and maximization
- Uninformed Students: Student-Teacher Anomaly Detection with Discriminative Latent Embeddings
- Data-Efficient Image Recognition with Contrastive Predictive Coding
- Prototypical Contrastive Learning of Unsupervised Representations
- Improving Unsupervised Defect Segmentation by Applying Structural Similarity to Autoencoders
- CutPaste: Self-Supervised Learning for Anomaly Detection and Localization
- Contrastive Training for Improved Out-of-Distribution Detection
- Neural Transformation Learning for Deep Anomaly Detection Beyond Images
- Encoding Structure-Texture Relation with P-Net for Anomaly Detection in Retinal Images
- The Clever Hans Effect in Anomaly Detection