Some MCMC proposals with non-trivial boundaries breaks detailed balance
@gregory.ashton noticed that some periodic parameters return biased results when using the density estimate proposals. This is because we don't track the correct jacobian term that takes into account the wrapping/folding for this and other proposals that have non-trivial jacobians.
I think the simplest fix would be to only call the apply_boundaries
method if the log_jacobian == 0
.
Correctly tracking the full density would be a combinatoric nightmare in large numbers of dimensions with arbitrary combinations of boundaries.