Disentangling impact of capacity, objective, batchsize, estimators, and step-size on flow VI
Abhinav Agrawal, Justin Domke
TL;DR
This work systematically disentangles the factors affecting flow VI performance by evaluating capacity, objective, gradient estimators, batchsize, and step-size using a high-fidelity synthetic benchmark with exact samples. It introduces a scalable evaluation metric (marginal-Wasserstein) and demonstrates that high-capacity Real-NVP flows combined with large gradient batchsizes enable flow VI to approach or surpass exact inference and turnkey HMC methods under realistic parallel budgets. The authors derive a practical recipe: use high-capacity flows, the standard VI objective, reduced-variance gradient estimators when possible, and a fixed, small step-size, while training long with adaptive optimizers. The findings provide concrete guidelines for practitioners and show that, with sufficient parallelism, flow VI is a competitive alternative to HMC for challenging targets, thus broadening its applicability.
Abstract
Normalizing flow-based variational inference (flow VI) is a promising approximate inference approach, but its performance remains inconsistent across studies. Numerous algorithmic choices influence flow VI's performance. We conduct a step-by-step analysis to disentangle the impact of some of the key factors: capacity, objectives, gradient estimators, number of gradient estimates (batchsize), and step-sizes. Each step examines one factor while neutralizing others using insights from the previous steps and/or using extensive parallel computation. To facilitate high-fidelity evaluation, we curate a benchmark of synthetic targets that represent common posterior pathologies and allow for exact sampling. We provide specific recommendations for different factors and propose a flow VI recipe that matches or surpasses leading turnkey Hamiltonian Monte Carlo (HMC) methods.
