Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
ciguaran committed Aug 15, 2024
1 parent 5c34177 commit 8145cbb
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions tests/smc/test_waste_free_smc.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
import blackjax.smc.resampling as resampling
from blackjax import adaptive_tempered_smc, tempered_smc
from blackjax.smc import extend_params
from blackjax.smc.waste_free import waste_free_smc, update_waste_free
from blackjax.smc.waste_free import update_waste_free, waste_free_smc
from tests.smc import SMCLinearRegressionTestCase
from tests.smc.test_tempered_smc import inference_loop

Expand Down Expand Up @@ -107,14 +107,13 @@ def test_adaptive_tempered_smc(self):

def test_waste_free_set_num_mcmc_steps():
with pytest.raises(ValueError) as exc_info:
update_waste_free(lambda x:x,
lambda x:1,
lambda x:1,
100,
10,
3,
num_mcmc_steps=50)
assert str(exc_info.value).startswith("Can't use waste free SMC with a num_mcmc_steps parameter")
update_waste_free(
lambda x: x, lambda x: 1, lambda x: 1, 100, 10, 3, num_mcmc_steps=50
)
assert str(exc_info.value).startswith(
"Can't use waste free SMC with a num_mcmc_steps parameter"
)


if __name__ == "__main__":
absltest.main()

0 comments on commit 8145cbb

Please sign in to comment.