Skip to content

Commit 793f670

Browse files
Update src/array_api_extra/_delegation.py
Co-authored-by: Guido Imperiale <[email protected]>
1 parent 3c93718 commit 793f670

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/array_api_extra/_delegation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ def one_hot(
190190
raise IndexError from e
191191
else:
192192
out = _funcs.one_hot(x, num_classes, xp=xp)
193-
out = xp.astype(out, dtype)
193+
out = xp.astype(out, dtype, copy=False)
194194
if axis != -1:
195195
out = xp.moveaxis(out, -1, axis)
196196
return out

0 commit comments

Comments
 (0)