Banner Banner

Gradients should stay on Path: Better Estimators of the Reverse- and Forward KL divergence for Normalizing Flows

Lorenz Vaitl
Kim Andrea Nicoli
Shinichi Nakajima
Pan Kessel

October 19, 2022

We show how to use the path-wise derivative estimator for both the forward reverse Kullback–Leibler divergence for any practically invertible normalizing flow. The resulting path-gradient estimators are straightforward to implement, have lower variance, and lead not only to faster convergence of training but also to better overall approximation results compared to standard total gradient estimators. We also demonstrate that path-gradient training is less susceptible to mode-collapse. In light of our results, we expect that path-gradient estimators will become the new standard method to train normalizing flows for variational inference.