@@ -9,7 +9,7 @@ const test_props = [Proposals.Rejection(maxiter=Int(1e6)), Proposals.RWalk(ratio
99 sampler = Nested (D, 50 D; bounds= bound, proposal= proposal)
1010
1111 chain, state = sample (rng, model, sampler; dlogz= 0.01 )
12- chain_res = sample (chain, Weights (vec (chain[:weights ])), length (chain))
12+ chain_res = sample (rng, chain, Weights (vec (chain[:weights ])), length (chain))
1313 # test posteriors
1414 vals = Array (chain_res)
1515 means = mean (vals, dims= 1 )
@@ -64,7 +64,7 @@ const test_props = [Proposals.Rejection(maxiter=Int(1e6)), Proposals.RWalk(ratio
6464
6565 spl = Nested (2 , 1000 , bounds= bound, proposal= proposal)
6666 chain, state = sample (rng, model, spl; dlogz= 0.01 )
67- chain_res = sample (chain, Weights (vec (chain[:weights ])), length (chain))
67+ chain_res = sample (rng, chain, Weights (vec (chain[:weights ])), length (chain))
6868
6969 diff = state. logz - analytic_logz
7070 atol = 6 state. logzerr
@@ -90,7 +90,7 @@ const test_props = [Proposals.Rejection(maxiter=Int(1e6)), Proposals.RWalk(ratio
9090
9191 @test state. logz ≈ logz atol = 5 state. logzerr
9292
93- chain_res = sample (chain, Weights (vec (chain[:weights ])), length (chain))
93+ chain_res = sample (rng, chain, Weights (vec (chain[:weights ])), length (chain))
9494 xmodes = sort! (findpeaks (chain_res[:, 1 , 1 ])[1 : 5 ])
9595 @test all (isapprox .(xmodes, 0.1 : 0.2 : 0.9 , atol= 0.2 ))
9696 ymodes = sort! (findpeaks (chain_res[:, 2 , 1 ])[1 : 5 ])
0 commit comments