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

Method testaxis

numpy/ma/tests/test_core.py:5239–5246  ·  view source on GitHub ↗
(f, a, d)

Source from the content-addressed store, hash-verified

5237 a = np.ma.array(d, mask=m)
5238
5239 def testaxis(f, a, d):
5240 numpy_f = numpy.__getattribute__(f)
5241 ma_f = np.ma.__getattribute__(f)
5242
5243 # test axis arg
5244 assert_equal(ma_f(a, axis=1)[...,:-1], numpy_f(d[...,:-1], axis=1))
5245 assert_equal(ma_f(a, axis=(0,1))[...,:-1],
5246 numpy_f(d[...,:-1], axis=(0,1)))
5247
5248 def testkeepdims(f, a, d):
5249 numpy_f = numpy.__getattribute__(f)

Callers

nothing calls this directly

Calls 2

assert_equalFunction · 0.90
__getattribute__Method · 0.45

Tested by

no test coverage detected