Skip to content

Commit b41a4b1

Browse files
committed
Fix merge
1 parent 119c818 commit b41a4b1

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/mcmc/external_sampler.jl

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,10 @@ function AbstractMCMC.step(
182182
rng, AbstractMCMC.LogDensityModel(f), sampler, state.state; kwargs...
183183
)
184184

185-
new_parameters = getparams(f.model, state_inner)
185+
# NOTE: This is Turing.Inference.getparams, not AbstractMCMC.getparams (!!!!!)
186+
# The latter uses the state rather than the transition.
187+
# TODO(penelopeysm): Make this use AbstractMCMC.getparams instead
188+
new_parameters = Turing.Inference.getparams(f.model, transition_inner)
186189
new_vi = DynamicPPL.unflatten(f.varinfo, new_parameters)
187190
return (
188191
Transition(f.model, new_vi, transition_inner), TuringState(state_inner, new_vi, f)

0 commit comments

Comments
 (0)