Skip to content

Commit 632ab09

Browse files
committed
Remove default_varinfo function
1 parent 54691bf commit 632ab09

File tree

1 file changed

+1
-14
lines changed

1 file changed

+1
-14
lines changed

src/sampler.jl

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -67,19 +67,6 @@ function AbstractMCMC.step(
6767
return vi, nothing
6868
end
6969

70-
function default_varinfo(rng::Random.AbstractRNG, model::Model, sampler::AbstractSampler)
71-
return default_varinfo(rng, model, sampler, DefaultContext())
72-
end
73-
function default_varinfo(
74-
rng::Random.AbstractRNG,
75-
model::Model,
76-
sampler::AbstractSampler,
77-
context::AbstractContext,
78-
)
79-
init_sampler = initialsampler(sampler)
80-
return VarInfo(rng, model, init_sampler, context)
81-
end
82-
8370
function AbstractMCMC.sample(
8471
rng::Random.AbstractRNG,
8572
model::Model,
@@ -100,7 +87,7 @@ function AbstractMCMC.step(
10087
rng::Random.AbstractRNG, model::Model, spl::Sampler; initial_params=nothing, kwargs...
10188
)
10289
# Sample initial values.
103-
vi = default_varinfo(rng, model, spl)
90+
vi = typed_varinfo(rng, model, initialsampler(spl), DefaultContext())
10491

10592
# Update the parameters if provided.
10693
if initial_params !== nothing

0 commit comments

Comments
 (0)