Continuous-Time Flows for Efficient Inference and Density Estimation

Changyou Chen, Chunyuan Li, Liquan Chen, Wenlin Wang, Yunchen Pu, Lawrence CarinICML 2018

Introduction

In unsupervised learning, researchers frequently tackle two primary challenges: inferring latent variables to find hidden data structures (often using Variational Autoencoders, or VAEs) and estimating data density to generate new samples (typically using GANs or Normalizing Flows).

While Normalizing Flows (NFs) improve VAEs by applying a sequence of discrete, invertible transformations to simple distributions, their finite nature prevents them from perfectly approximating complex target distributions. Conversely, Markov Chain Monte Carlo (MCMC) methods guarantee convergence to a target distribution but are computationally prohibitive at test time. This paper introduces Continuous-Time Flows (CTFs), a framework that bridges this gap, offering the theoretical convergence guarantees of infinite continuous transformations alongside the rapid sampling speed of standard deep generative models.

Continuous-Time Flows and Amortized Learning

Instead of relying on discrete mathematical operations, a CTF utilizes a stochastic differential equation—specifically, Langevin dynamics—to evolve a simple distribution into a complex one over continuous time. Because simulating this continuous flow during inference is too slow, the authors employ amortized learning (or distillation). They train a standard neural network to directly output samples that mimic the results of the CTF.

To implement this, the authors propose two distinct architectures:

MacVAE: Markov-Chain-Based VAE

MacVAE uses CTFs to enhance the inference network (encoder) of a VAE. The continuous-time flow targets the true posterior distribution, and an encoder network is trained to match the CTF's output.

MacVAE Architecture

MacGAN: Markov-Chain-Based GAN

MacGAN applies CTFs to train a generator for an explicit Energy-Based Model (EBM). Here, the CTF targets the true data distribution, and the generator learns to mimic it. This framework provides a fascinating theoretical link, demonstrating that training an explicit EBM using a generator distilled from a CTF is mathematically equivalent to maximizing an upper bound on Maximum Likelihood Estimation (MLE).

The Necessity of Adversarial Matching

A crucial insight of the paper is how the CTF is distilled into the neural network. The authors mathematically prove and empirically demonstrate that using standard Euclidean distance for this distillation forces the network to collapse to the average of the modes. To successfully capture the full, complex shape of the distribution, adversarial distribution matching (minimizing the Wasserstein distance via a discriminator network) is mandatory.

Key Results

The proposed architectures were evaluated across both synthetic and real-world datasets:

  • Latent-Variable Inference (MacVAE): On the MNIST dataset, MacVAE achieved an Evidence Lower Bound (ELBO) of -85.62. This outperformed both standard VAEs and VAEs equipped with standard discrete normalizing flows, proving that the continuous-time approach yields tighter approximations of the posterior.
  • Density Estimation (MacGAN): On the CIFAR-10 dataset, MacGAN generated high-quality images, achieving an Inception Score of 6.49. This performance is highly competitive with the popular DCGAN baseline (6.58) and outperforms related hybrid methods like SteinGAN (6.35) and WGAN-I (6.25).
CIFAR-10 Generated Samples
  • Qualitative Toy Results: In 2D synthetic tests, the adversarial-CTF successfully learned complex, multi-modal posteriors (like rings or grids), whereas the Euclidean-based CTF collapsed into single, blurry points. This visually validated the authors' theoretical claims regarding mode collapse.

Limitations and Future Directions

While sampling at test time is exceptionally fast, the theoretical approximation bounds during training rely heavily on the step size and the number of transformations. Simulating the Langevin dynamics accurately enough to train the network remains computationally expensive.

Future work will explore more efficient learning algorithms for the CTF framework to accelerate training. Additionally, researchers may investigate better ways to approximate the target distribution from the discretized flow, such as assigning higher mathematical weights to more recent MCMC samples rather than treating all steps equally.

Summary updated

BibTeX
@inproceedings{chen2018continuous,
  author = {Changyou Chen and Chunyuan Li and Liquan Chen and Wenlin Wang and Yunchen Pu and Lawrence Carin},
  title = {{Continuous-Time Flows for Efficient Inference and Density Estimation}},
  booktitle = {International Conference on Machine Learning},
  year = {2018},
  url = {https://openreview.net/forum?id=rkVCvobO-H},
}
Figure