This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
cs401r_w2016:lab10 [2016/03/17 20:37] admin |
cs401r_w2016:lab10 [2016/03/17 20:39] admin |
||
---|---|---|---|
Line 76: | Line 76: | ||
A detailed explanation of Hamiltonian MCMC can be found here:[[http://www.mcmchandbook.net/HandbookChapter5.pdf|Hamiltonian MCMC]]. | A detailed explanation of Hamiltonian MCMC can be found here:[[http://www.mcmchandbook.net/HandbookChapter5.pdf|Hamiltonian MCMC]]. | ||
- | - You will find the equations describing the leapfrog method in Equations 5.18, 5.19 and 5.20. | + | * You will find the equations describing the leapfrog method in Equations 5.18, 5.19 and 5.20. |
- | - You will find a description of how to convert a given ''p(x)'' into a Hamiltonian in Section 5.3.1. | + | * You will find a description of how to convert a given ''p(x)'' into a Hamiltonian in Section 5.3.1. |
- | - You will find a description of the complete HMC algorithm in section 5.3.2.1 | + | * You will find a description of the complete HMC algorithm in section 5.3.2.1 |
- | Remember that you will alternate between two steps: | + | Remember that you will alternate between two steps: |
+ | |||
+ | - Sampling the momentum conditioned on the position. This is just sampling from a Gaussian. | ||
+ | - Proposing a new state for the position, given the momentum. This involves integrating the dynamics, and then accepting or rejecting based on integration error. | ||
You will have to tune two parameters in order to implement HMC: the variance of the momentum variables, and the timestep used for integrating the dynamics. Experiment with both, and report your results using plots like those you prepared for Part 1. | You will have to tune two parameters in order to implement HMC: the variance of the momentum variables, and the timestep used for integrating the dynamics. Experiment with both, and report your results using plots like those you prepared for Part 1. |