示例#1
0
 def test_axis_1_with_nans(self, array):
     expected = np.array([1, 1, 1, 0], dtype=bool)
     result = any_nan(array(self.x_with_nans), axis=1)
     np.testing.assert_equal(result, expected)
示例#2
0
 def test_axis_none_with_nans(self, array):
     self.assertTrue(any_nan(array(self.x_with_nans)))
示例#3
0
 def test_axis_0_without_nans(self, array):
     expected = np.array([0, 0, 0, 0], dtype=bool)
     result = any_nan(array(self.x_no_nans), axis=0)
     np.testing.assert_equal(result, expected)
示例#4
0
 def test_axis_none_without_nans(self, array):
     self.assertFalse(any_nan(array(self.x_no_nans)))