Adversarial Feature Augmentation for Unsupervised Domain Adaptation

Riccardo Volpi, Pietro Morerio, Silvio Savarese, Vittorio Murino

Abstract

Recent works showed that Generative Adversarial Networks (GANs) can be successfully applied in unsupervised domain adaptation, where, given a labeled source dataset and an unlabeled target dataset, the goal is to train powerful classifiers for the target samples. In particular, it was shown that a GAN objective function can be used to learn target features indistinguishable from the source ones. In this work, we extend this framework by (i) forcing the learned feature extractor to be domain-invariant, and (ii) training it through data augmentation in the feature space, namely performing feature augmentation. While data augmentation in the image space is a well established technique in deep learning, feature augmentation has not yet received the same level of attention. We accomplish it by means of a feature generator trained by playing the GAN minimax game against source features. Results show that both enforcing domain-invariance and performing feature augmentation lead to superior or comparable performance to state-of-the-art results in several unsupervised domain adaptation benchmarks.

Introduction

In modern machine learning, models often encounter the "domain shift" problem: a classifier trained on a specific source domain (e.g., synthetic digits) often fails when deployed on a related but distinct target domain (e.g., real-world house numbers). Unsupervised Domain Adaptation (UDA) seeks to mitigate this performance drop by leveraging labeled source data alongside unlabeled target data to learn representations that generalize across domains.

Traditional GAN-based approaches for UDA attempt to align target features with source features. However, these methods can suffer from training instability or require complex multi-encoder architectures. Furthermore, while image-level data augmentation (rotations, flips) is a staple of deep learning, the potential of augmenting representations in the abstract feature space remains largely untapped for domain adaptation.

The DIFA Framework

The authors propose DIFA (Domain Invariance + Feature Augmentation), a three-step training procedure designed to learn robust, domain-invariant representations through adversarial feature generation.

The three-step DIFA training procedure: (Step 0) source training, (Step 1) feature generator training via CGAN, and (Step 2) adversarial adaptation of a shared encoder.

Step 0: Source Training

The process begins by training a standard feature extractor ($E_S$) and a classifier ($C$) on the labeled source dataset using a standard cross-entropy loss. This establishes a baseline representation for the source domain.

Step 1: Feature Generation

A Feature Generator ($S$) is trained within a Conditional GAN (CGAN) framework. Unlike typical GANs that generate pixels, $S$ learns to "hallucinate" synthetic feature vectors. It is conditioned on class labels to ensure the generated features are semantically meaningful, aiming to produce vectors that a discriminator cannot distinguish from the real features produced by $E_S$.

Step 2: Adversarial Adaptation

Finally, a single, shared feature extractor ($E_I$) is trained for both domains. Through a minimax game, $E_I$ is optimized to map both source and target images into a feature space where a discriminator ($D_2$) cannot differentiate them from the synthetic features produced by the generator $S$. This forces $E_I$ to learn a domain-invariant mapping that aligns with the augmented feature distribution.

Experimental Results

The DIFA method was evaluated across several standard UDA benchmarks, including digit adaptation (MNIST, USPS, SVHN, SYN DIGITS) and cross-modal object classification (NYUD RGB $\rightarrow$ Depth).

Accuracy performance of DIFA compared to Domain Invariance (DI) and LS-ADDA baselines across various benchmarks. DIFA consistently shows higher accuracy and better convergence.

Key results include:

  • SVHN $\rightarrow$ MNIST: DIFA achieved 89.7% accuracy, a substantial improvement over the ADDA baseline of 76.0%.
  • NYUD (RGB $\rightarrow$ Depth): In this challenging cross-modal task, DIFA reached 31.3% accuracy, outperforming the previous state-of-the-art (ADDA at 21.1%) by over 10 percentage points.
  • Ablation Studies: Results confirmed that both Domain Invariance (DI) and Feature Augmentation (FA) are critical. While DI alone improves performance, the addition of FA provides the necessary regularization to achieve top-tier results.

Discussion and Insights

The primary strength of DIFA lies in Adversarial Feature Augmentation. By training a generator to explore the feature space, the model can "fill in the gaps" that exist in the limited source dataset. For instance, on the SVHN dataset, the generator was able to produce over a million unique activation patterns from a dataset of ~69,000 images, providing a much richer training signal for the final encoder.

Additionally, using a single shared encoder ($E_I$) instead of separate source and target encoders (as seen in methods like ADDA) helps prevent "catastrophic forgetting." This ensures the model maintains high accuracy on the source domain while adapting to the target.

Conclusion

DIFA demonstrates that playing the GAN minimax game in high-dimensional embedding spaces is a highly effective strategy for unsupervised domain adaptation. While the method is sensitive to the quality of the initial source features, its ability to "hallucinate" diverse representations allows it to bridge significant domain gaps. Future research may explore applying feature augmentation to more complex tasks such as semantic segmentation and object detection.

Summary updated

BibTeX
@inproceedings{volpi2018adversarial,
  author = {Riccardo Volpi and Pietro Morerio and Silvio Savarese and Vittorio Murino},
  title = {{Adversarial Feature Augmentation for Unsupervised Domain Adaptation}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2018},
  doi = {10.1109/cvpr.2018.00576},
}
Figure