@@ -20,7 +20,7 @@ def test_cycle_component_deterministic(rng):
20
20
cycle = st .CycleComponent (
21
21
name = "cycle" , cycle_length = 12 , estimate_cycle_length = False , innovations = False
22
22
)
23
- params = {"cycle " : np .array ([1.0 , 1.0 ], dtype = config .floatX )}
23
+ params = {"params_cycle " : np .array ([1.0 , 1.0 ], dtype = config .floatX )}
24
24
x , y = simulate_from_numpy_model (cycle , rng , params , steps = 12 * 12 )
25
25
26
26
assert_pattern_repeats (y , 12 , atol = ATOL , rtol = RTOL )
@@ -30,7 +30,10 @@ def test_cycle_component_with_dampening(rng):
30
30
cycle = st .CycleComponent (
31
31
name = "cycle" , cycle_length = 12 , estimate_cycle_length = False , innovations = False , dampen = True
32
32
)
33
- params = {"cycle" : np .array ([10.0 , 10.0 ], dtype = config .floatX ), "dampening_factor_cycle" : 0.75 }
33
+ params = {
34
+ "params_cycle" : np .array ([10.0 , 10.0 ], dtype = config .floatX ),
35
+ "dampening_factor_cycle" : 0.75 ,
36
+ }
34
37
x , y = simulate_from_numpy_model (cycle , rng , params , steps = 100 )
35
38
36
39
# check that cycle dampens to zero over time
@@ -42,7 +45,7 @@ def test_cycle_component_with_innovations_and_cycle_length(rng):
42
45
name = "cycle" , estimate_cycle_length = True , innovations = True , dampen = True
43
46
)
44
47
params = {
45
- "cycle " : np .array ([1.0 , 1.0 ], dtype = config .floatX ),
48
+ "params_cycle " : np .array ([1.0 , 1.0 ], dtype = config .floatX ),
46
49
"length_cycle" : 12.0 ,
47
50
"dampening_factor_cycle" : 0.95 ,
48
51
"sigma_cycle" : 1.0 ,
@@ -62,7 +65,7 @@ def test_cycle_multivariate_deterministic(rng):
62
65
innovations = False ,
63
66
observed_state_names = ["data_1" , "data_2" , "data_3" ],
64
67
)
65
- params = {"cycle " : np .array ([[1.0 , 1.0 ], [2.0 , 2.0 ], [3.0 , 3.0 ]], dtype = config .floatX )}
68
+ params = {"params_cycle " : np .array ([[1.0 , 1.0 ], [2.0 , 2.0 ], [3.0 , 3.0 ]], dtype = config .floatX )}
66
69
x , y = simulate_from_numpy_model (cycle , rng , params , steps = 12 * 12 )
67
70
68
71
# Check that each variable has a cyclical pattern with the expected period
@@ -116,7 +119,7 @@ def test_cycle_multivariate_with_dampening(rng):
116
119
observed_state_names = ["data_1" , "data_2" , "data_3" ],
117
120
)
118
121
params = {
119
- "cycle " : np .array ([[10.0 , 10.0 ], [20.0 , 20.0 ], [30.0 , 30.0 ]], dtype = config .floatX ),
122
+ "params_cycle " : np .array ([[10.0 , 10.0 ], [20.0 , 20.0 ], [30.0 , 30.0 ]], dtype = config .floatX ),
120
123
"dampening_factor_cycle" : 0.75 ,
121
124
}
122
125
x , y = simulate_from_numpy_model (cycle , rng , params , steps = 100 )
@@ -144,7 +147,7 @@ def test_cycle_multivariate_with_innovations_and_cycle_length(rng):
144
147
observed_state_names = ["data_1" , "data_2" , "data_3" ],
145
148
)
146
149
params = {
147
- "cycle " : np .array ([[1.0 , 1.0 ], [2.0 , 2.0 ], [3.0 , 3.0 ]], dtype = config .floatX ),
150
+ "params_cycle " : np .array ([[1.0 , 1.0 ], [2.0 , 2.0 ], [3.0 , 3.0 ]], dtype = config .floatX ),
148
151
"length_cycle" : 12.0 ,
149
152
"dampening_factor_cycle" : 0.95 ,
150
153
"sigma_cycle" : np .array ([0.5 , 1.0 , 1.5 ]), # different innov variances per var
0 commit comments