From 6c25663281ee03f3bf8982a1468f340fb2c68cf9 Mon Sep 17 00:00:00 2001 From: thorek1 Date: Mon, 28 Oct 2024 21:50:00 +0100 Subject: [PATCH] fix estim tests --- test/test_1st_order_inversion_filter_estimation.jl | 4 ++-- test/test_2nd_order_estimation.jl | 4 ++-- test/test_3rd_order_estimation.jl | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/test/test_1st_order_inversion_filter_estimation.jl b/test/test_1st_order_inversion_filter_estimation.jl index 6653c531..4abac1cd 100644 --- a/test/test_1st_order_inversion_filter_estimation.jl +++ b/test/test_1st_order_inversion_filter_estimation.jl @@ -73,8 +73,8 @@ while !isfinite(LPmax) && i < 1000 Pigeons.sample_iid!(FS2000_lp, replica, pt.shared) new_LP = FS2000_lp(replica.state) if new_LP > LPmax - LPmax = new_LP - XMAX = deepcopy(replica.state) + global LPmax = new_LP + global XMAX = deepcopy(replica.state) end i += 1 end diff --git a/test/test_2nd_order_estimation.jl b/test/test_2nd_order_estimation.jl index 75d28e94..dcb486de 100644 --- a/test/test_2nd_order_estimation.jl +++ b/test/test_2nd_order_estimation.jl @@ -59,8 +59,8 @@ while !isfinite(LPmax) && i < 1000 Pigeons.sample_iid!(FS2000_lp, replica, pt.shared) new_LP = FS2000_lp(replica.state) if new_LP > LPmax - LPmax = new_LP - XMAX = deepcopy(replica.state) + global LPmax = new_LP + global XMAX = deepcopy(replica.state) end i += 1 end diff --git a/test/test_3rd_order_estimation.jl b/test/test_3rd_order_estimation.jl index 3a4632a3..c8ead811 100644 --- a/test/test_3rd_order_estimation.jl +++ b/test/test_3rd_order_estimation.jl @@ -78,8 +78,8 @@ while !isfinite(LPmax) && i < 1000 Pigeons.sample_iid!(Caldara_lp, replica, pt.shared) new_LP = Caldara_lp(replica.state) if new_LP > LPmax - LPmax = new_LP - XMAX = deepcopy(replica.state) + global LPmax = new_LP + global XMAX = deepcopy(replica.state) end i += 1 end