Bridging the Gap Between $f$-GANs and Wasserstein GANs

Jiaming Song, Stefano Ermon

Abstract

Generative adversarial networks (GANs) have enjoyed much success in learning high-dimensional distributions. Learning objectives approximately minimize an $f$-divergence ($f$-GANs) or an integral probability metric (Wasserstein GANs) between the model and the data distribution using a discriminator. Wasserstein GANs enjoy superior empirical performance, but in $f$-GANs the discriminator can be interpreted as a density ratio estimator which is necessary in some GAN applications. In this paper, we bridge the gap between $f$-GANs and Wasserstein GANs (WGANs). First, we list two constraints over variational $f$-divergence estimation objectives that preserves the optimal solution. Next, we minimize over a Lagrangian relaxation of the constrained objective, and show that it generalizes critic objectives of both $f$-GAN and WGAN. Based on this generalization, we propose a novel practical objective, named KL-Wasserstein GAN (KL-WGAN). We demonstrate empirical success of KL-WGAN on synthetic datasets and real-world image generation benchmarks, and achieve state-of-the-art FID scores on CIFAR10 image generation.

Introduction

Generative Adversarial Networks (GANs) have traditionally been categorized into two distinct paradigms: $f$-GANs and Wasserstein GANs (WGANs). $f$-GANs minimize $f$-divergences (e.g., KL or Jensen-Shannon), where the discriminator learns a density ratio—a critical component for tasks like importance sampling. However, $f$-GANs often suffer from training instability. Conversely, WGANs utilize Integral Probability Metrics (IPMs), offering superior stability and sample quality, but their critic outputs lack a clear probabilistic interpretation. This research bridges the gap, proposing a unified framework that combines the stability of WGANs with the interpretable density ratios of $f$-GANs.

A Unified Framework for GAN Objectives

The authors introduce a generalized objective, $\mathcal{L}_f^\mathcal{R}(T; P, Q)$, which incorporates importance weights ($r$) over generated samples. By varying the constraints on these weights (the set $\mathcal{R}$), the framework recovers existing GAN variants as special cases.

A unified framework for GAN objectives, showing how $f$-GAN, WGAN, and $f$-WGAN relate through importance weight constraints.

As illustrated in Figure 3, $f$-GANs allow for any non-negative weight function, while WGANs fix weights to a constant. The proposed KL-Wasserstein GAN (KL-WGAN) utilizes the KL divergence as the underlying $f$-divergence, leading to a closed-form solution for optimal weights. Practically, this involves reweighting "fake" samples in a standard WGAN loss using a softmax-like normalization of critic scores, focusing the generator on samples the critic deems "more real."

Experimental Results

The KL-WGAN was evaluated on synthetic 2D datasets, UCI tabular benchmarks, and image generation tasks (CIFAR-10, CelebA).

Distribution Modeling

On 2D synthetic datasets, KL-WGAN demonstrated a significant improvement in capturing complex distributions compared to standard WGAN.

Visual comparison of generated samples on 2D synthetic datasets. KL-WGAN (bottom row) more accurately captures the target distributions (top row) than standard WGAN (middle row).

Quantitative results support these visual findings. On the Mixture of Gaussians (MoG) dataset, the Maximum Mean Discrepancy (MMD) was reduced from 25.45 (WGAN) to 6.51 (KL-WGAN). Furthermore, KL-WGAN successfully estimated density ratios matching ground truth, a capability absent in standard WGANs.

Image Generation

In large-scale image generation, KL-WGAN achieved state-of-the-art results. Using the BigGAN architecture on CIFAR-10, the "KL-BigGAN" variant improved the Inception Score from 8.60 to 8.66 and reduced the FID from 16.38 to 15.23.

Conclusion

This work demonstrates that $f$-GANs and WGANs are not disparate methods but rather points on a spectrum of importance-weighted objectives. KL-WGAN emerges as a computationally efficient "drop-in" replacement for WGAN that provides improved stability and interpretable density ratios. Future work may explore broader constraint sets for the importance weights and apply these density ratio estimates to downstream tasks like inverse reinforcement learning.

Summary updated

Abstract

Generative adversarial networks (GANs) have enjoyed much success in learning high-dimensional distributions. Learning objectives approximately minimize an $f$-divergence ($f$-GANs) or an integral probability metric (Wasserstein GANs) between the model and the data distribution using a discriminator. Wasserstein GANs enjoy superior empirical performance, but in $f$-GANs the discriminator can be interpreted as a density ratio estimator which is necessary in some GAN applications. In this paper, we bridge the gap between $f$-GANs and Wasserstein GANs (WGANs). First, we list two constraints over variational $f$-divergence estimation objectives that preserves the optimal solution. Next, we minimize over a Lagrangian relaxation of the constrained objective, and show that it generalizes critic objectives of both $f$-GAN and WGAN. Based on this generalization, we propose a novel practical objective, named KL-Wasserstein GAN (KL-WGAN). We demonstrate empirical success of KL-WGAN on synthetic datasets and real-world image generation benchmarks, and achieve state-of-the-art FID scores on CIFAR10 image generation.
BibTeX
@inproceedings{song2020bridging,
  author = {Jiaming Song and Stefano Ermon},
  title = {{Bridging the Gap Between $f$-GANs and Wasserstein GANs}},
  booktitle = {International Conference on Machine Learning},
  year = {2020},
  url = {https://openreview.net/forum?id=fCQb79vYD4},
}
Figure