Contrastive Order Learning: A General Framework for Ordinal Regression

Chaewon Lee, BeomJun Shim, Kwang Pyo Choi, Chang-Su Kim

TL;DR

This paper introduces ConOrd, a novel framework for ordinal regression that unifies contrastive learning and order learning. By leveraging soft, rank-aware weights, ConOrd effectively models the inherent ordering of labels, leading to state-of-the-art performance across various tasks like facial age estimation and image/video quality assessment.

What Problem Does This Paper Address?

Ordinal regression, the task of predicting ordered labels (like age or quality scores), presents a unique challenge. Standard contrastive learning, while great at learning general representations, often ignores the inherent order of these labels. On the other hand, traditional order learning methods can be too localized, struggling to capture the global structure of ordinal relationships. This paper aims to bridge this gap by developing a framework that effectively integrates the strengths of both approaches, allowing for a more nuanced understanding of ordinal data.

Methods

The core innovation is the Contrastive Order Loss (ConOrd loss). Unlike standard contrastive learning that uses hard positive/negative assignments, ConOrd employs soft affinity (a_ij) and disparity weights (b_ij). These weights are calculated based on the rank difference between pairs of samples in a batch. This allows every pair to contribute to learning, with their influence modulated by their ordinal relationship. Specifically:

  • Affinity weights (a_ij) are high for samples with similar ranks, encouraging attraction.
  • Disparity weights (b_ij) are high for samples with distant ranks, encouraging repulsion.

This approach allows for fine-grained modeling of ordinal relationships and creates a more globally consistent embedding space. The framework also incorporates a center loss for regularization, encouraging compact clusters for each rank.

Datasets

The proposed ConOrd framework was evaluated on a variety of datasets across different ordinal regression tasks:

  • Facial Age Estimation: MORPH II, CLAP2015, AgeDB-DIR, UTK, CACD, Adience.
  • Blind Image Quality Assessment (BIQA): BID, CLIVE, KonIQ10k, SPAQ, FLIVE.
  • Blind Video Quality Assessment (BVQA): LSVQ, KoNViD-1k, LIVE-VQC, CVD2014, YouTube-UGC.
  • Additional Regression Tasks: SkyFinder (ambient temperature prediction), MPIIFaceGaze (gaze direction estimation).
  • Deep Imbalanced Regression (DIR) Benchmarks: IMDB-WIKI-DIR, STS-B-DIR, NYUD2-DIR.

Key Insights and Ideas

  • Soft weighting is key: Moving beyond hard positive/negative assignments in contrastive learning to soft, rank-aware weights is crucial for effectively capturing ordinal relationships. This allows for a more nuanced understanding of how similar or dissimilar samples should be treated.
  • Global structure matters: By considering all sample pairs within a batch and modulating their contributions, ConOrd can learn a more globally consistent and discriminative embedding space compared to methods that rely on local comparisons.
  • Order and contrastive learning are complementary: The paper demonstrates that by thoughtfully integrating these two paradigms, significant performance gains can be achieved, overcoming the limitations of each individually.
  • Robustness to noise and limited data: ConOrd shows promising resilience to reduced training data and test-time corruptions, suggesting its learned representations are more stable and generalizable.

Key Results

  • State-of-the-art performance: ConOrd consistently achieved state-of-the-art results across facial age estimation, BIQA, and BVQA benchmarks, often outperforming existing methods even when they used larger models or more complex training strategies.
  • Improved MAE: For instance, on the CLAP2015 age estimation dataset, ConOrd achieved an MAE of 2.461, outperforming previous methods.
  • Strong generalization: The framework demonstrated strong generalization capabilities across diverse ordinal regression scenarios.
  • Computational efficiency: ConOrd achieved faster training times per epoch compared to some contrastive baselines and maintained low memory usage.
  • Robustness: Experiments showed ConOrd's stability across various hyperparameters (temperature $\tau$, epsilon $\epsilon$) and its resilience to reduced training data and data corruption.

Limitations and Future Work

  • Ambiguous visual cues: The paper acknowledges that for tasks like facial age estimation, performance can degrade when visual cues are ambiguous or degraded (e.g., poor lighting, strong shadows). This suggests that future work could focus on improving robustness to such challenging conditions.
  • Imbalanced data distributions: Prediction errors were more frequent for extremely low or high MOS values in BIQA/BVQA. This indicates that while ConOrd is robust, further improvements could be made by adopting learning strategies that better handle imbalanced data distributions, especially for extreme values.
  • Future directions: The authors suggest that ConOrd provides a flexible foundation for future advances in ordinal representation learning. The framework's ability to integrate with classification/regression heads and its potential for use as an auxiliary loss are also promising avenues for further research.

Summary updated

BibTeX
@inproceedings{lee2026contrastive,
  author = {Chaewon Lee and BeomJun Shim and Kwang Pyo Choi and Chang-Su Kim},
  title = {{Contrastive Order Learning: A General Framework for Ordinal Regression}},
  booktitle = {International Conference on Machine Learning},
  year = {2026},
  url = {https://openreview.net/forum?id=rUtcXHYnrN},
}
Figure