Abstract
Despite the progress made in domain adaptation, solving Unsupervised Domain Adaptation (UDA) problems with a general method under complex conditions caused by label shifts between domains remains a challenging task. In this work, we comprehensively investigate four distinct UDA settings including closed set domain adaptation, partial domain adaptation, open set domain adaptation, and universal domain adaptation, where shared common classes between source and target domains coexist alongside domain-specific private classes. The prominent challenges inherent in diverse UDA settings center around the discrimination of common/private classes and the precise measurement of domain discrepancy. To surmount these challenges effectively, we propose a novel yet effective method called Learning Instance Weighting for Unsupervised Domain Adaptation (LIWUDA), which caters to various UDA settings. Specifically, the proposed LIWUDA method constructs a weight network to assign weights to each instance based on its probability of belonging to common classes, and designs Weighted Optimal Transport (WOT) for domain alignment by leveraging instance weights. Additionally, the proposed LIWUDA method devises a Separate and Align (SA) loss to separate instances with low similarities and align instances with high similarities. To guide the learning of the weight network, Intra-domain Optimal Transport (IOT) is proposed to enforce the weights of instances in common classes to follow a uniform distribution. Through the integration of those three components, the proposed LIWUDA method demonstrates its capability to address all four UDA settings in a unified manner. Experimental evaluations conducted on four benchmark datasets substantiate the effectiveness of the proposed LIWUDA method.
Introduction
Unsupervised Domain Adaptation (UDA) is a critical area of research aimed at transferring knowledge from a labeled source domain to an unlabeled target domain. However, real-world applications often face complex conditions where the label spaces of the two domains do not perfectly overlap. This "label shift" manifests in several ways:
- Partial DA: The source domain has more classes than the target.
- Open Set DA: The target domain contains "unknown" classes not seen in the source.
- Universal DA: Both domains have unique, private classes alongside shared ones.
Traditional methods often suffer from "negative transfer" when they attempt to force-align these non-overlapping, domain-specific classes. The challenge lies in creating a single, versatile framework that can identify shared "common" classes and align them while ignoring domain-specific "private" samples.
Methodology
The proposed LIWUDA (Learning Instance Weighting for Unsupervised Domain Adaptation) framework addresses these challenges through three innovative pillars:
1. Weight Network & Weighted Optimal Transport (WOT)
Instead of treating all instances equally, LIWUDA employs a dedicated sub-network to assign a weight to every data instance, representing its probability of belonging to a shared common class. These weights are integrated into a Weighted Optimal Transport (WOT) formulation. Unlike standard OT, which attempts to move all "mass" between domains, WOT prioritizes the transport of shared-class instances, effectively filtering out noise from private classes.
2. Separate and Align (SA) Loss
This loss function acts as a fine-grained filter by using the mean cost of the WOT as a dynamic threshold. If the distance between a source-target pair is higher than this threshold, the model "separates" them; if it is lower, it "aligns" them. This prevents the model from incorrectly matching disparate categories, such as a "Cat" in the source to an "Unknown" class in the target.
3. Intra-domain Optimal Transport (IOT)
To prevent the weight network from becoming biased or collapsing (e.g., assigning zero weights to all instances), the authors introduced IOT. This acts as a regularizer that encourages the weights of common-class instances to follow a uniform distribution, providing a stable signal for training the weighting mechanism.
Experimental Evaluation
The framework was evaluated on four major computer vision benchmarks: Office-31, Office-Home, VisDA, and DomainNet. These datasets cover a wide range of domain shifts (e.g., Synthetic CAD models to Real images) and various label shift scenarios.
Key Results
LIWUDA demonstrated state-of-the-art (SOTA) or near-SOTA performance across all four UDA settings:
- Universal DA: On the Office-31 dataset, LIWUDA achieved a substantial 9% improvement in H-score (a metric balancing common class accuracy and "unknown" detection) over previous leading methods.
- Partial DA: The model reached nearly 100% accuracy on several transfer tasks within the Office-31 dataset.
- Open Set DA: On the large-scale VisDA dataset, it achieved a 68.4% OS* score, marking a 3.9% absolute improvement over previous benchmarks.
Conclusion
LIWUDA provides a unified and versatile solution for UDA under various label shift constraints. By leveraging instance weighting and optimal transport, it effectively mitigates negative transfer and bridges the gap between domains. Future work may extend this framework to multi-source domain adaptation or source-free scenarios where source data is inaccessible due to privacy concerns.
Summary updated