File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -60,6 +60,10 @@ using DynamicPPL:
6060 AbstractContext,
6161 AbstractVarInfo,
6262 AccumulatorTuple,
63+ InitContext,
64+ InitFromParams,
65+ InitFromPrior,
66+ InitFromUniform,
6367 LogJacobianAccumulator,
6468 LogLikelihoodAccumulator,
6569 LogPriorAccumulator,
@@ -123,6 +127,9 @@ function DynamicPPL.get_param_eltype(
123127 return eltype (leaf_ctx. params)
124128 elseif leaf_ctx isa InitContext{<: Any ,<: InitFromParams }
125129 return DynamicPPL. infer_nested_eltype (leaf_ctx. strategy. params)
130+ elseif leaf_ctx isa InitContext{<: Any ,<: Union{InitFromPrior,InitFromUniform} }
131+ # No need to enforce any particular eltype here, since new parameters are sampled
132+ return Any
126133 else
127134 error (
128135 " OnlyAccsVarInfo can only be used with FastEval contexts, found $(typeof (leaf_ctx)) " ,
You can’t perform that action at this time.
0 commit comments