MCPcopy
hub / github.com/numpy/numpy / check_complex_value

Function check_complex_value

numpy/_core/tests/test_umath_complex.py:552–559  ·  view source on GitHub ↗
(f, x1, y1, x2, y2, exact=True)

Source from the content-addressed store, hash-verified

550
551
552def check_complex_value(f, x1, y1, x2, y2, exact=True):
553 z1 = np.array([complex(x1, y1)])
554 z2 = complex(x2, y2)
555 with np.errstate(invalid='ignore'):
556 if exact:
557 assert_equal(f(z1), z2)
558 else:
559 assert_almost_equal(f(z1), z2)
560
561class TestSpecialComplexAVX:
562 @pytest.mark.parametrize("stride", [-4, -2, -1, 1, 2, 4])

Callers 2

test_simpleMethod · 0.85
test_simple_conjugateMethod · 0.85

Calls 3

assert_equalFunction · 0.90
assert_almost_equalFunction · 0.90
fFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…