Computing the marginal likelihood (also called the Bayesian model evidence) is an important task in Bayesian model selection, providing a principled quantitative way to compare models. The learned harmonic mean estimator solves the exploding variance problem of the original harmonic mean estimation of the marginal likelihood. The learned harmonic mean estimator learns an importance sampling target distribution that approximates the optimal distribution. While the approximation need not be highly accurate, it is critical that the probability mass of the learned distribution is contained within the posterior in order to avoid the exploding variance problem. In previous work a bespoke optimization problem is introduced when training models in order to ensure this property is satisfied. In the current article we introduce the use of normalizing flows to represent the importance sampling target distribution. A flow-based model is trained on samples from the posterior by maximum likelihood estimation. Then, the probability density of the flow is concentrated by lowering the variance of the base distribution, i.e. by lowering its "temperature", ensuring its probability mass is contained within the posterior. This approach avoids the need for a bespoke optimisation problem and careful fine tuning of parameters, resulting in a more robust method. Moreover, the use of normalizing flows has the potential to scale to high dimensional settings. We present preliminary experiments demonstrating the effectiveness of the use of flows for the learned harmonic mean estimator. The harmonic code implementing the learned harmonic mean, which is publicly available, has been updated to now support normalizing flows.
翻译:计算边际似然(也称为贝叶斯模型证据)是贝叶斯模型选择中的一项重要任务,为模型比较提供了一种原则性的定量方法。学习谐波均值估计器解决了原始谐波均值估计边际似然时的爆炸方差问题。该估计器学习一个重要性采样目标分布,该分布近似最优分布。虽然近似无需高度精确,但关键在于学习到的分布的概率质量必须包含在后验分布内,以避免爆炸方差问题。在先前的研究中,为确保这一性质,模型训练时引入了一个定制优化问题。本文提出使用归一化流来表示重要性采样目标分布。基于后验样本,通过最大似然估计训练流模型,随后通过降低基分布的方差(即降低其“温度”)来集中流的概率密度,确保其概率质量包含在后验分布之内。该方法避免了定制优化问题和参数精细调优的需求,从而提高了鲁棒性。此外,归一化流的使用具有扩展到高维场景的潜力。我们通过初步实验展示了流模型对学习谐波均值估计器的有效性。目前已公开实现学习谐波均值的谐波代码已更新,以支持归一化流。