File tree Expand file tree Collapse file tree 1 file changed +3
-6
lines changed
Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -746,12 +746,9 @@ def safezip(*args):
746746def safe_masked_invalid (x , copy = False ):
747747 x = np .array (x , subok = True , copy = copy )
748748 if not x .dtype .isnative :
749- # Note that the argument to `byteswap` is 'inplace',
750- # thus if we have already made a copy, do the byteswap in
751- # place, else make a copy with the byte order swapped.
752- # Be explicit that we are swapping the byte order of the dtype
753- x = x .byteswap (copy ).newbyteorder ('S' )
754-
749+ # If we have already made a copy, do the byteswap in place, else make a
750+ # copy with the byte order swapped.
751+ x = x .byteswap (inplace = copy ).newbyteorder ('N' ) # Swap to native order.
755752 try :
756753 xm = np .ma .masked_invalid (x , copy = False )
757754 xm .shrink_mask ()
You can’t perform that action at this time.
0 commit comments