Skip to main content
QUICK REVIEW

[Paper Review] Making Contrastive Learning Robust to Shortcuts

Tianhong Li, Lijie Fan|arXiv (Cornell University)|Dec 17, 2020
Domain Adaptation and Few-Shot LearningComputer Science22 references5 citations
TL;DR

This paper proposes Reconstructive Contrastive Learning (RCL), a method that enhances contrastive learning by enforcing input reconstruction in the latent space to counteract shortcut learning. By jointly optimizing contrastive and reconstruction objectives, RCL learns robust, generalizable representations that are less prone to relying on spurious features, outperforming state-of-the-art methods across diverse datasets and multi-attribute tasks.

ABSTRACT

Contrastive learning is one of the fastest growing research areas in machine learning due to its ability to learn useful representations without labeled data. However, contrastive learning is susceptible to shortcuts - i.e., it may learn shortcut features irrelevant to the task of interest, and discard relevant information. Past work has addressed this limitation via handcrafted data augmentations that eliminate the shortcut. But, manually crafted augmentations do not work across all datasets and tasks. Further, data augmentations fail in addressing shortcuts in multi-attribute classification when one attribute acts as a shortcut around other attributes. In this paper, we analyze the objective function of contrastive learning and formally prove that it is vulnerable to shortcuts. We then present reconstructive contrastive learning (RCL), a framework for learning unsupervised representations that are robust to shortcuts. The key idea is to force the learned representation to reconstruct the input, which naturally counters potential shortcuts. Extensive experiments verify that RCL is highly robust to shortcuts and outperforms state-of-the-art contrastive learning methods on a variety of datasets and tasks.

Motivation & Objective

  • To address the vulnerability of contrastive learning to shortcut features that are irrelevant to the true task but correlate with labels.
  • To overcome the limitations of handcrafted data augmentations, which are dataset-specific and ineffective in multi-attribute classification where one attribute acts as a shortcut.
  • To formally analyze the contrastive objective and prove its susceptibility to shortcut learning.
  • To develop a general-purpose framework that improves robustness without relying on task-specific data augmentations.

Proposed method

  • Introduce a joint optimization objective combining contrastive learning with an autoencoding reconstruction loss to enforce faithful representation of input data.
  • Use a dual-stream encoder-decoder architecture where the contrastive loss encourages positive sample alignment and the reconstruction loss enforces fidelity to the original input.
  • Formally prove that standard contrastive learning is vulnerable to shortcuts due to its objective not penalizing irrelevant feature learning.
  • Apply the reconstruction loss during pre-training to regularize the representation space, making it less likely to exploit spurious correlations.
  • Ensure that the reconstruction objective acts as an inductive bias against shortcut features by requiring the model to preserve all input information.
  • Train the model end-to-end using a weighted combination of contrastive and reconstruction losses to balance representation quality and reconstruction fidelity.

Experimental results

Research questions

  • RQ1Can the standard contrastive learning objective be formally proven to be vulnerable to shortcut learning?
  • RQ2Does enforcing input reconstruction in the latent space effectively mitigate shortcut learning in representation learning?
  • RQ3Can RCL generalize across diverse datasets and multi-attribute classification tasks where data augmentations fail?
  • RQ4How does RCL compare to state-of-the-art contrastive learning methods in terms of robustness and accuracy under shortcut conditions?

Key findings

  • The paper formally proves that the standard contrastive learning objective is vulnerable to shortcut learning due to its lack of explicit regularization on irrelevant features.
  • RCL significantly reduces reliance on shortcut features across multiple benchmark datasets, including Cifar-100 and CUB-200, under controlled shortcut conditions.
  • On multi-attribute classification tasks, RCL outperforms state-of-the-art contrastive methods by maintaining high accuracy even when one attribute acts as a shortcut.
  • RCL achieves superior performance on downstream linear evaluation protocols, demonstrating improved generalization and robustness.
  • The ablation study confirms that the reconstruction loss is the key component in mitigating shortcut learning, with ablation of this component leading to performance degradation.
  • The method generalizes well across datasets without requiring task-specific data augmentations, unlike prior approaches.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.