File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -1329,12 +1329,13 @@ end
1329
1329
1330
1330
function _inner_transform! (md:: Metadata , vi:: VarInfo , vn:: VarName , f)
1331
1331
# TODO : Use inplace versions to avoid allocations
1332
- yvec, logjac = with_logabsdet_jacobian (f, getindex_internal (vi, vn ))
1332
+ yvec, logjac = with_logabsdet_jacobian (f, getindex_internal (vi, md ))
1333
1333
# Determine the new range.
1334
- start = first (getrange (vi , vn))
1334
+ start = first (getrange (md , vn))
1335
1335
# NOTE: `length(yvec)` should never be longer than `getrange(vi, vn)`.
1336
- setrange! (vi , vn, start: (start + length (yvec) - 1 ))
1336
+ setrange! (md , vn, start: (start + length (yvec) - 1 ))
1337
1337
# Set the new value.
1338
+ # TODO : should replace this with a `setval!` for `Metadata`.
1338
1339
setval! (vi, yvec, vn)
1339
1340
acclogp!! (vi, - logjac)
1340
1341
return vi
You can’t perform that action at this time.
0 commit comments