From 37481ac4b77d5fe5faac11487cc340024d1564ed Mon Sep 17 00:00:00 2001 From: Jaime RZ Date: Thu, 27 Jul 2023 15:24:52 +0100 Subject: [PATCH] removing last HMCKernel legacy function (#339) * removing last HMCKernel legacy function * AbstractTrajectory * Revert "AbstractTrajectory" This reverts commit 103fded3763cf2ed3479f328585cd1a59a4892b3. --- src/AdvancedHMC.jl | 17 +---------------- test/sampler-vec.jl | 2 +- 2 files changed, 2 insertions(+), 17 deletions(-) diff --git a/src/AdvancedHMC.jl b/src/AdvancedHMC.jl index 40b409b9..17f2bdac 100644 --- a/src/AdvancedHMC.jl +++ b/src/AdvancedHMC.jl @@ -66,24 +66,9 @@ export Trajectory, # Useful defaults -# Deprecations for trajectory.jl - -abstract type AbstractTrajectory end - -struct StaticTrajectory{TS} end -@deprecate StaticTrajectory{TS}(int::AbstractIntegrator, L) where {TS} HMCKernel( - Trajectory{TS}(int, FixedNSteps(L)), -) -@deprecate StaticTrajectory(int::AbstractIntegrator, L) HMCKernel( - Trajectory{EndPointTS}(int, FixedNSteps(L)), -) -@deprecate StaticTrajectory(ϵ::AbstractScalarOrVec{<:Real}, L) HMCKernel( - Trajectory{EndPointTS}(Leapfrog(ϵ), FixedNSteps(L)), -) - @deprecate find_good_eps find_good_stepsize -export StaticTrajectory, find_good_eps +export find_good_eps include("adaptation/Adaptation.jl") using .Adaptation diff --git a/test/sampler-vec.jl b/test/sampler-vec.jl index 9b40f21f..2b85614a 100644 --- a/test/sampler-vec.jl +++ b/test/sampler-vec.jl @@ -83,7 +83,7 @@ include("common.jl") # Simple time benchmark let metricT = UnitEuclideanMetric - κ = StaticTrajectory(lf, n_steps) + κ = HMCKernel(Trajectory{EndPointTS}(lf, FixedNSteps(n_steps))) time_mat = Vector{Float64}(undef, n_chains_max) for (i, n_chains) in enumerate(n_chains_list)