-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
Closed
Labels
performanceMust go fasterMust go fasterregressionRegression in behavior compared to a previous versionRegression in behavior compared to a previous versionregression 1.11Regression in the 1.11 releaseRegression in the 1.11 releasetypes and dispatchTypes, subtyping and method dispatchTypes, subtyping and method dispatch
Description
module MWE
using Turing
using Turing: DynamicPPL
using Random
Random.seed!(42)
num_iterations = 10_000
adbackend = AutoForwardDiff()
@model function m(x=1.5)
s ~ InverseGamma(2, 3)
m ~ Normal(0, sqrt(s))
x ~ Normal(m, s)
return nothing
end
model = m()
initial_params = [0.5, 0.5]
component_sampler = HMC(0.1, 32; adtype=adbackend)
sampler = Turing.Gibbs(@varname(s) => component_sampler, @varname(m) => component_sampler)
@info "Starting sampling"
sample(model, sampler, num_iterations; initial_params=initial_params)
endThe above code runs in about 4s on v1.10.6 and in about 30s on v1.11.2 (recording second runs, so excluding compilation time). This is using the latest master from Turing.jl.
I would need to minimise the example to find the cause, but does anyone have clues as to where to look? A type inference failure seems like a possibility to me, any known regressions there on v1.11?
Metadata
Metadata
Assignees
Labels
performanceMust go fasterMust go fasterregressionRegression in behavior compared to a previous versionRegression in behavior compared to a previous versionregression 1.11Regression in the 1.11 releaseRegression in the 1.11 releasetypes and dispatchTypes, subtyping and method dispatchTypes, subtyping and method dispatch