Latent Space Virtual Adversarial Training for Supervised and Semi-Supervised Learning

Genki Osada, Budrul Ahsan, Revoti Prasad Bora, Takashi NishideIEICE Trans. Information and Systems 2022 · DOI

Introduction

Deep learning models are notoriously prone to overfitting, especially when labeled data is scarce. To improve generalization, researchers often employ consistency regularization. This technique encourages a model to produce stable outputs when presented with an input and its slightly perturbed version.

Virtual Adversarial Training (VAT) is a prominent consistency regularization method where perturbations are not random noise but are specifically calculated to be "adversarial"—maximizing the change in the model's prediction. However, VAT is limited by a local constraint: because it operates in the raw pixel space, perturbations must be kept extremely small to ensure the image remains semantically valid. This narrow search space limits the effectiveness of the regularization.

The LVAT Framework

This paper introduces Latent Space Virtual Adversarial Training (LVAT), which shifts the adversarial search from the high-dimensional pixel space to a structured latent space $Z$ defined by a generative model.

Overview of the LVAT training pipeline, showing the generation of adversarial samples in latent space and the subsequent consistency loss calculation.

Methodology

The LVAT process involves a two-stage approach:

  1. Generative Pre-training: A generative model, such as a Variational Auto-Encoder (VAE) or a Normalizing Flow (Glow), is trained to map inputs $x$ to a latent representation $z$.
  2. Latent Perturbation: During the training of the classifier $f$, an input $x$ is encoded into $z$. LVAT identifies the most adversarial direction within the latent space to create $z_{adv} = z + r$.
  3. Adversarial Reconstruction: The perturbed vector $z_{adv}$ is decoded back into the input space to produce an adversarial image $x_{adv}$.
  4. Consistency Regularization: The classifier is trained to minimize the KL divergence between its predictions for the original $x$ and the reconstructed $x_{adv}$.

By perturbing in the latent space, LVAT can generate adversarial examples that are pixel-wise very different from the original (e.g., changes in lighting or background) but remain semantically identical, effectively bypassing the local constraint of standard VAT.

Experimental Results

The authors evaluated LVAT on standard benchmarks, including SVHN and CIFAR-10, in both supervised and semi-supervised settings.

Performance Gains

LVAT, particularly when paired with the Glow generative model, consistently outperformed standard VAT. In semi-supervised CIFAR-10 (with 4,000 labels), LVAT-Glow achieved an error rate of 9.94%, a significant reduction from the 16.92% error rate of standard VAT. On SVHN (with 1,000 labels), LVAT-Glow reached an error rate of 4.20% compared to 5.77% for VAT.

Comparison of test cross-entropy loss between LVAT and standard VAT, demonstrating the superior regularization effect of the latent space approach.

The Role of Reconstruction Quality

A key insight from the study is the importance of the generative model's quality. LVAT-Glow significantly outperformed LVAT-VAE. This is attributed to the fact that VAEs often produce blurry reconstructions, which provide a weaker signal for the classifier. In contrast, Normalizing Flows like Glow provide exact and sharp reconstructions, allowing for more effective adversarial training.

Conclusion and Future Work

LVAT demonstrates that moving adversarial perturbations to a semantically meaningful latent space provides a more powerful regularization signal than pixel-level perturbations. While the method requires a pre-trained generative model, the resulting performance gains in semi-supervised learning are substantial. Future research may explore end-to-end training of the generator and classifier or combining LVAT with graph-based consistency methods to further push the boundaries of semi-supervised accuracy.

Summary updated

BibTeX
@article{osada2022latent,
  author = {Genki Osada and Budrul Ahsan and Revoti Prasad Bora and Takashi Nishide},
  title = {{Latent Space Virtual Adversarial Training for Supervised and Semi-Supervised Learning}},
  journal = {IEICE Trans. Information and Systems},
  year = {2022},
  doi = {10.1587/transinf.2021edp7161},
}
Figure