class documentation

class _CopyMode(enum.Enum):

View In Hierarchy

An enumeration for the copy modes supported by numpy.copy() and numpy.array(). The following three modes are supported,

  • ALWAYS: This means that a deep copy of the input
    array will always be taken.
  • IF_NEEDED: This means that a deep copy of the input
    array will be taken only if necessary.
  • NEVER: This means that the deep copy will never be taken.
    If a copy cannot be avoided then a ValueError will be raised.

Note that the buffer-protocol could in theory do copies. NumPy currently assumes an object exporting the buffer protocol will never do this.

Constant ALWAYS Undocumented
Constant IF​_NEEDED Undocumented
Constant NEVER Undocumented
Method __bool__ Undocumented
ALWAYS: bool =

Undocumented

Value
True
IF_NEEDED: bool =

Undocumented

Value
False
NEVER: int =

Undocumented

Value
2
def __bool__(self):

Undocumented