Importance sampling with transformed weights
Manuel A. V\'azquez, Joaqu\'in M\'iguez

TL;DR
This paper investigates the use of transformed importance weights in standard importance sampling, demonstrating that it improves robustness to weight degeneracy through a bias-variance trade-off.
Contribution
It provides a numerical assessment of transformed importance weights in standard IS, showing their effectiveness in reducing weight degeneracy.
Findings
Transformed importance weights improve robustness in importance sampling.
The method achieves a bias-variance trade-off that mitigates weight degeneracy.
Numerical results confirm the effectiveness of TIWs in standard IS.
Abstract
The importance sampling (IS) method lies at the core of many Monte Carlo-based techniques. IS allows the approximation of a target probability distribution by drawing samples from a proposal (or importance) distribution, different from the target, and computing importance weights (IWs) that account for the discrepancy between these two distributions. The main drawback of IS schemes is the degeneracy of the IWs, which significantly reduces the efficiency of the method. It has been recently proposed to use transformed IWs (TIWs) to alleviate the degeneracy problem in the context of Population Monte Carlo, which is an iterative version of IS. However, the effectiveness of this technique for standard IS is yet to be investigated. In this letter we numerically assess the performance of IS when using TIWs, and show that the method can attain robustness to weight degeneracy thanks to a…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsStatistical Methods and Inference · Statistical Methods and Bayesian Inference
Importance sampling with transformed weights
Manuel A. Vázquez and Joaquín Míguez
Abstract
The importance sampling (IS) method lies at the core of many Monte Carlo-based techniques. IS allows the approximation of a target probability distribution by drawing samples from a proposal (or importance) distribution, different from the target, and computing importance weights (IWs) that account for the discrepancy between these two distributions. The main drawback of IS schemes is the degeneracy of the IWs, which significantly reduces the efficiency of the method. It has been recently proposed to use transformed IWs (TIWs) to alleviate the degeneracy problem in the context of Population Monte Carlo, which is an iterative version of IS. However, the effectiveness of this technique for standard IS is yet to be investigated. In this letter we numerically assess the performance of IS when using TIWs, and show that the method can attain robustness to weight degeneracy thanks to a bias/variance trade-off.
1 Introduction
One classical application of Monte Carlo (MC) methods is the approximation of a distribution of interest (often referred to as target distribution) by means of random samples. In many practical situations it is not possible or convenient to draw samples directly from the target. In such a case, it is common to rely on the importance sampling (IS) principle [1]. It consists in drawing samples from a proposal distribution, which are then assigned importance weights (IWs) to compensate for the mismatch between the target and the proposal.
A critical drawback of the IS methodology is the degeneracy of the IWs. This happens when only a few samples have non-negligible IWs. Since samples with weights close to zero are irrelevant when building a Monte Carlo approximation, weight degeneracy reduces the efficiency of the method. This problem aggravates when performing inference in high-dimensional systems [2].
The term Population Monte Carlo (PMC) [3] refers to a class of iterative IS algorithms in which samples drawn from a proposal distribution are used to obtain a refined proposal that can be sampled again. In the context of PMC, the authors of [4] propose to apply a non-linear transformation to the IWs that reduces their variability, and hence alleviates the degeneracy problem. Although a theoretical analysis of the asymptotic convergence of the method is provided in [4], to date there is no published numerical assessment of the performance of the importance samplers with transformed IWs (TIWs) in a non-iterative setting and with finite sample size. Moreover, the impact of certain parameters that are relevant to the performance of the method has not been investigated. In this work we tackle these open issues.
2 Standard Monte Carlo
Let be an unknown random vector with known prior density . Our goal is the Bayesian estimation of given an vector of observations, y, that relates to the former through a likelihood function, . Specifically, we aim at approximating the posterior probability density function (pdf) of , i.e.,
[TABLE]
using a collection of random samples, , in the space of . From the latter, it is easy to approximate any expectation of the form , where is some real integrable function of . For instance, the posterior mean of can be approximated as .
3 Importance sampling
Let us denote by the pdf of a distribution of interest, usually referred to as the target distribution. It is often impractical to sample directly, so we are going to draw samples from a proposal distribution and weight them appropriately according to the principle of IS [1]. If denotes the proposal pdf, then the idea is to draw samples,
[TABLE]
and assign each one a normalized importance weight, , computed as
[TABLE]
Equations (2) and (3) together constitute the standard IS algorithm.
From the sample set and their associated weights, one can build a discrete random measure,
[TABLE]
where is the unit delta measure located at , that allows to approximate the expectation of any integrable function with respect to as
[TABLE]
The efficiency of any IS algorithm (roughly given by the number of samples that are required to attain a certain level of performance) depends to a great extent on the choice of the proposal function, . However, the asymptotic convergence of the above approximation when is guaranteed as long as for every [1].
4 Weight degeneracy and transformation of the weights
The degeneracy of the IWs refers to the situation in which only a few samples hold significant IWs, while the vast majority have weights close to zero. This clearly reduces the efficiency of the method since samples with negligible IWs barely contribute to the approximations in (4) or (5).
Following [4], we propose to alleviate this problem by applying a non-linear transformation over the unnormalized IWs, , aimed at decreasing their variance. To be specific, the (unnormalized) transformed IWs (TIWs) are obtained as , where is a real positive function that depends on the whole sample set, , and their weights.
Different choices for the non-linear transformation, , are possible. The asymptotic convergence results in [4] are specifically referred to the "clipping" transformation, which is also the one we consider here. It consists in setting the highest IWs to a common value. More formally, let us consider a permutation, of the indices in such that . Then, the unnormalized TIWs, , are computed from the original IWs, , as
[TABLE]
and their normalized counterparts are
[TABLE]
The IS algorithm with TIWs is described by equations (2), (3), (6) and (7). We refer to it as nonlinear IS (NIS).
5 Simulations
We numerically asses the convergence of the NIS algorithm when the sample size is finite and, most importantly, when using a non-iterative scheme (unlike in [4]). We apply the algorithm to estimate the location of the modes of a Gaussian mixture model (GMM) given a set of conditionally independent and identically distributed (i.i.d.) observations. In particular, we consider the GMM
[TABLE]
where is a vector encompassing the unknown means of the mixture components. The remaining parameters of the model are assumed to be known, and set to , and .
We assume independent Gaussian prior distributions for the unknown means, namely
[TABLE]
Given a collection of observations, , drawn from the GMM in (8), we aim at approximating the posterior . In order to do so, we draw samples from a proposal function, which is selected to match the prior, i.e.,
[TABLE]
Then, at the sight of equations (3) and (1), the unnormalized IWs are computed as
[TABLE]
where we have used the fact that the observations in y are conditionally independent given the state. TIWs can then be computed as indicated in (6) and (7).
In this setting we compare the performance of the standard IS and the novel NIS schemes. Every result in this section is averaged over a certain number of independent simulation runs, , of the appropriate algorithm for a fixed set of observations y. We refer to each of these runs as an MC realization, and we set . Additionally, independent realizations of the observations, , are considered. Overall, each algorithm is run times.
Figure 1 shows the performance of the standard IS and NIS algorithms in terms of the bias of the posterior-mean estimators, and as the number of samples, , grows. For every value of , the number of samples whose weights are clipped is . On the other hand, the number of observations is in every case . The bias is computed as
[TABLE]
where is the posterior-mean estimate of computed for the -th realization of the observations, , during the -th MC realization for either the NIS or IS algorithms. Additionally, the figure also provides information about the degeneracy of the weights. The color of every marker indicates, according to the color bar on the right, the maximum weight among all the samples.
It can be seen that the bias attained by the standard IS estimator is always below the bias of the NIS estimator. This is because the transformation of the weights applied to obtain the TIWs introduces a distortion in the approximation of the probability measure . However, it is clear from the figure that both algorithms converge to the same estimate when the number of samples is large as predicted by the asymptotic analysis in [4]. Also notice that in the standard IS algorithm, the maximum weight is close to whenever the number of samples is below . Hence, most of the probability mass is concentrated in a single sample, and the remaining samples are, for all practical purposes, irrelevant. This is specifically avoided in the NIS algorithm, where the maximum weight is below for most values of . Avoiding a single sample garnering most of the probability mass is important in connection to the variance of the resulting estimators. This is illustrated in Figure 2 that shows the estimator variance, computed as with
The figure shows that, for low-to-medium sample sizes, the variance of the estimates computed using the NIS method is considerably lower than the variance of the standard IS estimates.
A common metric for comparing the performance of different algorithms is the mean square error (MSE). Our simulations indicate that, e.g., for the (average) MSE attained by the standard IS algorithm is while that achieved by the NIS scheme is .
In the last experiment, we explore the impact on the performance of the NIS scheme of both the number of observations, N, and the number of clipped weights, . Notice that when , the resulting algorithm is the standard importance sampler. Figure 3 shows that, for any number of observations , the bias (left) increases along , whereas the variance (right) decreases. However, there is an elbow in the curves for the variance, which suggests that increasing the value of above does not yield any benefits in terms of variance while the bias keeps increasing linearly. Another remarkable result is that, as , grows, the bias decreases and the variance increases. This is due to the target pdf concentrating in an ever smaller region as the number of observations, , grows, which, in turn, makes sampling more difficult. In such a case, the benefits stemming from using NIS are more obvious. This can be seen by comparing, e.g., the variance when (plain IS) and for observations.
6 Conclusion
We have investigated the benefits of applying a nonlinear transformation to the IS weights in order to alleviate the well-known degeneracy problem. Our computer simulations show that, while both the IS and NIS schemes converge to the same approximations when the number of samples is large enough, the estimators computed via the NIS method attain an advantageous variance/bias trade-off that often results in a better practical performance.
\ack
This work was supported by Ministerio de Economía y Competitividad of Spain (projects TEC2012-38883-C02-01 and TEC2015-69868-C2-1-R) and the Office of Naval Research Global (award no. N62909- 15-1-2011).
M. A. Vázquez and J. Míguez (Departamento de Teoría de la Señal y Comunicaciones, Universidad Carlos III de Madrid, Spain)
E-mail: {mvazquez,jmiguez}@tsc.uc3m.es
The reference list from the paper itself. Each links out to its DOI / PubMed record.
- 1[1] C. P. Robert, G. Casella, Monte Carlo Statistical Methods, Springer, 2004.
- 2[2] T. Bengtsson, P. Bickel, B. Li, et al., Curse-of-dimensionality revisited: Collapse of the particle filter in very large scale systems, in: Probability and statistics: Essays in honor of David A. Freedman, Institute of Mathematical Statistics, 2008, pp. 316–334.
- 3[3] O. Cappe, A. Guillin, J. Marin, C. Robert, Population Monte Carlo, Journal of Computational and Graphical Statistics 13 (4) (2004) 907–929.
- 4[4] E. Koblents, J. Míguez, A population Monte Carlo scheme with transformed weights and its application to stochastic kinetic models, Statistics and Computing 25 (2) (2015) 407–425.
