numpy / 1.22.0 / reference / generated / numpy.dtype.base.html /

numpy.dtype.base

attribute

dtype. base

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

See also

dtype.subdtype

Examples

>>> x = numpy.dtype('8f')
>>> x.base
dtype('float32')
>>> x =  numpy.dtype('i2')
>>> x.base
dtype('int16')

© 2005–2021 NumPy Developers
Licensed under the 3-clause BSD License.
https://numpy.org/doc/1.22/reference/generated/numpy.dtype.base.html