MCPcopy Index your code
hub / github.com/numpy/numpy / assert_poly_almost_equal

Function assert_poly_almost_equal

numpy/polynomial/tests/test_classes.py:44–51  ·  view source on GitHub ↗
(p1, p2, msg="")

Source from the content-addressed store, hash-verified

42
43
44def assert_poly_almost_equal(p1, p2, msg=""):
45 try:
46 assert_(np.all(p1.domain == p2.domain))
47 assert_(np.all(p1.window == p2.window))
48 assert_almost_equal(p1.coef, p2.coef)
49 except AssertionError:
50 msg = f"Result: {p1}\nTarget: {p2}"
51 raise AssertionError(msg)
52
53
54#

Callers 9

test_addFunction · 0.85
test_subFunction · 0.85
test_mulFunction · 0.85
test_floordivFunction · 0.85
test_truedivFunction · 0.85
test_modFunction · 0.85
test_divmodFunction · 0.85
test_integFunction · 0.85
test_powFunction · 0.85

Calls 3

assert_Function · 0.90
assert_almost_equalFunction · 0.90
allMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…