Skip to content

Commit ae17868

Browse files
committed
Rephrase a case when an input array may have any dtype
1 parent bb711a1 commit ae17868

File tree

3 files changed

+43
-43
lines changed

3 files changed

+43
-43
lines changed

dpnp/dpnp_iface_logic.py

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -195,9 +195,9 @@ def allclose(a, b, rtol=1.0e-5, atol=1.0e-8, equal_nan=False):
195195
Parameters
196196
----------
197197
a : {dpnp.ndarray, usm_ndarray, scalar}
198-
First input array, expected to have numeric data type.
198+
First input array, expected to have a numeric data type.
199199
b : {dpnp.ndarray, usm_ndarray, scalar}
200-
Second input array, also expected to have numeric data type.
200+
Second input array, also expected to have a numeric data type.
201201
rtol : {dpnp.ndarray, usm_ndarray, scalar}, optional
202202
The relative tolerance parameter.
203203
@@ -552,9 +552,9 @@ def array_equiv(a1, a2):
552552
Parameters
553553
----------
554554
x1 : {dpnp.ndarray, usm_ndarray, scalar}
555-
First input array, expected to have a boolean or numeric data type.
555+
First input array, may have any data type.
556556
x2 : {dpnp.ndarray, usm_ndarray, scalar}
557-
Second input array, also expected to have a boolean or numeric data type.
557+
Second input array, also may have any data type.
558558
out : {None, dpnp.ndarray, usm_ndarray}, optional
559559
Output array to populate.
560560
Array have the correct shape and the expected data type.
@@ -632,9 +632,9 @@ def array_equiv(a1, a2):
632632
Parameters
633633
----------
634634
x1 : {dpnp.ndarray, usm_ndarray, scalar}
635-
First input array, expected to have a boolean or numeric data type.
635+
First input array, may have any data type.
636636
x2 : {dpnp.ndarray, usm_ndarray, scalar}
637-
Second input array, also expected to have a boolean or numeric data type.
637+
Second input array, also may have any data type.
638638
out : {None, dpnp.ndarray, usm_ndarray}, optional
639639
Output array to populate.
640640
Array must have the correct shape and the expected data type.
@@ -706,9 +706,9 @@ def array_equiv(a1, a2):
706706
Parameters
707707
----------
708708
x1 : {dpnp.ndarray, usm_ndarray, scalar}
709-
First input array, expected to have a boolean or numeric data type.
709+
First input array, may have any data type.
710710
x2 : {dpnp.ndarray, usm_ndarray, scalar}
711-
Second input array, also expected to have a boolean or numeric data type.
711+
Second input array, also may have any data type.
712712
out : {None, dpnp.ndarray, usm_ndarray}, optional
713713
Output array to populate.
714714
Array must have the correct shape and the expected data type.
@@ -790,9 +790,9 @@ def isclose(a, b, rtol=1e-05, atol=1e-08, equal_nan=False):
790790
Parameters
791791
----------
792792
a : {dpnp.ndarray, usm_ndarray, scalar}
793-
First input array, expected to have numeric data type.
793+
First input array, expected to have a numeric data type.
794794
b : {dpnp.ndarray, usm_ndarray, scalar}
795-
Second input array, also expected to have numeric data type.
795+
Second input array, also expected to have a numeric data type.
796796
rtol : {dpnp.ndarray, usm_ndarray, scalar}, optional
797797
The relative tolerance parameter.
798798
@@ -992,7 +992,7 @@ def iscomplexobj(x):
992992
Parameters
993993
----------
994994
x : {dpnp.ndarray, usm_ndarray}
995-
Input array, expected to have a boolean or numeric data type.
995+
Input array, may have any data type.
996996
out : {None, dpnp.ndarray, usm_ndarray}, optional
997997
Output array to populate.
998998
Array must have the correct shape and the expected data type.
@@ -1124,7 +1124,7 @@ def isfortran(a):
11241124
Parameters
11251125
----------
11261126
x : {dpnp.ndarray, usm_ndarray}
1127-
Input array, expected to have a boolean or numeric data type.
1127+
Input array, may have any data type.
11281128
out : {None, dpnp.ndarray, usm_ndarray}, optional
11291129
Output array to populate.
11301130
Array must have the correct shape and the expected data type.
@@ -1182,7 +1182,7 @@ def isfortran(a):
11821182
Parameters
11831183
----------
11841184
x : {dpnp.ndarray, usm_ndarray}
1185-
Input array, expected to have a boolean or numeric data type.
1185+
Input array, may have any data type.
11861186
out : {None, dpnp.ndarray, usm_ndarray}, optional
11871187
Output array to populate.
11881188
Array must have the correct shape and the expected data type.
@@ -1517,9 +1517,9 @@ def isscalar(element):
15171517
Parameters
15181518
----------
15191519
x1 : {dpnp.ndarray, usm_ndarray, scalar}
1520-
First input array, expected to have a boolean or numeric data type.
1520+
First input array, may have any data type.
15211521
x2 : {dpnp.ndarray, usm_ndarray, scalar}
1522-
Second input array, also expected to have a boolean or numeric data type.
1522+
Second input array, also may have any data type.
15231523
out : {None, dpnp.ndarray, usm_ndarray}, optional
15241524
Output array to populate.
15251525
Array must have the correct shape and the expected data type.
@@ -1591,9 +1591,9 @@ def isscalar(element):
15911591
Parameters
15921592
----------
15931593
x1 : {dpnp.ndarray, usm_ndarray, scalar}
1594-
First input array, expected to have a boolean or numeric data type.
1594+
First input array, may have any data type.
15951595
x2 : {dpnp.ndarray, usm_ndarray, scalar}
1596-
Second input array, also expected to have a boolean or numeric data type.
1596+
Second input array, also may have any data type.
15971597
out : {None, dpnp.ndarray, usm_ndarray}, optional
15981598
Output array to populate.
15991599
Array must have the correct shape and the expected data type.
@@ -1664,9 +1664,9 @@ def isscalar(element):
16641664
Parameters
16651665
----------
16661666
x1 : {dpnp.ndarray, usm_ndarray, scalar}
1667-
First input array, expected to have a boolean or numeric data type.
1667+
First input array, may have any data type.
16681668
x2 : {dpnp.ndarray, usm_ndarray, scalar}
1669-
Second input array, also expected to have a boolean or numeric data type.
1669+
Second input array, also may have any data type.
16701670
out : {None, dpnp.ndarray, usm_ndarray}, optional
16711671
Output array to populate.
16721672
Array must have the correct shape and the expected data type.
@@ -1739,7 +1739,7 @@ def isscalar(element):
17391739
Parameters
17401740
----------
17411741
x : {dpnp.ndarray, usm_ndarray}
1742-
Input array, expected to have a boolean or numeric data type.
1742+
Input array, may have any data type.
17431743
out : {None, dpnp.ndarray, usm_ndarray}, optional
17441744
Output array to populate.
17451745
Array must have the correct shape and the expected data type.
@@ -1803,9 +1803,9 @@ def isscalar(element):
18031803
Parameters
18041804
----------
18051805
x1 : {dpnp.ndarray, usm_ndarray, scalar}
1806-
First input array, expected to have a boolean or numeric data type.
1806+
First input array, may have any data type.
18071807
x2 : {dpnp.ndarray, usm_ndarray, scalar}
1808-
Second input array, also expected to have a boolean or numeric data type.
1808+
Second input array, also may have any data type.
18091809
out : {None, dpnp.ndarray, usm_ndarray}, optional
18101810
Output array to populate.
18111811
Array must have the correct shape and the expected data type.
@@ -1879,9 +1879,9 @@ def isscalar(element):
18791879
Parameters
18801880
----------
18811881
x1 : {dpnp.ndarray, usm_ndarray, scalar}
1882-
First input array, expected to have a boolean or numeric data type.
1882+
First input array, may have any data type.
18831883
x2 : {dpnp.ndarray, usm_ndarray, scalar}
1884-
Second input array, also expected to have a boolean or numeric data type.
1884+
Second input array, also may have any data type.
18851885
out : {None, dpnp.ndarray, usm_ndarray}, optional
18861886
Output array to populate.
18871887
Array must have the correct shape and the expected data type.
@@ -1953,9 +1953,9 @@ def isscalar(element):
19531953
Parameters
19541954
----------
19551955
x1 : {dpnp.ndarray, usm_ndarray, scalar}
1956-
First input array, expected to have a boolean or numeric data type.
1956+
First input array, may have any data type.
19571957
x2 : {dpnp.ndarray, usm_ndarray, scalar}
1958-
Second input array, also expected to have a boolean or numeric data type.
1958+
Second input array, also may have any data type.
19591959
out : {None, dpnp.ndarray, usm_ndarray}, optional
19601960
Output array to populate.
19611961
Array must have the correct shape and the expected data type.

