Skip to content

Commit 55c8230

Browse files
add ndarray.take (#1032)
1 parent 1cbd81b commit 55c8230

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

dpnp/dpnp_array.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -735,6 +735,17 @@ def sum(self, axis=None, dtype=None, out=None, keepdims=False, initial=0, where=
735735

736736
# 'swapaxes',
737737
# 'take',
738+
739+
def take(self, indices, axis=None, out=None, mode='raise'):
740+
"""
741+
Take elements from an array.
742+
743+
For full documentation refer to :obj:`numpy.take`.
744+
745+
"""
746+
747+
return dpnp.take(self, indices, axis, out, mode)
748+
738749
# 'tobytes',
739750
# 'tofile',
740751
# 'tolist',

tests/skipped_tests_gpu.tbl

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -709,9 +709,6 @@ tests/third_party/cupy/indexing_tests/test_indexing.py::TestIndexing::test_diago
709709
tests/third_party/cupy/indexing_tests/test_indexing.py::TestIndexing::test_diagonal_negative3
710710
tests/third_party/cupy/indexing_tests/test_indexing.py::TestIndexing::test_diagonal_negative4
711711
tests/third_party/cupy/indexing_tests/test_indexing.py::TestIndexing::test_diagonal_negative5
712-
tests/third_party/cupy/indexing_tests/test_indexing.py::TestIndexing::test_take_by_array
713-
tests/third_party/cupy/indexing_tests/test_indexing.py::TestIndexing::test_take_by_scalar
714-
tests/third_party/cupy/indexing_tests/test_indexing.py::TestIndexing::test_take_no_axis
715712
tests/third_party/cupy/indexing_tests/test_insert.py::TestDiagIndicesFromRaises_param_4_{shape=(-1,)}::test_non_equal_dims
716713
tests/third_party/cupy/indexing_tests/test_insert.py::TestFillDiagonal_param_0_{shape=(3, 3), val=1, wrap=True}::test_columnar_slice
717714
tests/third_party/cupy/indexing_tests/test_insert.py::TestFillDiagonal_param_11_{shape=(2, 2, 2), val=0, wrap=False}::test_1darray

0 commit comments

Comments
 (0)