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

Method test_take_output

numpy/core/tests/test_regression.py:731–737  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

729 assert_(asbytes(r['var1'][0][0]) == b'abc')
730
731 def test_take_output(self):
732 # Ensure that 'take' honours output parameter.
733 x = np.arange(12).reshape((3, 4))
734 a = np.take(x, [0, 2], axis=1)
735 b = np.zeros_like(a)
736 np.take(x, [0, 2], axis=1, out=b)
737 assert_array_equal(a, b)
738
739 def test_take_object_fail(self):
740 # Issue gh-3001

Callers

nothing calls this directly

Calls 3

assert_array_equalFunction · 0.90
reshapeMethod · 0.80
takeMethod · 0.80

Tested by

no test coverage detected