File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change 285
285
unvectorize (dists:: AbstractVector ) = length (dists) == 1 ? first (dists) : dists
286
286
287
287
# possibly unpack and reshape samples according to the prior distribution
288
- reconstruct (dist:: Distribution , val:: AbstractVector ) = DynamicPPL. reconstruct (dist, val)
289
- function reconstruct (dist:: AbstractVector{<:UnivariateDistribution} , val:: AbstractVector )
290
- return val
291
- end
288
+ reconstruct (dist:: Distribution , val:: AbstractVector ) = DynamicPPL. from_vec_transform (dist)(val)
289
+ reconstruct (dist:: AbstractVector{<:UnivariateDistribution} , val:: AbstractVector ) = val
292
290
function reconstruct (dist:: AbstractVector{<:MultivariateDistribution} , val:: AbstractVector )
293
291
offset = 0
294
292
return map (dist) do d
322
320
:(
323
321
$ name = reconstruct (
324
322
unvectorize (DynamicPPL. getdist .(Ref (vi), vns.$ name)),
325
- DynamicPPL. getval (vi, vns.$ name),
323
+ DynamicPPL. getindex_internal (vi, vns.$ name),
326
324
)
327
325
) for name in names
328
326
]
You can’t perform that action at this time.
0 commit comments