Skip to content

Commit 23e0671

Browse files
cumsum array method (#1030)
1 parent 5ed6898 commit 23e0671

File tree

2 files changed

+13
-4
lines changed

2 files changed

+13
-4
lines changed

dpnp/dpnp_array.py

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -414,7 +414,19 @@ def conjugate(self):
414414
# 'copy',
415415
# 'ctypes',
416416
# 'cumprod',
417-
# 'cumsum',
417+
418+
def cumsum(self, axis=None, dtype=None, out=None):
419+
"""
420+
Return the cumulative sum of the elements along the given axis.
421+
422+
See Also
423+
--------
424+
:obj:`dpnp.cumsum`
425+
426+
"""
427+
428+
return dpnp.cumsum(self, axis=axis, dtype=dtype, out=out)
429+
418430
# 'data',
419431

420432
def diagonal(input, offset=0, axis1=0, axis2=1):

tests/skipped_tests_gpu.tbl

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1091,9 +1091,6 @@ tests/third_party/cupy/math_tests/test_sumprod.py::TestCumprod::test_ndarray_cum
10911091
tests/third_party/cupy/math_tests/test_sumprod.py::TestDiff::test_diff_1dim
10921092
tests/third_party/cupy/math_tests/test_sumprod.py::TestDiff::test_diff_1dim_with_n
10931093
tests/third_party/cupy/math_tests/test_sumprod.py::TestDiff::test_diff_2dim_without_axis
1094-
tests/third_party/cupy/math_tests/test_sumprod.py::TestCumsum_param_0_{axis=0}::test_ndarray_cumsum_axis
1095-
tests/third_party/cupy/math_tests/test_sumprod.py::TestCumsum_param_1_{axis=1}::test_ndarray_cumsum_axis
1096-
tests/third_party/cupy/math_tests/test_sumprod.py::TestCumsum_param_2_{axis=2}::test_ndarray_cumsum_axis
10971094
tests/third_party/cupy/math_tests/test_sumprod.py::TestCumprod::test_cumprod_arraylike
10981095
tests/third_party/cupy/math_tests/test_sumprod.py::TestCumprod::test_cumprod_huge_array
10991096
tests/third_party/cupy/math_tests/test_sumprod.py::TestCumprod::test_cumprod_numpy_array

0 commit comments

Comments
 (0)