numpy.dtype.base#

属性

dtype.base#

返回子数组基本元素的 dtype,无论其维度或形状如何。

另请参阅

dtype.subdtype

示例

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