Estimating the normalization constants (partition functions) of energy-based probabilistic models (Markov random fields) with a high accuracy is required for measuring performance, monitoring the training progress of adaptive models, and conducting likelihood ratio tests. We devised a unifying theoretical framework for algorithms for estimating the partition function, including Annealed Importance Sampling (AIS) and Bennett's Acceptance Ratio method (BAR). The unification reveals conceptual similarities of and differences between different approaches and suggests new algorithms. The framework is based on a generalized form of Crooks' equality, which links the expectation over a distribution of samples generated by a transition operator to the expectation over the distribution induced by the reversed operator.
Different ways of sampling, such as parallel
tempering and path sampling, are covered by the framework.
We performed experiments in which we estimated the partition function of restricted Boltzmann
machines (RBMs) and Ising models. We found that BAR using parallel
tempering worked well with a small number of bridging distributions,
while path sampling based AIS performed best with many bridging
distributions. The normalization constant is measured w.r.t.~a reference distribution, and the choice of this distribution turned out to be very important in our experiments.
Overall, BAR gave the best empirical results, outperforming AIS.