Skip to content

Commit

Permalink
Fix test to correct calls of func_KS/ST
Browse files Browse the repository at this point in the history
  • Loading branch information
AhmadAmine998 committed Oct 2, 2024
1 parent de44270 commit dfe00de
Showing 1 changed file with 48 additions and 54 deletions.
102 changes: 48 additions & 54 deletions tests/test_dynamics.py
Original file line number Diff line number Diff line change
Expand Up @@ -194,47 +194,43 @@ def test_derivatives(self):
x_ks,
0,
u,
params={
"mu": self.mu,
"C_Sf": self.C_Sf,
"C_Sr": self.C_Sr,
"lf": self.lf,
"lr": self.lr,
"h": self.h,
"m": self.m,
"I": self.I,
"s_min": self.s_min,
"s_max": self.s_max,
"sv_min": self.sv_min,
"sv_max": self.sv_max,
"v_switch": self.v_switch,
"a_max": self.a_max,
"v_min": self.v_min,
"v_max": self.v_max,
},
self.mu,
self.C_Sf,
self.C_Sr,
self.lf,
self.lr,
self.h,
self.m,
self.I,
self.s_min,
self.s_max,
self.sv_min,
self.sv_max,
self.v_switch,
self.a_max,
self.v_min,
self.v_max,
)
f_st = func_ST(
x_st,
0,
u,
params={
"mu": self.mu,
"C_Sf": self.C_Sf,
"C_Sr": self.C_Sr,
"lf": self.lf,
"lr": self.lr,
"h": self.h,
"m": self.m,
"I": self.I,
"s_min": self.s_min,
"s_max": self.s_max,
"sv_min": self.sv_min,
"sv_max": self.sv_max,
"v_switch": self.v_switch,
"a_max": self.a_max,
"v_min": self.v_min,
"v_max": self.v_max,
},
self.mu,
self.C_Sf,
self.C_Sr,
self.lf,
self.lr,
self.h,
self.m,
self.I,
self.s_min,
self.s_max,
self.sv_min,
self.sv_max,
self.v_switch,
self.a_max,
self.v_min,
self.v_max,
)

start = time.time()
Expand All @@ -243,24 +239,22 @@ def test_derivatives(self):
x_st,
0,
u,
params={
"mu": self.mu,
"C_Sf": self.C_Sf,
"C_Sr": self.C_Sr,
"lf": self.lf,
"lr": self.lr,
"h": self.h,
"m": self.m,
"I": self.I,
"s_min": self.s_min,
"s_max": self.s_max,
"sv_min": self.sv_min,
"sv_max": self.sv_max,
"v_switch": self.v_switch,
"a_max": self.a_max,
"v_min": self.v_min,
"v_max": self.v_max,
},
self.mu,
self.C_Sf,
self.C_Sr,
self.lf,
self.lr,
self.h,
self.m,
self.I,
self.s_min,
self.s_max,
self.sv_min,
self.sv_max,
self.v_switch,
self.a_max,
self.v_min,
self.v_max,
)
duration = time.time() - start
avg_fps = 10000 / duration
Expand Down

0 comments on commit dfe00de

Please sign in to comment.