Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

ease test tolerance on timeseries#659

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
bnavigator merged 1 commit intopython-control:masterfrombnavigator:easetol
Nov 3, 2021
Merged
Show file tree
Hide file tree
Changes fromall commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletionscontrol/tests/flatsys_test.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -339,8 +339,9 @@ def test_point_to_point_errors(self):
traj_kwarg = fs.point_to_point(
flat_sys, timepts, x0, u0, xf, uf, cost=cost_fcn,
basis=fs.PolyFamily(8), minimize_kwargs={'method': 'slsqp'})
np.testing.assert_almost_equal(
traj_method.eval(timepts)[0], traj_kwarg.eval(timepts)[0])
np.testing.assert_allclose(
traj_method.eval(timepts)[0], traj_kwarg.eval(timepts)[0],
atol=1e-5)

# Unrecognized keywords
with pytest.raises(TypeError, match="unrecognized keyword"):
Expand Down
3 changes: 2 additions & 1 deletioncontrol/tests/timeresp_test.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -681,7 +681,8 @@ def test_forced_response_T_U(self, tsystem, fr_kwargs, refattr):
fr_kwargs['X0'] = tsystem.X0
t, y = forced_response(tsystem.sys, **fr_kwargs)
np.testing.assert_allclose(t, tsystem.t)
np.testing.assert_allclose(y, getattr(tsystem, refattr), rtol=1e-3)
np.testing.assert_allclose(y, getattr(tsystem, refattr),
rtol=1e-3, atol=1e-5)

@pytest.mark.parametrize("tsystem", ["siso_ss1"], indirect=True)
def test_forced_response_invalid_c(self, tsystem):
Expand Down

[8]ページ先頭

©2009-2025 Movatter.jp