3
$\begingroup$

(After some pondering, what I really wanted to ask is how to incorporate prior information about $f$ into a sampling method - see this question.)

Suppose you want to draw samples from an (unnormalized) pdf $f(x)$, $x \in \mathbb{R}^d$, $1 \le d \le 20$, which might be expensive to compute, and you have a (normalized) pdf, $g(x)$, which is an approximation of $f(x)$. We also assume that you can easily draw i.i.d. samples from $g(x)$, and $g(x)$ has a simple analytical form (e.g., we can derive gradients). As a practical example, let us assume that $g(x)$ is a mixture of Gaussians or $t$ distributions.

Note that $f(x)$ is black-box, so we do not know much about it besides assuming that $g(x)$ is a "decent" approximation thereof (which I deliberately leave vague).

There are several ways to proceed here:

  1. A standard approach would consist of using $g(x)$ as a proposal distribution of an independent Metropolis MCMC sampler (perhaps after "fattening" the tails of $g(x)$). Clearly, the acceptance/reject ratio would be based on actual values of $f(x)$.
  2. Some mix of importance sampling and independent Metropolis, such as the approach described in this paper (Edit: I originally mistakenly wrote "importance sampling/resampling", but that would not produce unbiased samples from $f(x)$).
  3. We could use $g(x)$ as a surrogate function and perform Hamiltonian Monte Carlo (or other efficient transition operators) on the surrogate, with acceptance/rejection based on the true $f(x)$.

I am trying to figure out whether there would be reasons or situations in which to prefer (3) to (1), or other methods to (1). Any idea?


A note after the discussion in the comments. The acceptance ratio of an independent Metropolis proposal from $g$ is: $$a\left(x_\text{old} \rightarrow x_\text{new}\right) = \min \left(1, \frac{f(x_\text{new})}{f(x_\text{old})} \cdot \frac{g(x_\text{old})}{g(x_\text{new})} \right). $$ In the limit $g \rightarrow f$ we have that $a \rightarrow 1$. This suggests that if $g$ is a very good approximation to $f$, one can't do much better than (1). However, if $g$ is an okay approximation to $f$, there might be better things to do.

$\endgroup$
6
  • 2
    $\begingroup$ I don't understand your question. It seems you're only asking how to sample from $g$ which apparently has nothing to do with the fact that it happens to be an approximation of another density $f$. $\endgroup$
    – dsaxton
    Commented May 24, 2016 at 19:23
  • 1
    $\begingroup$ It seems like you already have your answer. I would default to #1 since I am not too familiar with Hamiltonian MC, but then again, why would you use Hamiltonian MC? $\endgroup$
    – Jon
    Commented May 24, 2016 at 19:45
  • 1
    $\begingroup$ If you can generate exactly from $g$, using Hamiltonian MC is a perfect waste of computing time. And importance sampling/resampling does not produce samples from $f$. $\endgroup$
    – Xi'an
    Commented May 24, 2016 at 19:53
  • $\begingroup$ Oh, yeah, (2) is wrong, thanks @Xi'an -- not sure why I wrote that as an option. And I suppose that in the limit $f \rightarrow g$, one can't do better than independent Metropolis, since the acceptance ratio converges to 1. So there is no reason to do anything but (1). Is this correct? (The only reason would be if we have $g$ but we cannot directly sample from it, I suppose.) $\endgroup$
    – lacerbi
    Commented May 24, 2016 at 21:32
  • $\begingroup$ Thanks all for the useful comments -- I clarified my question and added more details. $\endgroup$
    – lacerbi
    Commented May 24, 2016 at 22:08

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.