NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Making The Best of Both Worlds: A Domain-Oriented Transformer for Unsupervised Domain Adaptation

Wenxuan Ma, Jinming Zhang, Shuang Li, Chi Harold Liu, Yulin Wang, Wei Li

Introduction

Unsupervised Domain Adaptation (UDA) is a critical challenge in computer vision, aiming to transfer knowledge from a labeled "source" domain (e.g., synthetic images) to an unlabeled "target" domain (e.g., real-world photographs). While Vision Transformers (ViTs) have recently become the backbone of choice for these tasks, most existing methods adhere to a "classical" paradigm: forcing both domains into a single, shared feature space and using a shared classifier.

In this work, researchers introduce the Domain-Oriented Transformer (DOT), a novel architecture that challenges the necessity of a shared feature space. By leveraging the inherent flexibility of the Transformer architecture, DOT preserves domain-specific nuances while ensuring effective knowledge transfer, achieving state-of-the-art results on the most demanding UDA benchmarks.

The Limitations of Shared Feature Spaces

The authors identify two primary flaws in the traditional approach of forcing source and target domains into a unified representation:

  1. Discriminability Deterioration: When the domain gap is significant, forcing disparate distributions into the same space can "smudge" features. This process often destroys the fine-grained details necessary to distinguish between different classes, leading to lower overall accuracy.
  2. Source Bias: Because classifiers are trained primarily on source labels, they naturally develop a bias toward source-specific characteristics. This creates a "blind spot" for the unique features of the target domain, making the model less effective when deployed on real-world target data.

The Domain-Oriented Transformer (DOT) Framework

To address these issues, DOT moves away from the single-token bottleneck. Instead of the standard [CLS] token, the model employs a dual-token strategy to create specialized feature spaces.

1. Dual-Token Architecture

DOT utilizes two distinct classification tokens: [src] and [tgt].

  • The [src] token is dedicated to learning a source-oriented feature space.
  • The [tgt] token focuses on a target-oriented feature space.

Each token is paired with its own dedicated classifier. This "one token per domain" strategy allows the model to maintain the unique characteristics of each domain, preventing the discriminability loss that occurs in a forced shared space.

2. Domain-Oriented Contrastive Alignment

While the tokens are distinct, the model must still bridge the gap between domains to transfer knowledge. DOT employs a supervised contrastive learning strategy. Rather than a general alignment of distributions, the model pulls target samples toward source samples of the same category within the feature space. This approach is theoretically grounded in maximizing the mutual information between the learned representations and the category labels.

3. Source-Guided Pseudo-Label Refinement

Since target data lacks ground-truth labels, UDA models rely on pseudo-labeling. DOT improves this process by using the source-oriented classifier as a "fair judge." Because the source classifier is trained on clean labels and hasn't been corrupted by noisy target predictions, it is used to filter target data into "reliable" and "unreliable" sets. Unreliable samples are then reassigned to the nearest reliable class center, significantly cleaning the training signal for the target classifier.

Experimental Results

The DOT model was evaluated against three major UDA benchmarks, demonstrating superior performance and robustness.

DomainNet

DomainNet is currently the most challenging UDA benchmark, featuring 345 categories across six diverse domains. On this dataset, DOT-S (Small) achieved an average accuracy of 41.2%, representing a massive improvement over the previous state-of-the-art (CDTrans) at 32.2%.

VisDA-2017

In the VisDA-2017 challenge, which focuses on the shift from synthetic 3D models to real images, the DOT-B (Base) version reached 90.3% accuracy. This performance outperforms methods that rely on more complex, domain-specific batch normalization techniques.

Office-Home

DOT also showed strong performance on the Office-Home dataset (65 categories across four domains). Ablation studies conducted on these datasets confirmed that both the dual-token structure and the contrastive alignment are essential; removing either component resulted in a significant drop in accuracy.

Conclusion and Future Directions

The Domain-Oriented Transformer demonstrates that a "one-size-fits-all" feature space is not always optimal for domain adaptation. By allowing for domain-specific representations through a dual-token architecture, DOT preserves discriminative power while effectively bridging the domain gap.

Beyond standard UDA, the authors demonstrated that this approach scales naturally to Multi-Source Domain Adaptation. By simply adding more tokens (e.g., one for each source domain and one for the target), the model can handle complex multi-domain scenarios without the need for specialized algorithms. This flexibility suggests that the dual-token approach could become a new standard for robust, scalable transfer learning.

Summary updated

BibTeX
@inproceedings{ma2022making,
  author = {Wenxuan Ma and Jinming Zhang and Shuang Li and Chi Harold Liu and Yulin Wang and Wei Li},
  title = {{Making The Best of Both Worlds: A Domain-Oriented Transformer for Unsupervised Domain Adaptation}},
  booktitle = {ACM Multimedia},
  year = {2022},
  url = {https://openreview.net/forum?id=FB4rSMebGh},
}
Figure