Stabilizing Adversarial Nets with Prediction Methods

Abhay Yadav, Sohil Shah, Zheng Xu, David Jacobs, Tom Goldstein

TL;DR

Training adversarial networks is often a frustrating game of "cat and mouse" where the players never reach an equilibrium. This paper introduces a simple "prediction" step that acts as a damping mechanism, preventing training from spiraling out of control and allowing for faster convergence with much larger learning rates.

The Problem: Minimizers vs. Saddle Points

Adversarial neural networks—most famously Generative Adversarial Networks (GANs)—are powerful tools for everything from image generation to domain adaptation. However, they are notoriously temperamental.

The root of the problem is mathematical. While standard neural networks look for a minimizer (the bottom of a valley), adversarial networks look for a saddle point. In this minimax game, one network tries to minimize a loss while the other tries to maximize it. Standard optimization tools like Stochastic Gradient Descent (SGD) are designed to go "downhill." When applied to saddle points, the training path often "slides off" the surface or orbits endlessly. This leads to the dreaded "mode collapse," where the generator produces the same limited output regardless of input, or the loss simply explodes to infinity.

Gradient descent behavior on a minimizer versus a saddle point.

The Solution: The Prediction Method

To stabilize this process, the authors propose a "Prediction Method."

In standard alternating SGD, you update player A, then use player A’s new position to update player B. The authors argue this reactive approach is unstable. Instead, their method adds a look-ahead step:

  1. Update Player A (the minimizer) using a standard gradient step.
  2. Predict Player A’s future by assuming it will continue moving in the same direction it just moved.
  3. Update Player B (the maximizer) using this predicted future position of Player A.
The prediction step introduces a look-ahead mechanism to guide the optimizer toward the saddle point.

Mathematically, if $u$ is the minimizer and $v$ is the maximizer, the update for $v$ uses an extrapolated value $\bar{u}^{k+1} = u^{k+1} + (u^{k+1} - u^k)$. This is significantly more efficient than methods like "Unrolled GANs," which require computing multiple full gradient steps to look ahead. Here, the "prediction" is essentially free—it’s just a simple linear extrapolation.

Key Insights and Ideas

  • The Harmonic Oscillator Analogy: The authors show that standard adversarial training behaves like an undamped harmonic oscillator—the parameters just orbit the saddle point forever without landing on it. The prediction step introduces a damping term, forcing the parameters to spiral inward and converge to the saddle point.
  • Stability at Scale: Because the method is more stable, researchers can use learning rates up to 5x larger than usual. This leads to much faster training without the constant fear of the model collapsing mid-run.
  • Computational Efficiency: Unlike other stabilization methods, the prediction step adds almost zero computational overhead. In their tests, an epoch of DCGAN took 35 seconds, while the version with prediction took only 38 seconds.

Experimental Validation and Results

The authors validated their approach across a diverse set of tasks and datasets, including MNIST, CIFAR-10, the OFFICE Dataset (domain adaptation), the UCI Adult Dataset (fair classifiers), and ImageNet.

  • GAN Stability: In 25 different training settings, standard DCGAN collapsed 20 times. The prediction method collapsed only once.
  • Higher Quality Images: On the Stacked GAN architecture, the prediction method achieved significantly higher Inception Scores (a measure of image quality and diversity). For example, at a learning rate of 0.001, the standard model failed (score of 1.52), while the prediction model thrived (score of 7.96).
  • Domain Adaptation: The method provided an absolute improvement of 1.3% to 6.9% in accuracy on difficult transfer learning tasks where the source and target domains were very different.
  • Fairness: When training fair classifiers, the prediction method allowed for the selection of models that were both more accurate and less discriminatory than those trained with standard Adam.

Limitations and Future Work

While the empirical results are strong across various architectures, the theoretical proof provided in the paper assumes the loss function is convex-concave. Most deep learning loss surfaces are non-convex and much more complex.

The authors also note that while the method is very stable, it isn't a "magic bullet" that guarantees convergence in every possible scenario—it simply widens the "safe zone" for hyperparameters. Future work could explore whether adaptive prediction steps (changing the look-ahead distance dynamically) could further improve results.

Summary updated

BibTeX
@inproceedings{yadav2018stabilizing,
  author = {Abhay Yadav and Sohil Shah and Zheng Xu and David Jacobs and Tom Goldstein},
  title = {{Stabilizing Adversarial Nets with Prediction Methods}},
  booktitle = {International Conference on Learning Representations},
  year = {2018},
  url = {https://openreview.net/forum?id=Skj8Kag0Z},
}
Figure