aesara-devs / aehmc

An HMC/NUTS implementation in Aesara
MIT License
33 stars 6 forks source link

Acceptance probability in NUTS #54

Closed rlouf closed 2 years ago

rlouf commented 2 years ago

Work on on #48 showed that the computed values of the acceptance_probability for the NUTS algorithms were sometimes completely wrong. This PR fixes the way the value is computed and also makes the computation more numerically stable.

codecov[bot] commented 2 years ago

Codecov Report

Merging #54 (02339a0) into main (2a7dbaf) will not change coverage. The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##              main       #54   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           13        13           
  Lines          464       464           
  Branches        26        26           
=========================================
  Hits           464       464           
Impacted Files Coverage Δ
aehmc/nuts.py 100.00% <100.00%> (ø)
aehmc/proposals.py 100.00% <100.00%> (ø)
aehmc/trajectory.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 2a7dbaf...02339a0. Read the comment docs.