Contrastive Learning Via Equivariant Representation

Sifan Song, Jinfeng Wang, Qiaochu Zhao, Xiang Li, Dufan Wu, Angelos Stefanidis, Jionglong Su, S Kevin Zhou, Quanzheng Li · Submission to ICLR 2025 · Rejected

TL;DR

Standard invariant contrastive learning (ICL) discards transformation-related information, making models brittle to real-world perturbations like rotations and elastic distortions. The authors introduce CLeVER, an equivariant contrastive learning framework that explicitly separates representations into invariant semantics and "equivariant factors." By adding a simple parameter-regularization loss, CLeVER stabilizes training against trivial collapse and delivers significant robustness and accuracy gains across ResNet, Vision Transformer (ViT), and VMamba backbones.

What Problem Does This Paper Address?

Mainstream self-supervised visual representation methods (like SimCLR or DINO) rely on invariance: they force a network to map different augmented views of an image to the exact same feature vector. While powerful, this objective has major drawbacks:

  1. Burden on capacity: The backbone must memorize many transformed views to map them to a single point, which disproportionately degrades smaller backbones.
  2. Loss of useful information: Information discarded during training (e.g., rotation or color shifts) may be crucial for downstream tasks or real-world robustness.

Recent Equivariant Contrastive Learning (ECL) methods attempt to keep transformation details. Specifically, Distortion-Disentangled Contrastive Learning (DDCL) uses an orthogonal loss to split representations into invariant and variant components. However, the authors discover that DDCL suffers from a silent failure mode: the orthogonal projection head often collapses its weights to near zero ($10^{-21}$ magnitude), producing a trivial zero-loss solution rather than learning true geometric relationships.

Methods

CLeVER incorporates equivariant feature learning on top of DINO without requiring task-specific pretext heads or rigid geometric assumptions:

  • Disentangled Representation Splitting: The backbone output $f(x)$ is split into two components based on an optimal separation ratio (found to be 0.8): an Invariant Representation ($z_{\text{IR}}$) and an Equivariant Factor ($z_{\text{EF}}$).
  • Dual Contrastive & Orthogonal Objectives: $z_{\text{IR}}$ is optimized using standard contrastive cross-entropy ($L_{\text{CL}}$) to retain invariant semantics. $z_{\text{EF}}$ is optimized with an orthogonal loss ($L_{\text{Orth}}$) to decorrelate distortion-variant features across views.
  • Projection Regularization Loss ($L_{\text{PReg}}$): To eliminate the trivial null-space collapse observed in prior work, CLeVER enforces an L1 penalty aligning the parameter norms of the projection heads: $$L_{\text{PReg}} = \big| \|h_{\text{EF}}\| - \|h_{\text{IR}}\| \big|$$ This prevents the equivariant projection head from decaying to zero, forcing the model to actually extract distortion information.

  • Joint Downstream Inference: Downstream classifiers consume the concatenated vector $[z_{\text{IR}}, z_{\text{EF}}]$ to jointly leverage both core semantics and geometric context.

Datasets

  • Pre-training: ImageNet-100 (IN-100) and full ImageNet-1K (IN-1K).
  • Downstream Classification & Semi-Supervised: IN-100/IN-1K (1% and 10% label regimes), CUB200, Flowers102, Food101, and OxfordPet.
  • Downstream Dense Tasks: DAVIS 2017 (unsupervised video object segmentation) and ECSSD, DUTS, and DUT-OMRON (unsupervised saliency segmentation using TokenCut).
  • Augmentation Protocols: Basic Augmentations (BAug), Complex Augmentations (CAug, adding $\pm 90^\circ$ rotation), and High-Complexity (CAug+, adding elastic transformations).

Key Insights and Ideas

  • Fixing Orthogonal Loss Collapse: An unconstrained orthogonal loss minimizes trivially when the projection weights vanish. Penalizing the divergence between the equivariant and invariant head norms forces the network to retain structured transformation data.
  • Equivariant Factors Boost Both Invariance and Sensitivity: Unlike rigid architectures designed only for rotation detection or rotation invariance, CLeVER's learned equivariant factors provide raw perturbation signals without inductive bias. Downstream linear heads can use them to either ignore perturbations (better invariance) or predict rotation angles (better sensitivity).
  • Smaller Backbones Gain the Most: Massive models have enough parameters to memorize multi-view invariances. Smaller models do not. Explicitly splitting out equivariant factors relieves representational pressure, yielding the largest proportional performance boosts on smaller backbones.

Key Results

  • Linear Classification Gains: On ImageNet-100, CLeVER improves over DINO across backbones, boosting ViT-Tiny by +3.9% (to 74.1%), ResNet-18 by +2.8% (to 78.1%), and VMamba-Tiny to 83.9% (+0.7%) at 500 epochs.
  • Robustness Under Perturbations: When evaluating backbones pre-trained with complex augmentations (CAug+) under rotation and elastic transformations, CLeVER improves linear accuracy by 21.1% and 30.7% over vanilla DINO under extreme rotational and elastic perturbations.
  • Downstream Segmentation: On the ECSSD unsupervised saliency benchmark, CLeVER achieves 0.688 IoU / 0.888 Acc. compared to DINO’s 0.655 IoU / 0.867 Acc. under CAug pre-training.

Limitations and Future Work

  • Interpretability: While the paper proves $z_{\text{EF}}$ captures perturbation details rather than primary semantic class information, the exact internal mechanics of what features are preserved remain difficult to interpret.
  • Diminishing Returns at Scale: Accuracy gains on ImageNet-1K are less pronounced than on ImageNet-100, which the authors attribute to the massive dataset already supplying rich semantic variation.
  • Future Work: The authors plan to investigate gating mechanisms to extract equivariant factors in a more transparent, interpretable format.

Summary updated

BibTeX
@misc{song2024contrastive,
  author = {Sifan Song and Jinfeng Wang and Qiaochu Zhao and Xiang Li and Dufan Wu and Angelos Stefanidis and Jionglong Su and S Kevin Zhou and Quanzheng Li},
  title = {{Contrastive Learning Via Equivariant Representation}},
  year = {2024},
  eprint = {2406.00262},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2406.00262},
}
Figure