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

Method test_ufunc

numpy/lib/tests/test_function_base.py:1398–1403  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1396 assert_array_equal(y, x)
1397
1398 def test_ufunc(self):
1399 f = vectorize(math.cos)
1400 args = np.array([0, 0.5 * np.pi, np.pi, 1.5 * np.pi, 2 * np.pi])
1401 r1 = f(args)
1402 r2 = np.cos(args)
1403 assert_array_almost_equal(r1, r2)
1404
1405 def test_keywords(self):
1406

Callers

nothing calls this directly

Calls 3

vectorizeClass · 0.90
fFunction · 0.85

Tested by

no test coverage detected