0

If $p_\theta(x)$ can be reparameterized as $p(\epsilon)$, s.t. $x=g(\theta, \epsilon)$, why $\frac{\partial}{\partial \theta} \int f(x) p_{\theta}(x)dx = \int p(\epsilon) \frac{\partial}{\partial x} f(x) \frac{\partial}{\partial \theta} g(\theta, \epsilon) d\epsilon$?

It is a description in the eq. (3.5) of (https://mlg.eng.cam.ac.uk/yarin/thesis/thesis.pdf). I am reading the paper but poor in mathematic to figure out this equation. I will really appreciate it if anyone can give me some hints. :)

1 Answers1

0

I just answer the question myself. The answer is originally in the page 33 of (https://mlg.eng.cam.ac.uk/yarin/thesis/thesis.pdf).

We can write the $p_\theta(x) = \int p(\theta |\epsilon) p(\epsilon) d \epsilon$, with $p(\theta | \epsilon) = \delta(x - g(\theta, \epsilon))$, then we can write down the expectation above as \begin{align*} \frac{\partial}{\partial \theta} \int f(x) p_\theta(x) dx &= \frac{\partial}{\partial \theta} \int f(x) p(\theta | \epsilon) p(\epsilon) d\epsilon dx \\ &=\frac{\partial}{\partial \theta} \int (\int f(x) \delta(x - g(\theta, \epsilon) )dx) p(\epsilon) d\epsilon \\ &= \frac{\partial}{\partial \theta} \int f(g(\theta, \epsilon))p(\epsilon)d\epsilon \\ &= \int \frac{\partial}{\partial \theta} f(g(\theta, \epsilon))p(\epsilon)d\epsilon \\ &= \int f'(g(\theta, \epsilon))\frac{\partial}{\partial \theta} g(\theta, \epsilon)p(\epsilon)d\epsilon , \end{align*} defining $f'(x) = \frac{\partial}{\partial x} f(x)$.