MCPcopy Index your code
hub / github.com/numpy/numpy / test_where_broadcast

Method test_where_broadcast

numpy/ma/tests/test_core.py:4810–4818  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

4808 assert_equal(test, control)
4809
4810 def test_where_broadcast(self):
4811 # Issue 8599
4812 x = np.arange(9).reshape(3, 3)
4813 y = np.zeros(3)
4814 core = np.where([1, 0, 1], x, y)
4815 ma = where([1, 0, 1], x, y)
4816
4817 assert_equal(core, ma)
4818 assert_equal(core.dtype, ma.dtype)
4819
4820 def test_where_structured(self):
4821 # Issue 8600

Callers

nothing calls this directly

Calls 3

whereFunction · 0.90
assert_equalFunction · 0.90
reshapeMethod · 0.80

Tested by

no test coverage detected