Skip to content

Commit f69ef28

Browse files
committed
Add synchronization warning to nanargmin and nanargmax documentation
1 parent 4552fe8 commit f69ef28

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

dpnp/dpnp_iface_nanfunctions.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,13 @@ def nanargmax(a, axis=None, out=None, *, keepdims=False):
137137
138138
For full documentation refer to :obj:`numpy.nanargmax`.
139139
140+
Warning
141+
-------
142+
This function synchronizes in order to test for all-NaN slices in the array.
143+
This may harm performance in some applications. To avoid synchronization,
144+
the user is recommended to filter NaNs themselves and use `dpnp.argmax`
145+
on the filtered array.
146+
140147
Parameters
141148
----------
142149
a : {dpnp.ndarray, usm_ndarray}
@@ -211,6 +218,13 @@ def nanargmin(a, axis=None, out=None, *, keepdims=False):
211218
212219
For full documentation refer to :obj:`numpy.nanargmin`.
213220
221+
Warning
222+
-------
223+
This function synchronizes in order to test for all-NaN slices in the array.
224+
This may harm performance in some applications. To avoid synchronization,
225+
the user is recommended to filter NaNs themselves and use `dpnp.argmax`
226+
on the filtered array.
227+
214228
Parameters
215229
----------
216230
a : {dpnp.ndarray, usm_ndarray}

0 commit comments

Comments
 (0)