VISCOS Flows: Variational Schur Conditional Sampling with Normalizing Flows

Vincent Moens, Aivar Sootla, Haitham Bou Ammar, Jun Wang

TL;DR

This paper introduces VISCOS Flows, a novel method for conditional sampling with pre-trained normalizing flows when only parts of an observation are available. It leverages Schur complement properties to derive a lower bound for the conditioning variable's log-probability, enabling effective data imputation and conditional generation even with partially observed data.

What Problem Does This Paper Address?

Conditional data generation is a fundamental problem in machine learning, especially when dealing with high-dimensional data. While many methods exist for scenarios where the conditioning and conditioned parts of the data are known beforehand, the challenge becomes significantly harder when this partitioning isn't anticipated or when the data itself is incomplete. This is common in applications like few-shot learning, super-resolution, Bayesian optimization with missing inputs, and image inpainting. Existing methods for conditional sampling with normalizing flows often have limitations, such as requiring retraining for new missing data patterns, being computationally expensive, or relying on MCMC methods with unknown convergence times. This paper aims to provide a more flexible and efficient solution for conditional sampling from pre-trained normalizing flows, particularly for data completion tasks where only a subset of the data is observed.

Methods

The core of VISCOS Flows lies in deriving a lower bound for the conditioning variable's log-probability using Schur complement properties, inspired by Gaussian conditional sampling. This is achieved by carefully partitioning the flow's domain and its latent space such that the restricted flow remains bijective. This bijectivity is crucial for applying the Schur complement.

Key methodological contributions include:

  • Schur Complement for Conditional Sampling: The paper derives a variational lower bound (ELBO) by leveraging the Schur complement of the Jacobian matrix. This allows for efficient sampling from the conditional distribution without explicitly computing intractable integrals.
  • Variational Posterior: Instead of directly sampling from the conditional distribution, VISCOS Flows introduces a variational posterior distribution. This allows for amortized inference and efficient recovery of multiple samples.
  • Domain Partitioning: A critical aspect is how the input and latent spaces are partitioned into "observed" (O) and "hidden" (H) components. This partitioning is key to enabling the Schur complement derivation and ensuring bijectivity. The paper discusses how this partitioning can be chosen to improve conditioning.
  • Solving Equality Constraints: The method involves solving an equality constraint to find the missing parts of the data. Two approaches are proposed: a fixed-point iterative algorithm and Newton-Krylov methods, with the latter used as a fallback.
  • Gradient Estimation: The paper details methods for estimating gradients of the Evidence Lower Bound (ELBO), including Log-Absolute Determinant (LAD) gradient estimators like NLADE and CLADE, which are crucial for optimizing the variational posterior.

Datasets

The paper evaluates VISCOS Flows on the following datasets:

  • MNIST: Used for both quantitative experiments on data completion with randomly missing pixels and for demonstrating performance with Implicit Normalizing Flows.
  • CIFAR-10: Used for qualitative experiments on post-training data imputation, specifically for completing masked regions of images.

The paper does not introduce new benchmarks but compares its performance against existing methods on these standard datasets.

Key Insights and Ideas

  • Schur Complement as a Bridge: The paper elegantly demonstrates how the Schur complement, a concept from linear algebra, can be adapted to the non-linear setting of normalizing flows for conditional inference. This provides a principled way to handle missing data.
  • Decoupling Training and Sampling: A significant advantage highlighted is that VISCOS Flows allows for conditional sampling after a normalizing flow has been trained, without needing to include conditioning information during the initial training phase. This greatly improves modularity.
  • Flexibility in Architectures: While the core derivation relies on certain bijectivity properties, the paper shows that VISCOS Flows can be applied to various architectures, including iResNets and Implicit Normalizing Flows, suggesting broad applicability.
  • Variational Posterior for Efficiency: The use of a variational posterior is not just a theoretical convenience; it enables efficient generation of multiple samples from a single fit and allows for amortized inference through inference networks.

Key Results

  • Competitive Performance on MNIST: VISCOS Flows achieved competitive results on the MNIST dataset for data completion, ranking either first or second in Top-1 classification accuracy, FID, and RMSE across various missingness rates, compared to methods like PL-MCMC, MCFlow, and MisGAN.
  • Effective Post-Training Imputation: For CIFAR-10, VISCOS Flows demonstrated strong performance in post-training data imputation, achieving comparable RMSE to PL-MCMC while offering the advantage of generating diverse samples from a single variational posterior fit.
  • Efficiency of Fixed-Point Solver: The proposed fixed-point iterative algorithm for solving the equality constraint was found to be effective, often reducing the distance between imposed and estimated values by over 90%.
  • Applicability to Implicit NFs: The method was successfully extended to Implicit Normalizing Flows, showcasing its adaptability to architectures with potentially unbounded Lipschitz constants.

Limitations and Future Work

  • Assumption A1: The derivation relies on Assumption A1, which requires the flow and its restrictions to be C¹-diffeomorphisms. This might limit its direct application to architectures where this assumption is violated without modifications.
  • Partitioning Choice: While the paper discusses partitioning, finding the optimal partition for specific architectures and tasks might require further investigation.
  • MCMC vs. Gradient Descent: The paper positions VISCOS Flows as an alternative to MCMC methods like PL-MCMC, which can be harder to use. However, the computational cost of gradient descent and the iterative solvers are still significant.
  • Future Work: The authors suggest exploring alternative ways to fit low-dimensional variational posteriors for data completion, particularly for architectures like coupling flows where partitioning and solving for latent variables can be more involved. They also mention the potential for extending the method to other NF architectures with higher Lipschitz constants.

Summary updated

BibTeX
@inproceedings{moens2022viscos,
  author = {Vincent Moens and Aivar Sootla and Haitham Bou Ammar and Jun Wang},
  title = {{VISCOS Flows: Variational Schur Conditional Sampling with Normalizing Flows}},
  booktitle = {International Conference on Learning Representations},
  year = {2022},
  url = {https://openreview.net/forum?id=WRORN3GUCu},
}
Figure