Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes and improvements to experimental Gibbs #2231

Merged
merged 40 commits into from
Jul 16, 2024
Merged
Changes from 1 commit
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
0b2279f
moved new Gibbs tests all into a single block
torfjelde Apr 23, 2024
dcad548
initial work on making Gibbs work with `externalsampler`
torfjelde Apr 23, 2024
8e2d7be
Merge branch 'master' into torfjelde/gibbs-new-improv
torfjelde May 18, 2024
4a609cb
removed references to Setfield.jl
torfjelde May 18, 2024
fc21894
fixed crucial bug in experimental Gibbs sampler
torfjelde May 18, 2024
9910962
added ground-truth comparison for Gibbs sampler on demo models
torfjelde May 18, 2024
b3a4692
added convenience method for performing two sample KS test
torfjelde May 18, 2024
3e17efc
use thinning to avoid OOM issues
torfjelde May 20, 2024
429fc8f
removed incredibly slow testset that didn't really add much
torfjelde May 20, 2024
f6af20e
removed now-redundant testset
torfjelde May 20, 2024
065eef6
use Anderson-Darling test instead of Kolomogorov-Smirnov to better
torfjelde May 20, 2024
c2d23e5
Merge branch 'master' into torfjelde/gibbs-new-improv
torfjelde Jun 4, 2024
99f28f9
more work on testing
torfjelde Jun 6, 2024
6df1ccc
Merge branch 'master' into torfjelde/gibbs-new-improv
torfjelde Jun 6, 2024
b6a907e
fixed tests
torfjelde Jun 6, 2024
a4e223e
Merge remote-tracking branch 'origin/torfjelde/gibbs-new-improv' into…
torfjelde Jun 6, 2024
e1e7386
make failures of `two_sample_ad_tests` a bit more informative
torfjelde Jun 6, 2024
be1ec7f
make failrues of `two_sample_ad_test` produce more informative logs
torfjelde Jun 6, 2024
5f36446
additional information upon `two_sample_ad_test` failure
torfjelde Jun 6, 2024
3be8f8b
rename `two_sample_ad_test` to `two_sample_test` and use KS test instead
torfjelde Jun 6, 2024
dbaf447
added minor test for externalsampler usage
torfjelde Jun 16, 2024
f44c407
also test AdvancedHMC samplers with Gibbs
torfjelde Jun 16, 2024
dd86cfa
forgot to add updates to src/mcmc/abstractmcmc.jl in previous commits
torfjelde Jun 17, 2024
4160577
Merge remote-tracking branch 'origin/torfjelde/gibbs-new-improv' into…
torfjelde Jun 17, 2024
2a7d85b
Merge branch 'master' into torfjelde/gibbs-new-improv
torfjelde Jun 17, 2024
bdc61fe
removed usage of `timeit_testset` macro
torfjelde Jun 17, 2024
d76243e
added temporary fix for externalsampler that needs to be removed once
torfjelde Jun 17, 2024
14f5c89
minor reorg of two testsets
torfjelde Jun 17, 2024
5893d54
set random seeds more aggressively in an attempt to make tests more r…
torfjelde Jun 18, 2024
4a2cea2
Merge branch 'master' into torfjelde/gibbs-new-improv
yebai Jun 18, 2024
4f30ea5
removed hack, awaiting PR to DynamicPPL
torfjelde Jun 18, 2024
414a077
Merge branch 'master' into torfjelde/gibbs-new-improv
yebai Jun 26, 2024
89bc2e1
renamed `_getmodel` to `getmodel`, `_setmodel` to `setmodel`, and
torfjelde Jun 26, 2024
3d3c944
missed some instances during rnenaming
torfjelde Jun 26, 2024
e1f1a0e
fixed missing merge in initial step for experimental `Gibbs`
torfjelde Jul 10, 2024
7c4368e
Always reconstruct `ADGradientWrapper` using the `adype` available in…
torfjelde Jul 15, 2024
06357c6
Test Gibbs with different adtype in externalsampler to ensure that works
torfjelde Jul 15, 2024
02f9fad
Update Project.toml
yebai Jul 15, 2024
30ab9e0
Update Project.toml
yebai Jul 15, 2024
d40d82b
Merge branch 'master' into torfjelde/gibbs-new-improv
yebai Jul 15, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
use thinning to avoid OOM issues
torfjelde committed May 20, 2024
commit 3e17efca6a8a2fc0f318a7e1c395c833a0a6fbd5
7 changes: 5 additions & 2 deletions test/experimental/gibbs.jl
Original file line number Diff line number Diff line change
@@ -80,8 +80,9 @@ has_dot_assume(::Model) = true
# All the chains should converge easily, so by subsampling to a much lower
# number of samples, we should be left with something we can compare easily to
# "ground truth" samples (using NUTS here, but should implement exact sampling).
num_samples = 1_000
num_iterations = 5_000
num_samples = 500
num_iterations = 1_000
thinning = 10
num_chains = 4

# Determine initial parameters to make comparison as fair as possible.
@@ -109,6 +110,7 @@ has_dot_assume(::Model) = true
progress = false,
initial_params = initial_params,
discard_initial = 1_000,
thinning = thinning
),
num_samples,
)
@@ -124,6 +126,7 @@ has_dot_assume(::Model) = true
num_chains;
progress = false,
initial_params = initial_params,
thinning = thinning,
),
num_samples,
)