numpy.dtype.base — NumPy v2.2 Manual (original) (raw)

attribute

dtype.base#

Returns dtype for the base element of the subarrays, regardless of their dimension or shape.

Examples

import numpy as np x = numpy.dtype('8f') x.base dtype('float32')

x = numpy.dtype('i2') x.base dtype('int16')