Skip to content

Commit 4a49821

Browse files
committed
update docstring for floor, ceil, trunc
1 parent b09fd05 commit 4a49821

File tree

1 file changed

+22
-3
lines changed

1 file changed

+22
-3
lines changed

dpnp/dpnp_iface_mathematical.py

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@
9191
"clip",
9292
"conj",
9393
"conjugate",
94+
"convolve",
9495
"copysign",
9596
"cross",
9697
"cumprod",
@@ -611,7 +612,7 @@ def around(x, /, decimals=0, out=None):
611612
Parameters
612613
----------
613614
x : {dpnp.ndarray, usm_ndarray}
614-
Input array, expected to have a real-valued data type.
615+
Input array, expected to have a boolean or real-valued data type.
615616
out : {None, dpnp.ndarray, usm_ndarray}, optional
616617
Output array to populate.
617618
Array must have the correct shape and the expected data type.
@@ -791,6 +792,24 @@ def clip(a, /, min=None, max=None, *, out=None, order="K", **kwargs):
791792

792793
conj = conjugate
793794

795+
796+
def convolve(a, v, mode="full"):
797+
"""
798+
Returns the discrete, linear convolution of two one-dimensional sequences.
799+
800+
For full documentation refer to :obj:`numpy.convolve`.
801+
802+
Examples
803+
--------
804+
>>> ca = dpnp.convolve([1, 2, 3], [0, 1, 0.5])
805+
>>> print(ca)
806+
[0. , 1. , 2.5, 4. , 1.5]
807+
808+
"""
809+
810+
return call_origin(numpy.convolve, a=a, v=v, mode=mode)
811+
812+
794813
_COPYSIGN_DOCSTRING = """
795814
Composes a floating-point value with the magnitude of `x1_i` and the sign of
796815
`x2_i` for each element of input arrays `x1` and `x2`.
@@ -1878,7 +1897,7 @@ def ediff1d(ary, to_end=None, to_begin=None):
18781897
Parameters
18791898
----------
18801899
x : {dpnp.ndarray, usm_ndarray}
1881-
Input array, expected to have a real-valued data type.
1900+
Input array, expected to have a boolean or real-valued data type.
18821901
out : {None, dpnp.ndarray, usm_ndarray}, optional
18831902
Output array to populate.
18841903
Array must have the correct shape and the expected data type.
@@ -4551,7 +4570,7 @@ def trapezoid(y, x=None, dx=1.0, axis=-1):
45514570
Parameters
45524571
----------
45534572
x : {dpnp.ndarray, usm_ndarray}
4554-
Input array, expected to have a real-valued data type.
4573+
Input array, expected to have a boolean or real-valued data type.
45554574
out : {None, dpnp.ndarray, usm_ndarray}, optional
45564575
Output array to populate.
45574576
Array must have the correct shape and the expected data type.

0 commit comments

Comments
 (0)