Skip to content

Commit 5a3f7aa

Browse files
authored
Suppress info message with verbose=false (#2657)
* Suppress info message with verbose=false * Fix changelog typos
1 parent ac93c30 commit 5a3f7aa

File tree

3 files changed

+8
-3
lines changed

3 files changed

+8
-3
lines changed

HISTORY.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
# 0.41.1
1+
# 0.40.2
2+
3+
`sample(model, NUTS(), N; verbose=false)` now suppresses the 'initial step size' message.
4+
5+
# 0.40.1
26

37
Extra release to trigger Documenter.jl build (when 0.40.0 was released GitHub was having an outage).
48
There are no code changes.

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name = "Turing"
22
uuid = "fce5fe82-541a-59a6-adf8-730c64b5f9a0"
3-
version = "0.40.1"
3+
version = "0.40.2"
44

55
[deps]
66
ADTypes = "47edcb42-4c32-4615-8424-f2b9edc5f35b"

src/mcmc/hmc.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,7 @@ function DynamicPPL.initialstep(
181181
vi_original::AbstractVarInfo;
182182
initial_params=nothing,
183183
nadapts=0,
184+
verbose::Bool=true,
184185
kwargs...,
185186
)
186187
# Transform the samples to unconstrained space and compute the joint log probability.
@@ -211,7 +212,7 @@ function DynamicPPL.initialstep(
211212
# Find good eps if not provided one
212213
if iszero(spl.alg.ϵ)
213214
ϵ = AHMC.find_good_stepsize(rng, hamiltonian, theta)
214-
@info "Found initial step size" ϵ
215+
verbose && @info "Found initial step size" ϵ
215216
else
216217
ϵ = spl.alg.ϵ
217218
end

0 commit comments

Comments
 (0)