(self)
| 1627 | |
| 1628 | class TestIndex: |
| 1629 | def test_boolean(self): |
| 1630 | a = rand(3, 5, 8) |
| 1631 | V = rand(5, 8) |
| 1632 | g1 = randint(0, 5, size=15) |
| 1633 | g2 = randint(0, 8, size=15) |
| 1634 | V[g1, g2] = -V[g1, g2] |
| 1635 | assert_((np.array([a[0][V > 0], a[1][V > 0], a[2][V > 0]]) == a[:, V > 0]).all()) |
| 1636 | |
| 1637 | def test_boolean_edgecase(self): |
| 1638 | a = np.array([], dtype='int32') |