@@ -77,11 +77,11 @@ def lu(
7777 Perform the multiplication ``P @ L`` (Default: do not permute).
7878
7979 Default: ``False``.
80- overwrite_a : {None, bool} , optional
80+ overwrite_a : bool, optional
8181 Whether to overwrite data in `a` (may increase performance).
8282
8383 Default: ``False``.
84- check_finite : {None, bool} , optional
84+ check_finite : bool, optional
8585 Whether to check that the input matrix contains only finite numbers.
8686 Disabling may give a performance gain, but may result in problems
8787 (crashes, non-termination) if the inputs do contain infinities or NaNs.
@@ -95,23 +95,19 @@ def lu(
9595
9696 Returns
9797 -------
98- **(If ``permute_l`` is ``False``)**
98+ The tuple ``(p, l, u)`` is returned if ``permute_l`` is ``False``
99+ (default), else the tuple ``(pl, u)`` is returned, where:
99100
100101 p : (..., M, M) dpnp.ndarray or (..., M) dpnp.ndarray
101- If `p_indices` is ``False`` (default), the permutation matrix .
102- The permutation matrix always has a real dtype (``float32 `` or
103- ``float64``) even when `a` is complex, since it only contains
104- 0s and 1s.
102+ Permutation matrix or permutation indices .
103+ If `p_indices` is ``False `` (default), a permutation matrix.
104+ The permutation matrix always has a real-valued floating-point dtype
105+ even when `a` is complex, since it only contains 0s and 1s.
105106 If `p_indices` is ``True``, a 1-D (or batched) array of row
106107 permutation indices such that ``A = L[p] @ U``.
107108 l : (..., M, K) dpnp.ndarray
108109 Lower triangular or trapezoidal matrix with unit diagonal.
109110 ``K = min(M, N)``.
110- u : (..., K, N) dpnp.ndarray
111- Upper triangular or trapezoidal matrix.
112-
113- **(If ``permute_l`` is ``True``)**
114-
115111 pl : (..., M, K) dpnp.ndarray
116112 Permuted ``L`` matrix: ``pl = P @ L``.
117113 ``K = min(M, N)``.
@@ -130,18 +126,18 @@ def lu(
130126 permutation matrix is still needed then it can be constructed by
131127 ``dpnp.eye(M)[P, :]``.
132128
133- Warning
134- -------
129+ Warnings
130+ --------
135131 This function synchronizes in order to validate array elements
136132 when ``check_finite=True``, and also synchronizes to compute the
137133 permutation from LAPACK pivot indices.
138134
139135 See Also
140136 --------
141- :obj :`dpnp.scipy.linalg.lu_factor` : LU factorize a matrix
142- (compact representation).
143- :obj :`dpnp.scipy.linalg.lu_solve` : Solve an equation system using
144- the LU factorization of a matrix.
137+ :func :`dpnp.scipy.linalg.lu_factor` : LU factorize a matrix
138+ (compact representation).
139+ :func :`dpnp.scipy.linalg.lu_solve` : Solve an equation system using
140+ the LU factorization of a matrix.
145141
146142 Examples
147143 --------
@@ -211,11 +207,11 @@ def lu_factor(a, overwrite_a=False, check_finite=True):
211207 ----------
212208 a : (..., M, N) {dpnp.ndarray, usm_ndarray}
213209 Input array to decompose.
214- overwrite_a : {None, bool} , optional
210+ overwrite_a : bool, optional
215211 Whether to overwrite data in `a` (may increase performance).
216212
217213 Default: ``False``.
218- check_finite : {None, bool} , optional
214+ check_finite : bool, optional
219215 Whether to check that the input matrix contains only finite numbers.
220216 Disabling may give a performance gain, but may result in problems
221217 (crashes, non-termination) if the inputs do contain infinities or NaNs.
@@ -233,15 +229,15 @@ def lu_factor(a, overwrite_a=False, check_finite=True):
233229 row i of matrix was interchanged with row piv[i].
234230 Where ``K = min(M, N)``.
235231
236- Warning
237- -------
232+ Warnings
233+ --------
238234 This function synchronizes in order to validate array elements
239235 when ``check_finite=True``.
240236
241237 See Also
242238 --------
243- :obj :`dpnp.scipy.linalg.lu_solve` : Solve an equation system using
244- the LU factorization of `a` matrix.
239+ :func :`dpnp.scipy.linalg.lu_solve` : Solve an equation system using
240+ the LU factorization of `a` matrix.
245241
246242 Examples
247243 --------
@@ -273,7 +269,7 @@ def lu_solve(lu_and_piv, b, trans=0, overwrite_b=False, check_finite=True):
273269 lu, piv : {tuple of dpnp.ndarrays or usm_ndarrays}
274270 LU factorization of matrix `a` (..., M, M) together with pivot indices.
275271 b : {(M,), (..., M, K)} {dpnp.ndarray, usm_ndarray}
276- Right-hand side
272+ Right-hand side.
277273 trans : {0, 1, 2} , optional
278274 Type of system to solve:
279275
@@ -286,11 +282,11 @@ def lu_solve(lu_and_piv, b, trans=0, overwrite_b=False, check_finite=True):
286282 ===== =================
287283
288284 Default: ``0``.
289- overwrite_b : {None, bool} , optional
285+ overwrite_b : bool, optional
290286 Whether to overwrite data in `b` (may increase performance).
291287
292288 Default: ``False``.
293- check_finite : {None, bool} , optional
289+ check_finite : bool, optional
294290 Whether to check that the input matrix contains only finite numbers.
295291 Disabling may give a performance gain, but may result in problems
296292 (crashes, non-termination) if the inputs do contain infinities or NaNs.
@@ -302,14 +298,14 @@ def lu_solve(lu_and_piv, b, trans=0, overwrite_b=False, check_finite=True):
302298 x : {(M,), (..., M, K)} dpnp.ndarray
303299 Solution to the system
304300
305- Warning
306- -------
301+ Warnings
302+ --------
307303 This function synchronizes in order to validate array elements
308304 when ``check_finite=True``.
309305
310306 See Also
311307 --------
312- :obj :`dpnp.scipy.linalg.lu_factor` : LU factorize a matrix.
308+ :func :`dpnp.scipy.linalg.lu_factor` : LU factorize a matrix.
313309
314310 Examples
315311 --------
0 commit comments