Skip to content

Commit 5f34212

Browse files
committed
Apply review comments
1 parent ae17868 commit 5f34212

4 files changed

Lines changed: 29 additions & 29 deletions

File tree

dpnp/dpnp_iface_linearalgebra.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -617,7 +617,7 @@ def inner(a, b):
617617
618618
See Also
619619
--------
620-
:obj:`dpnp.einsum` : Einstein summation convention..
620+
:obj:`dpnp.einsum` : Einstein summation convention.
621621
:obj:`dpnp.dot` : Generalized matrix product,
622622
using second last dimension of `b`.
623623
:obj:`dpnp.tensordot` : Sum products over arbitrary axes.
@@ -998,7 +998,7 @@ def matvec(
998998
999999
See Also
10001000
--------
1001-
:obj:`dpnp.vecdot` : Vector-vector product..
1001+
:obj:`dpnp.vecdot` : Vector-vector product.
10021002
:obj:`dpnp.vecmat` : Vector-matrix product.
10031003
:obj:`dpnp.matmul` : Matrix-matrix product.
10041004
:obj:`dpnp.einsum` : Einstein summation convention.
@@ -1502,7 +1502,7 @@ def vecmat(
15021502
15031503
See Also
15041504
--------
1505-
:obj:`dpnp.vecdot` : Vector-vector product..
1505+
:obj:`dpnp.vecdot` : Vector-vector product.
15061506
:obj:`dpnp.matvec` : Matrix-vector product.
15071507
:obj:`dpnp.matmul` : Matrix-matrix product.
15081508
:obj:`dpnp.einsum` : Einstein summation convention.

dpnp/dpnp_iface_logic.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -985,7 +985,7 @@ def iscomplexobj(x):
985985

986986

987987
_ISFINITE_DOCSTRING = """
988-
Test each element :math:`x_i` of input array `x` if finite.
988+
Test each element :math:`x_i` of the input array `x` to determine if finite.
989989
990990
For full documentation refer to :obj:`numpy.isfinite`.
991991

dpnp/dpnp_iface_mathematical.py

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -351,7 +351,7 @@ def _process_ediff1d_args(arg, arg_name, ary_dtype, ary_sycl_queue, usm_type):
351351
_ABS_DOCSTRING = """
352352
Calculates the absolute value for each element :math:`x_i` of input array `x`.
353353
354-
For full documentation refer to :obj:`numpy.abs`.
354+
For full documentation refer to :obj:`numpy.absolute`.
355355
356356
Parameters
357357
----------
@@ -372,8 +372,8 @@ def _process_ediff1d_args(arg, arg_name, ary_dtype, ary_sycl_queue, usm_type):
372372
out : dpnp.ndarray
373373
An array containing the element-wise absolute values.
374374
For complex input, the absolute value is its magnitude.
375-
If `x` has a real-valued floating-point data type, the returned array has
376-
the same data type as `x`. If `x` has a complex floating-point data type,
375+
If `x` has a real-valued data type, the returned array has the
376+
same data type as `x`. If `x` has a complex floating-point data type,
377377
the returned array has a real-valued floating-point data type whose
378378
precision matches the precision of `x`.
379379
@@ -389,7 +389,7 @@ def _process_ediff1d_args(arg, arg_name, ary_dtype, ary_sycl_queue, usm_type):
389389
390390
Notes
391391
-----
392-
``dpnp.absolute`` is a shorthand for this function.
392+
``dpnp.absolute`` is an equivalent function.
393393
394394
Examples
395395
--------
@@ -497,7 +497,7 @@ def _process_ediff1d_args(arg, arg_name, ary_dtype, ary_sycl_queue, usm_type):
497497
)
498498

499499

500-
_ANGLE_DOCSTRING = """
500+
_ANGLE_DOCSTRING = r"""
501501
Computes the phase angle (also called the argument) of each element :math:`x_i`
502502
for input array `x`.
503503
@@ -530,13 +530,13 @@ def _process_ediff1d_args(arg, arg_name, ary_dtype, ary_sycl_queue, usm_type):
530530
531531
Notes
532532
-----
533-
Although the angle of the complex number 0 is undefined, `dpnp.angle(0)` returns
534-
the value ``0``.
533+
Although the angle of the complex number ``0`` is undefined, ``dpnp.angle(0)``
534+
returns the value ``0``.
535535
536536
See Also
537537
--------
538-
:obj:`dpnp.atan2` : Element-wise arc tangent of `x1/x2` choosing the quadrant
539-
correctly.
538+
:obj:`dpnp.atan2` : Element-wise arc tangent of :math:`\frac{x1}/{x2}` choosing
539+
the quadrant correctly.
540540
:obj:`dpnp.atan` : Trigonometric inverse tangent, element-wise.
541541
:obj:`dpnp.abs` : Calculate the absolute value element-wise.
542542
:obj:`dpnp.real` : Return the real part of the complex argument.
@@ -2703,7 +2703,7 @@ def gradient(f, *varargs, axis=None, edge_order=1):
27032703
-------
27042704
out : dpnp.ndarray
27052705
An array containing the element-wise imaginary component of input.
2706-
If the input is a real-valued floating-point data type, the returned array has
2706+
If the input is a real-valued data type, the returned array has
27072707
the same data type. If the input is a complex floating-point
27082708
data type, the returned array has a floating-point data type
27092709
with the same floating-point precision as complex input.
@@ -3764,7 +3764,7 @@ def prod(
37643764
Parameters
37653765
----------
37663766
x : {dpnp.ndarray, usm_ndarray}
3767-
Input array, expected to have a numeric data type.
3767+
Input array, may have any data type.
37683768
out : {None, dpnp.ndarray, usm_ndarray}, optional
37693769
Output array to populate.
37703770
Array must have the correct shape and the expected data type.
@@ -3779,7 +3779,7 @@ def prod(
37793779
-------
37803780
out : dpnp.ndarray
37813781
An array containing the element-wise real component of input.
3782-
If the input is a real-valued floating-point data type, the returned array has
3782+
If the input is a real-valued data type, the returned array has
37833783
the same data type. If the input is a complex floating-point
37843784
data type, the returned array has a floating-point data type
37853785
with the same floating-point precision as complex input.
@@ -4105,7 +4105,7 @@ def real_if_close(a, tol=100):
41054105
\frac{x_i}{|x_i|} & \textrm{otherwise}
41064106
\end{cases}
41074107
4108-
where :math:`|x_i|` is the absolute value of :math:`x_i`.
4108+
where :math:`|x_i|` is the absolute value of :math:`x_i`.
41094109
41104110
For full documentation refer to :obj:`numpy.sign`.
41114111
@@ -4166,8 +4166,8 @@ def real_if_close(a, tol=100):
41664166
input array `x`.
41674167
41684168
The sign bit of a real-valued floating-point number :math:`x_i` is set whenever
4169-
:math:`x_i` is either ``-0``, less than zero, or a signed ``NaN`` (i.e., a NaN
4170-
value whose sign bit is ``1``).
4169+
:math:`x_i` is either ``-0``, less than zero, or a signed ``NaN``
4170+
(i.e., a ``NaN`` value whose sign bit is ``1``).
41714171
41724172
For full documentation refer to :obj:`numpy.signbit`.
41734173

dpnp/dpnp_iface_trigonometric.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -315,7 +315,7 @@ def _get_accumulation_res_dt(a, dtype):
315315
:obj:`dpnp.acos` : Trigonometric inverse cosine, element-wise.
316316
:obj:`dpnp.tan` : Trigonometric tangent, element-wise.
317317
:obj:`dpnp.atan` : Trigonometric inverse tangent, element-wise.
318-
:obj:`dpnp.atan2` : Element-wise arc tangent of `x1/x2`
318+
:obj:`dpnp.atan2` : Element-wise arc tangent of :math:`\frac{x1}/{x2}`
319319
choosing the quadrant correctly.
320320
:obj:`dpnp.asinh` : Hyperbolic inverse sine, element-wise.
321321
@@ -477,7 +477,7 @@ def _get_accumulation_res_dt(a, dtype):
477477
478478
See Also
479479
--------
480-
:obj:`dpnp.atan2` : Element-wise arc tangent of `x1/x2`
480+
:obj:`dpnp.atan2` : Element-wise arc tangent of :math:`\frac{x1}/{x2}`
481481
choosing the quadrant correctly.
482482
:obj:`dpnp.angle` : Argument of complex values.
483483
:obj:`dpnp.tan` : Trigonometric tangent, element-wise.
@@ -554,9 +554,9 @@ def _get_accumulation_res_dt(a, dtype):
554554
Returns
555555
-------
556556
out : dpnp.ndarray
557-
An array containing the inverse tangent of the quotient :math:`x1/x2`, in
558-
radians. The returned array must have a real-valued floating-point data
559-
type determined by Type Promotion Rules.
557+
An array containing the inverse tangent of the quotient
558+
:math:`\frac{x1}/{x2}`, in radians. The returned array must have a
559+
real-valued floating-point data type determined by Type Promotion Rules.
560560
561561
Limitations
562562
-----------
@@ -1027,7 +1027,7 @@ def cumlogsumexp(
10271027

10281028

10291029
_DEGREES_DOCSTRING = r"""
1030-
Convert angles from degrees to radians for each element :math:`x_i` for input
1030+
Convert angles from radian to degrees for each element :math:`x_i` for input
10311031
array `x`.
10321032
10331033
For full documentation refer to :obj:`numpy.degrees`.
@@ -1210,8 +1210,8 @@ def cumlogsumexp(
12101210

12111211

12121212
_EXPM1_DOCSTRING = r"""
1213-
Computes the exponential minus 1 for each element :math:`x_i` of input array
1214-
`x`.
1213+
Computes the exponential minus ``1`` for each element :math:`x_i` of input
1214+
array `x`.
12151215
12161216
For full documentation refer to :obj:`numpy.expm1`.
12171217
@@ -1918,7 +1918,7 @@ def logsumexp(x, /, *, axis=None, dtype=None, keepdims=False, out=None):
19181918

19191919

19201920
_RAD2DEG_DOCSTRING = r"""
1921-
Convert angles from degrees to radians for each element :math:`x_i` for input
1921+
Convert angles from radians to degrees for each element :math:`x_i` for input
19221922
array `x`.
19231923
19241924
For full documentation refer to :obj:`numpy.rad2deg`.
@@ -2472,7 +2472,7 @@ def reduce_hypot(x, /, *, axis=None, dtype=None, keepdims=False, out=None):
24722472
24732473
See Also
24742474
--------
2475-
:obj:`dpnp..linalg.matrix_power` : Raise a square matrix to the (integer)
2475+
:obj:`dpnp.linalg.matrix_power` : Raise a square matrix to the (integer)
24762476
power `n`.
24772477
:obj:`dpnp.sqrt` : Calculate :math:`\sqrt{x}`, element-wise.
24782478
:obj:`dpnp.power` : Calculate :math:`{x1}^{x2}`, element-wise.

0 commit comments

Comments
 (0)