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

Method test_fix_invalid

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

Source from the content-addressed store, hash-verified

299 assert_(new_m.flags.c_contiguous)
300
301 def test_fix_invalid(self):
302 # Checks fix_invalid.
303 with np.errstate(invalid='ignore'):
304 data = masked_array([np.nan, 0., 1.], mask=[0, 0, 1])
305 data_fixed = fix_invalid(data)
306 assert_equal(data_fixed._data, [data.fill_value, 0., 1.])
307 assert_equal(data_fixed._mask, [1., 0., 1.])
308
309 def test_maskedelement(self):
310 # Test of masked element

Callers

nothing calls this directly

Calls 2

fix_invalidFunction · 0.90
assert_equalFunction · 0.90

Tested by

no test coverage detected