dpnp/dpnp_iface_mathematical.py

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,7 @@ def _process_ediff1d_args(arg, arg_name, ary_dtype, ary_sycl_queue, usm_type):
356356
Parameters
357357
----------
358358
x : {dpnp.ndarray, usm_ndarray}
359-
Input array, expected to have a boolean or numeric data type.
359+
Input array, may have any data type.
360360
out : {None, dpnp.ndarray, usm_ndarray}, optional
361361
Output array to populate.
362362
Array must have the correct shape and the expected data type.
@@ -426,9 +426,9 @@ def _process_ediff1d_args(arg, arg_name, ary_dtype, ary_sycl_queue, usm_type):
426426
Parameters
427427
----------
428428
x1 : {dpnp.ndarray, usm_ndarray, scalar}
429-
First input array, expected to have a boolean or numeric data type.
429+
First input array, may have any data type.
430430
x2 : {dpnp.ndarray, usm_ndarray, scalar}
431-
Second input array, also expected to have a boolean or numeric data type.
431+
Second input array, also may have any data type.
432432
out : {None, dpnp.ndarray, usm_ndarray}, optional
433433
Output array to populate.
434434
Array must have the correct shape and the expected data type.
@@ -573,7 +573,7 @@ def around(x, /, decimals=0, out=None):
573573
Parameters
574574
----------
575575
x : {dpnp.ndarray, usm_ndarray}
576-
Input array, expected to have numeric data type.
576+
Input array, expected to have a numeric data type.
577577
decimals : int, optional
578578
Number of decimal places to round to. If `decimals` is negative, it
579579
specifies the number of positions to the left of the decimal point.
@@ -758,7 +758,7 @@ def clip(a, /, min=None, max=None, *, out=None, order="K", **kwargs):
758758
Parameters
759759
----------
760760
x : {dpnp.ndarray, usm_ndarray}
761-
Input array, expected to have a boolean or numeric data type.
761+
Input array, may have any data type.
762762
out : {None, dpnp.ndarray, usm_ndarray}, optional
763763
Output array to populate.
764764
Array must have the correct shape and the expected data type.
@@ -2050,9 +2050,9 @@ def ediff1d(ary, to_end=None, to_begin=None):
20502050
Parameters
20512051
----------
20522052
x1 : {dpnp.ndarray, usm_ndarray, scalar}
2053-
First input array, expected to have a boolean or numeric data type.
2053+
First input array, may have any data type.
20542054
x2 : {dpnp.ndarray, usm_ndarray, scalar}
2055-
Second input array, also expected to have a boolean or numeric data type.
2055+
Second input array, also may have any data type.
20562056
out : {None, dpnp.ndarray, usm_ndarray}, optional
20572057
Output array to populate.
20582058
Array must have the correct shape and the expected data type.
@@ -2141,9 +2141,9 @@ def ediff1d(ary, to_end=None, to_begin=None):
21412141
Parameters
21422142
----------
21432143
x1 : {dpnp.ndarray, usm_ndarray, scalar}
2144-
First input array, expected to have a boolean or numeric data type.
2144+
First input array, may have any data type.
21452145
x2 : {dpnp.ndarray, usm_ndarray, scalar}
2146-
Second input array, also expected to have a boolean or numeric data type.
2146+
Second input array, also may have any data type.
21472147
out : {None, dpnp.ndarray, usm_ndarray}, optional
21482148
Output array to populate.
21492149
Array must have the correct shape and the expected data type.
@@ -2688,7 +2688,7 @@ def gradient(f, *varargs, axis=None, edge_order=1):
26882688
Parameters
26892689
----------
26902690
x : {dpnp.ndarray, usm_ndarray}
2691-
Input array, expected to have a boolean or numeric data type.
2691+
Input array, may have any data type.
26922692
out : {None, dpnp.ndarray, usm_ndarray}, optional
26932693
Output array to populate.
26942694
Array must have the correct shape and the expected data type.
@@ -2888,9 +2888,9 @@ def gradient(f, *varargs, axis=None, edge_order=1):
28882888
Parameters
28892889
----------
28902890
x1 : {dpnp.ndarray, usm_ndarray, scalar}
2891-
First input array, expected to have a boolean or numeric data type.
2891+
First input array, may have any data type.
28922892
x2 : {dpnp.ndarray, usm_ndarray, scalar}
2893-
Second input array, also expected to have a boolean or numeric data type.
2893+
Second input array, also may have any data type.
28942894
out : {None, dpnp.ndarray, usm_ndarray}, optional
28952895
Output array to populate.
28962896
Array must have the correct shape and the expected data type.
@@ -2977,9 +2977,9 @@ def gradient(f, *varargs, axis=None, edge_order=1):
29772977
Parameters
29782978
----------
29792979
x1 : {dpnp.ndarray, usm_ndarray, scalar}
2980-
First input array, expected to have a boolean or numeric data type.
2980+
First input array, may have any data type.
29812981
x2 : {dpnp.ndarray, usm_ndarray, scalar}
2982-
Second input array, also expected to have a boolean or numeric data type.
2982+
Second input array, also may have any data type.
29832983
out : {None, dpnp.ndarray, usm_ndarray}, optional
29842984
Output array to populate.
29852985
Array must have the correct shape and the expected data type.
@@ -3097,9 +3097,9 @@ def modf(x1, **kwargs):
30973097
Parameters
30983098
----------
30993099
x1 : {dpnp.ndarray, usm_ndarray, scalar}
3100-
First input array, expected to have a boolean or numeric data type.
3100+
First input array, may have any data type.
31013101
x2 : {dpnp.ndarray, usm_ndarray, scalar}
3102-
Second input array, also expected to have a boolean or numeric data type.
3102+
Second input array, also may have any data type.
31033103
out : {None, dpnp.ndarray, usm_ndarray}, optional
31043104
Output array to populate.
31053105
Array must have the correct shape and the expected data type.

dpnp/dpnp_iface_trigonometric.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2447,7 +2447,7 @@ def reduce_hypot(x, /, *, axis=None, dtype=None, keepdims=False, out=None):
24472447
Parameters
24482448
----------
24492449
x : {dpnp.ndarray, usm_ndarray}
2450-
Input array, expected to have a boolean or numeric data type.
2450+
Input array, may have any data type.
24512451
out : {None, dpnp.ndarray, usm_ndarray}, optional
24522452
Output array to populate.
24532453
Array must have the correct shape and the expected data type.

0 commit comments

Comments
 (0)