Contrastive Regression for Domain Adaptation on Gaze Estimation

Yaoming Wang, Yangzhou Jiang, Jin Li, Bingbing Ni, Wenrui Dai, Chenglin Li, Hongkai Xiong, Teng Li

Abstract

Appearance-based gaze estimation is vital for human-computer interaction but suffers from significant performance degradation when deployed in new environments with varying lighting or camera angles. This paper presents Contrastive Regression Gaze Adaptation (CRGA), a novel framework that leverages a distance-aware contrastive loss to bridge the domain gap. Unlike traditional contrastive learning designed for classification, our approach treats gaze as a continuous spectrum, organizing the feature space by angular similarity. Experimental results show that CRGA reduces estimation error by up to 55.8% on cross-domain benchmarks without requiring target-domain labels.

Introduction

Appearance-based gaze estimation—predicting a person's focus from facial images—is a cornerstone for applications in VR/AR, medical diagnostics, and driver monitoring. While deep learning models excel within a single dataset, they often "fall off a cliff" when applied to new domains. Collecting new gaze annotations is expensive and labor-intensive. Unsupervised Domain Adaptation (UDA) offers a solution by adapting models using only unlabeled images. However, standard UDA techniques often rely on classification-based contrastive learning, which fails to capture the continuous nature of gaze angles.

The Challenge of Regression in Contrastive Learning

Standard contrastive loss functions are binary: they pull "positives" (same class) together and push "negatives" (different classes) apart. In regression tasks like gaze estimation, this logic is flawed. Treating two images as "negatives" just because they are different—even if the gaze angles are nearly identical—disrupts the learning of a smooth, continuous feature space.

Methodology: The CRGA Framework

The proposed Contrastive Regression Gaze Adaptation (CRGA) framework introduces a distance-aware logic to unsupervised learning.

Overview of the CRGA framework, including Contrastive Domain Generalization (CDG) and Contrastive Self-training Adaptation (CSA).

The framework consists of two primary stages:

  1. Contrastive Domain Generalization (CDG): Using labeled source data, the model learns a stable representation where the feature space is organized by gaze direction. This is achieved through the Contrastive Regression (CR) loss, which uses a similarity function based on the negative log of the Kullback-Leibler (KL) divergence between gaze labels.
  2. Contrastive Self-training Adaptation (CSA): When presented with an unlabeled target domain, the model generates "pseudo-labels" (initial predictions). These are then used within the CR loss framework to refine the model's understanding of the new environment's specific characteristics.

Key Insights: Regression-Aware Contrast

The core innovation is the realization that "negativeness" in regression is a spectrum. If two images have gaze angles only 1° apart, they should be treated as near-positives. By using CR loss, the model organizes its internal feature space such that the mathematical distance between two image representations corresponds to their angular difference.

Comparison of feature space organization between standard contrastive classification loss and the proposed contrastive regression loss.

As shown in the t-SNE visualizations, the proposed regression loss creates a much more structured and continuous feature distribution compared to standard classification-based contrastive methods. This geometric organization makes the model significantly more robust to domain shifts in lighting, background, or physical appearance.

Experimental Results

The CRGA method was evaluated across six major gaze datasets, including ETH-XGAZE, Gaze360, and MPIIGaze. Key findings include:

  • Significant Error Reduction: Adapting from ETH-XGAZE to GazeCapture resulted in a 55.8% reduction in angular error compared to baseline models.
  • State-of-the-Art Performance: On the MPIIGaze dataset, CRGA achieved an angular error of 5.48°, outperforming previous unsupervised methods like PnP-GA (5.53°).
  • Broad Applicability: The framework was also successfully applied to head pose estimation, demonstrating its versatility for various continuous-label regression tasks.

Conclusion and Future Work

CRGA demonstrates that reimagining contrastive learning for regression can yield massive gains in domain adaptation. While the method currently relies on a high-quality pre-trained source model for initial pseudo-labeling, it sets a new benchmark for unsupervised gaze estimation. Future research may extend this distance-aware contrastive framework to other regression tasks such as age estimation or depth prediction.

Summary updated

BibTeX
@inproceedings{wang2022contrastive,
  author = {Yaoming Wang and Yangzhou Jiang and Jin Li and Bingbing Ni and Wenrui Dai and Chenglin Li and Hongkai Xiong and Teng Li},
  title = {{Contrastive Regression for Domain Adaptation on Gaze Estimation}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2022},
  doi = {10.1109/cvpr52688.2022.01877},
}
Figure