CADet: Fully Self-Supervised Out-Of-Distribution Detection With Contrastive Learning
Not on the map. Why?
Abstract (arXiv)
Handling out-of-distribution (OOD) samples has become a major stake in the real-world deployment of machine learning systems. This work explores the use of self-supervised contrastive learning to the simultaneous detection of two types of OOD samples: unseen classes and adversarial perturbations. First, we pair self-supervised contrastive learning with the maximum mean discrepancy (MMD) two-sample test. This approach enables us to robustly test whether two independent sets of samples originate from the same distribution, and we demonstrate its effectiveness by discriminating between CIFAR-10 and CIFAR-10.1 with higher confidence than previous work. Motivated by this success, we introduce CADet (Contrastive Anomaly Detection), a novel method for OOD detection of single samples. CADet draws inspiration from MMD, but leverages the similarity between contrastive transformations of a same sample. CADet outperforms existing adversarial detection methods in identifying adversarially perturbed samples on ImageNet and achieves comparable performance to unseen label detection methods on two challenging benchmarks: ImageNet-O and iNaturalist. Significantly, CADet is fully self-supervised and requires neither labels for in-distribution samples nor access to OOD examples.
Key facts. Cited by 11 papers in the map (data through 7 Oct 2026). Builds on 57 of its 75 references that are in the map. First posted on arXiv 4 Oct 2022.
Builds on
57 of 75 references.
References · 57
- 2020A Simple Framework for Contrastive Learning of Visual Representationscited by 11,979
- 2019Momentum Contrast for Unsupervised Visual Representation Learningcited by 7,482
- 2014Explaining and Harnessing Adversarial Examplescited by 7,287
- 2017Towards Deep Learning Models Resistant to Adversarial Attackscited by 6,326
- 2016Towards Evaluating the Robustness of Neural Networkscited by 2,976
- 2016A Baseline for Detecting Misclassified and Out-of-Distribution Examples in Neural Networkscited by 2,362
- 2016Density estimation using Real NVPcited by 2,029
- 2018Unsupervised Feature Learning via Non-Parametric Instance-level Discriminationcited by 1,838
- 2019Do ImageNet Classifiers Generalize to ImageNet?cited by 1,507
- 2018A Simple Unified Framework for Detecting Out-of-Distribution Samples and Adversarial Attackscited by 1,472
- 2019Natural Adversarial Examplescited by 1,401
- 2020Big Self-Supervised Models are Strong Semi-Supervised Learnerscited by 1,375
38 more
- 2015LSUN: Construction of a Large-scale Image Dataset using Deep Learning with Humans in the Loopcited by 1,350
- 2017Enhancing The Reliability of Out-of-distribution Image Detection in Neural Networkscited by 1,325
- 2020Energy-based Out-of-distribution Detectioncited by 1,296
- 2021Generalized Out-of-Distribution Detection: A Surveycited by 796
- 2017Unsupervised Anomaly Detection with Generative Adversarial Networks to Guide Marker Discoverycited by 566
- 2020On Adaptive Attacks to Adversarial Example Defensescited by 547
- 2017Large Batch Training of Convolutional Networkscited by 529
- 2019Using Self-Supervised Learning Can Improve Model Robustness and Uncertaintycited by 511
- 2021ReAct: Out-of-distribution Detection With Rectified Activationscited by 486
- 2017Feature Squeezing: Detecting Adversarial Examples in Deep Neural Networkscited by 484
- 2019Scaling Out-of-Distribution Detection for Real-World Settingscited by 465
- 2019Likelihood Ratios for Out-of-Distribution Detectioncited by 451
- 2018Do Deep Generative Models Know What They Don't Know?cited by 443
- 2020CSI: Novelty Detection via Contrastive Learning on Distributionally Shifted Instancescited by 441
- 2022ViM: Out-Of-Distribution with Virtual-logit Matchingcited by 404
- 2019Your Classifier is Secretly an Energy Based Model and You Should Treat it Like Onecited by 402
- 2018Characterizing Adversarial Subspaces Using Local Intrinsic Dimensionalitycited by 280
- 2018Deep Anomaly Detection Using Geometric Transformationscited by 269
- 2021SSD: A Unified Framework for Self-Supervised Outlier Detectioncited by 264
- 2017Detecting Adversarial Samples from Artifactscited by 244
- 2021MOS: Towards Scaling Out-of-distribution Detection for Large Semantic Spacecited by 233
- 2017On Detecting Adversarial Perturbationscited by 232
- 2020Classification-Based Anomaly Detection for General Datacited by 210
- 2018Deep k-Nearest Neighbors: Towards Confident, Interpretable and Robust Deep Learningcited by 203
- 2019OCGAN: One-class Novelty Detection Using GANs with Constrained Latent Representationscited by 199
- 2019Input complexity and out-of-distribution detection with likelihood-based generative modelscited by 186
- 2020Contrastive Training for Improved Out-of-Distribution Detectioncited by 186
- 2020Learning and Evaluating Representations for Deep One-class Classificationcited by 133
- 2020Learning Deep Kernels for Non-Parametric Two-Sample Testscited by 129
- 2016Deep Structured Energy Based Models for Anomaly Detectioncited by 113
- 2016Generative Models and Model Criticism via Optimized Maximum Mean Discrepancycited by 99
- 2018Generative Probabilistic Novelty Detection with Adversarial Autoencoderscited by 99
- 2016Interpretable Distribution Features with Maximum Testing Powercited by 63
- 2015Fast Two-Sample Testing with Analytic Representations of Probability Measurescited by 53
- 2019A New Defense Against Adversarial Images: Turning a Weakness into a Strengthcited by 49
- 2020Maximum Mean Discrepancy Test is Aware of Adversarial Attackscited by 44
- 2021Neural Mean Discrepancy for Efficient Out-of-Distribution Detectioncited by 42
- 2018Learning deep kernels for exponential family densitiescited by 36
50 most cited of 57 All 57 (JSON)
Built on by
Citing papers per year: 2023: 1; 2024: 3; 2025: 6; 2026: 1.
11 papers.
- 2025FruitNeRF++: A Generalized Multi-Fruit Counting Method Utilizing Contrastive Learning and Neural Radiance Fieldscited by 4
- 2023Expecting The Unexpected: Towards Broad Out-Of-Distribution Detectioncited by 3
- 2025Can We Ignore Labels In Out of Distribution Detection?cited by 3
- 2024Evaluating Self-Supervised Learning in Medical Imaging: A Benchmark for Robustness, Generalizability, and Multi-Domain Impactcited by 2
- 2025AutoSciDACT: Automated Scientific Discovery through Contrastive Embedding and Hypothesis Testingcited by 2
- 2024Deep Metric Learning-Based Out-of-Distribution Detection with Synthetic Outlier Exposurecited by 0
- 2024Resultant: Incremental Effectiveness on Likelihood for Unsupervised Out-of-Distribution Detectioncited by 0
- 2025DynaSubVAE: Adaptive Subgrouping for Scalable and Robust OOD Detectioncited by 0
- 2025KoALA: KL-L0 Adversarial Detector via Label Agreementcited by 0
- 2025CroTad: A Contrastive Reinforcement Learning Framework for Online Trajectory Anomaly Detectioncited by 0
- 2026LOTTERY: Learning from Reference-Only Samples in Two-Sample Testing under Size Asymmetrycited by 0
- 2026LOTTERY: Learning from Reference-Only Samples in Two-Sample Testing under Size Asymmetry7 Jun 2026
- 2025CroTad: A Contrastive Reinforcement Learning Framework for Online Trajectory Anomaly Detection21 Nov 2025
- 2025AutoSciDACT: Automated Scientific Discovery through Contrastive Embedding and Hypothesis Testing24 Oct 2025
- 2025KoALA: KL-L0 Adversarial Detector via Label Agreement14 Oct 2025
- 2025DynaSubVAE: Adaptive Subgrouping for Scalable and Robust OOD Detection11 Jun 2025
- 2025FruitNeRF++: A Generalized Multi-Fruit Counting Method Utilizing Contrastive Learning and Neural Radiance Fields26 May 2025
- 2025Can We Ignore Labels In Out of Distribution Detection?20 Apr 2025
- 2024Evaluating Self-Supervised Learning in Medical Imaging: A Benchmark for Robustness, Generalizability, and Multi-Domain Impact26 Dec 2024
- 2024Resultant: Incremental Effectiveness on Likelihood for Unsupervised Out-of-Distribution Detection5 Sep 2024
- 2024Deep Metric Learning-Based Out-of-Distribution Detection with Synthetic Outlier Exposure1 May 2024
- 2023Expecting The Unexpected: Towards Broad Out-Of-Distribution Detection22 Aug 2023