Skip to content

Commit b9a9f42

Browse files
antonwolfyclaude
andcommitted
Standardize docstring section header to 'Warnings'
Change 'Warning' to 'Warnings' (plural) in docstring section headers across multiple modules to follow NumPy/SciPy documentation style guide. Files modified: - dpnp/scipy/linalg/_decomp_lu.py (3 functions) - dpnp/dpnp_iface_histograms.py (5 functions) - dpnp/dpnp_iface_manipulation.py (2 functions) - dpnp/dpnp_iface_nanfunctions.py (4 functions) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
1 parent 3fd720d commit b9a9f42

File tree

4 files changed

+28
-28
lines changed

4 files changed

+28
-28
lines changed

dpnp/dpnp_iface_histograms.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -306,8 +306,8 @@ def bincount(x, weights=None, minlength=0):
306306
307307
For full documentation refer to :obj:`numpy.bincount`.
308308
309-
Warning
310-
-------
309+
Warnings
310+
--------
311311
This function synchronizes in order to calculate binning edges.
312312
This may harm performance in some applications.
313313
@@ -504,8 +504,8 @@ def histogram(a, bins=10, range=None, density=None, weights=None):
504504
505505
For full documentation refer to :obj:`numpy.histogram`.
506506
507-
Warning
508-
-------
507+
Warnings
508+
--------
509509
This function may synchronize in order to check a monotonically increasing
510510
array of bin edges. This may harm performance in some applications.
511511
@@ -675,8 +675,8 @@ def histogram_bin_edges(a, bins=10, range=None, weights=None):
675675
676676
For full documentation refer to :obj:`numpy.histogram_bin_edges`.
677677
678-
Warning
679-
-------
678+
Warnings
679+
--------
680680
This function may synchronize in order to check a monotonically increasing
681681
array of bin edges. This may harm performance in some applications.
682682
@@ -767,8 +767,8 @@ def histogram2d(x, y, bins=10, range=None, density=None, weights=None):
767767
768768
For full documentation refer to :obj:`numpy.histogram2d`.
769769
770-
Warning
771-
-------
770+
Warnings
771+
--------
772772
This function may synchronize in order to check a monotonically increasing
773773
array of bin edges. This may harm performance in some applications.
774774
@@ -1100,8 +1100,8 @@ def histogramdd(sample, bins=10, range=None, density=None, weights=None):
11001100
11011101
For full documentation refer to :obj:`numpy.histogramdd`.
11021102
1103-
Warning
1104-
-------
1103+
Warnings
1104+
--------
11051105
This function may synchronize in order to check a monotonically increasing
11061106
array of bin edges. This may harm performance in some applications.
11071107

dpnp/dpnp_iface_manipulation.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -829,8 +829,8 @@ def asfarray(a, dtype=None, *, device=None, usm_type=None, sycl_queue=None):
829829
out : dpnp.ndarray
830830
The input `a` as a float ndarray.
831831
832-
Warning
833-
-------
832+
Warnings
833+
--------
834834
This function is deprecated in favor of :obj:`dpnp.asarray` and
835835
will be removed in a future release.
836836
@@ -3099,8 +3099,8 @@ def resize(a, new_shape):
30993099
be used. In most other cases either indexing (to reduce the size) or
31003100
padding (to increase the size) may be a more appropriate solution.
31013101
3102-
Warning
3103-
-------
3102+
Warnings
3103+
--------
31043104
This functionality does **not** consider axes separately, i.e. it does not
31053105
apply interpolation/extrapolation.
31063106
It fills the return array with the required number of elements, iterating

dpnp/dpnp_iface_nanfunctions.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -122,15 +122,15 @@ def nanargmax(a, axis=None, out=None, *, keepdims=False):
122122
123123
For full documentation refer to :obj:`numpy.nanargmax`.
124124
125-
Warning
126-
-------
125+
Warnings
126+
--------
127127
This function synchronizes in order to test for all-NaN slices in the array.
128128
This may harm performance in some applications. To avoid synchronization,
129129
the user is recommended to filter NaNs themselves and use `dpnp.argmax`
130130
on the filtered array.
131131
132-
Warning
133-
-------
132+
Warnings
133+
--------
134134
The results cannot be trusted if a slice contains only NaNs
135135
and -Infs.
136136
@@ -206,15 +206,15 @@ def nanargmin(a, axis=None, out=None, *, keepdims=False):
206206
207207
For full documentation refer to :obj:`numpy.nanargmin`.
208208
209-
Warning
210-
-------
209+
Warnings
210+
--------
211211
This function synchronizes in order to test for all-NaN slices in the array.
212212
This may harm performance in some applications. To avoid synchronization,
213213
the user is recommended to filter NaNs themselves and use `dpnp.argmax`
214214
on the filtered array.
215215
216-
Warning
217-
-------
216+
Warnings
217+
--------
218218
The results cannot be trusted if a slice contains only NaNs
219219
and -Infs.
220220

dpnp/scipy/linalg/_decomp_lu.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -130,8 +130,8 @@ def lu(
130130
permutation matrix is still needed then it can be constructed by
131131
``dpnp.eye(M)[P, :]``.
132132
133-
Warning
134-
-------
133+
Warnings
134+
--------
135135
This function synchronizes in order to validate array elements
136136
when ``check_finite=True``, and also synchronizes to compute the
137137
permutation from LAPACK pivot indices.
@@ -233,8 +233,8 @@ def lu_factor(a, overwrite_a=False, check_finite=True):
233233
row i of matrix was interchanged with row piv[i].
234234
Where ``K = min(M, N)``.
235235
236-
Warning
237-
-------
236+
Warnings
237+
--------
238238
This function synchronizes in order to validate array elements
239239
when ``check_finite=True``.
240240
@@ -302,8 +302,8 @@ def lu_solve(lu_and_piv, b, trans=0, overwrite_b=False, check_finite=True):
302302
x : {(M,), (..., M, K)} dpnp.ndarray
303303
Solution to the system
304304
305-
Warning
306-
-------
305+
Warnings
306+
--------
307307
This function synchronizes in order to validate array elements
308308
when ``check_finite=True``.
309309

0 commit comments

Comments
 (0)