MCPcopy Create free account
hub / github.com/numpy/numpy / _check_ninf_inf

Method _check_ninf_inf

numpy/core/tests/test_umath_complex.py:72–77  ·  view source on GitHub ↗
(dummy)

Source from the content-addressed store, hash-verified

70
71 # cexp(-inf + inf i) is +-0 +- 0i (signs unspecified)
72 def _check_ninf_inf(dummy):
73 msgform = "cexp(-inf, inf) is (%f, %f), expected (+-0, +-0)"
74 with np.errstate(invalid='ignore'):
75 z = f(np.array(complex(-np.inf, np.inf)))
76 if z.real != 0 or z.imag != 0:
77 raise AssertionError(msgform % (z.real, z.imag))
78
79 _check_ninf_inf(None)
80

Callers

nothing calls this directly

Calls 1

fFunction · 0.85

Tested by

no test coverage detected