本文簡要介紹 python 語言中  numpy.dtype.subdtype  的用法。
- 用法:- dtype.subdtype
- 如果此 - dtype說明了 sub-array,則為元組- (item_dtype, shape),否則為 None。- 形狀是該數據類型說明的sub-array的固定形狀,item_dtype是數組的數據類型。 - 如果檢索到其 dtype 對象具有此屬性的字段,則將 shape 隱含的額外維度附加到檢索到的數組的末尾。 - 例子:- >>> x = numpy.dtype('8f') >>> x.subdtype (dtype('float32'), (8,))- >>> x = numpy.dtype('i2') >>> x.subdtype >>>
相關用法
- Python numpy dtype.shape用法及代碼示例
- Python numpy dtype.isbuiltin用法及代碼示例
- Python numpy dtype.ndim用法及代碼示例
- Python numpy dtype.alignment用法及代碼示例
- Python numpy dtype.names用法及代碼示例
- Python numpy dtype.__class_getitem__用法及代碼示例
- Python numpy dtype.flags用法及代碼示例
- Python numpy dtype.fields用法及代碼示例
- Python numpy dtype.descr用法及代碼示例
- Python numpy dtype.kind用法及代碼示例
- Python numpy dtype.metadata用法及代碼示例
- Python numpy dtype.newbyteorder用法及代碼示例
- Python numpy dtype.char用法及代碼示例
- Python numpy dtype.base用法及代碼示例
- Python numpy dtype.byteorder用法及代碼示例
- Python numpy dtype.num用法及代碼示例
- Python numpy dtype.name用法及代碼示例
- Python numpy dtype.itemsize用法及代碼示例
- Python numpy dtype用法及代碼示例
- Python numpy diagonal用法及代碼示例
- Python numpy divmod用法及代碼示例
- Python numpy diagflat用法及代碼示例
- Python numpy delete用法及代碼示例
- Python numpy dec.setastest用法及代碼示例
- Python numpy datetime_as_string用法及代碼示例
注:本文由純淨天空篩選整理自numpy.org大神的英文原創作品 numpy.dtype.subdtype。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。
