Skip to content

Commit 35432c0

Browse files
committed
Do not convert NamedTuple to Dict
1 parent a494d00 commit 35432c0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/contexts/init.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ struct InitFromParams{P,S<:Union{AbstractInitStrategy,Nothing}} <: AbstractInitS
102102
function InitFromParams(
103103
params::NamedTuple, fallback::Union{AbstractInitStrategy,Nothing}=InitFromPrior()
104104
)
105-
return InitFromParams(to_varname_dict(params), fallback)
105+
return new{typeof(params),typeof(fallback)}(params, fallback)
106106
end
107107
end
108108
function init(rng::Random.AbstractRNG, vn::VarName, dist::Distribution, p::InitFromParams)

0 commit comments

Comments
 (0)