[Numpy-discussion] Ensuring one can operate on array-like argument in place

Pauli Virtanen pav at iki.fi
Sun Nov 13 09:29:06 EST 2016

Sat, 12 Nov 2016 17:00:07 +0000, Pavlyk, Oleksandr kirjoitti:
>     if x_arr is not x:
>        in_place = 1  # a copy was made, so we can work in place.
> The logic is of the last line turns out to be incorrect, because the
> input x can be a class with an array interface.

Please see:


This probably can be translated to equivalent Numpy C API calls.

More information about the NumPy-Discussion mailing list