I changed lub_constrain in prob/transform so that
it throws a std domain error if !(lower < upper).
I also changed the lub_constrain w/o Jacobians so
that it is bounded away from 0 and 1 like the one
with Jacobians. (See the previous message for more
on the ramifications for gradients.)
More on Matt's point about NUTS below.
On 8/18/12 1:24 PM, Matt Hoffman wrote:
> This might be ok sometimes, but it probably won't be in general.
> Consider the scenario where the initial momentum for y is large
> compared to the momenta for the other variables. y is going to get a
> good running start in some random direction, and the other variables'
> trajectories are going to take a little while to turn around. But by
> the time they do, the overall trajectory will be dominated by the y
> dimension, so we'll never satisfy the u-turn criterion, so each
> iteration runs until we reach max_treedepth.
>
> Basically, improper posteriors are always trouble.
Very good point. I hadn't thought about the
implications of the posterior on the transformed
params for the U-turn condition.
I don't know about "always". This wouldn't be a problem
for plain-old HMC!
- Bob