Understanding the properties and limitations of contrastive learning for Out-of-Distribution detection

11/06/2022
by   Nawid Keshtmand, et al.
0

A recent popular approach to out-of-distribution (OOD) detection is based on a self-supervised learning technique referred to as contrastive learning. There are two main variants of contrastive learning, namely instance and class discrimination, targeting features that can discriminate between different instances for the former, and different classes for the latter. In this paper, we aim to understand the effectiveness and limitation of existing contrastive learning methods for OOD detection. We approach this in 3 ways. First, we systematically study the performance difference between the instance discrimination and supervised contrastive learning variants in different OOD detection settings. Second, we study which in-distribution (ID) classes OOD data tend to be classified into. Finally, we study the spectral decay property of the different contrastive learning approaches and examine how it correlates with OOD detection performance. In scenarios where the ID and OOD datasets are sufficiently different from one another, we see that instance discrimination, in the absence of fine-tuning, is competitive with supervised approaches in OOD detection. We see that OOD samples tend to be classified into classes that have a distribution similar to the distribution of the entire dataset. Furthermore, we show that contrastive learning learns a feature space that contains singular vectors containing several directions with a high variance which can be detrimental or beneficial to OOD detection depending on the inference approach used.

READ FULL TEXT
research
01/26/2021

Revisiting Contrastive Learning for Few-Shot Classification

Instance discrimination based contrastive learning has emerged as a lead...
research
03/23/2023

Temperature Schedules for Self-Supervised Contrastive Methods on Long-Tail Data

Most approaches for self-supervised learning (SSL) are optimised on cura...
research
03/14/2023

WDiscOOD: Out-of-Distribution Detection via Whitened Linear Discriminative Analysis

Deep neural networks are susceptible to generating overconfident yet err...
research
06/28/2023

GraSS: Contrastive Learning with Gradient Guided Sampling Strategy for Remote Sensing Image Semantic Segmentation

Self-supervised contrastive learning (SSCL) has achieved significant mil...
research
07/27/2020

K-Shot Contrastive Learning of Visual Features with Multiple Instance Augmentations

In this paper, we propose the K-Shot Contrastive Learning (KSCL) of visu...
research
08/05/2021

A Low Rank Promoting Prior for Unsupervised Contrastive Learning

Unsupervised learning is just at a tipping point where it could really t...
research
02/03/2022

The Met Dataset: Instance-level Recognition for Artworks

This work introduces a dataset for large-scale instance-level recognitio...

Please sign up or login with your details

Forgot password? Click here to reset