File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 150
150
@test all (isone (p. trajectory. f. x) for p in chains_pg)
151
151
@test mean (x. logevidence for x in chains_pg) ≈ - 2 * log (2 ) atol = 0.01
152
152
end
153
-
153
+
154
154
@testset " Replay reference" begin
155
155
mutable struct Model <: AbstractMCMC.AbstractModel
156
156
a:: Float64
157
157
b:: Float64
158
158
159
159
Model () = new ()
160
160
end
161
-
161
+
162
162
function (m:: Model )(rng)
163
163
m. a = rand (rng, Normal ())
164
164
AdvancedPS. observe (Normal (), m. a)
165
165
166
166
m. b = rand (rng, Normal ())
167
- AdvancedPS. observe (Normal (), m. b)
167
+ return AdvancedPS. observe (Normal (), m. b)
168
168
end
169
169
170
170
pg = AdvancedPS. PG (1 )
171
- first, second = sample (Model (), pg, 2 );
171
+ first, second = sample (Model (), pg, 2 )
172
172
173
173
first_model = first. trajectory. f
174
174
second_model = second. trajectory. f
You can’t perform that action at this time.
0 commit comments