本文简要介绍 python 语言中  numpy.ndarray.newbyteorder  的用法。
- 用法:- ndarray.newbyteorder(new_order='S', /)
- 返回具有以不同字节顺序查看的相同数据的数组。 - 相当于: - arr.view(arr.dtype.newbytorder(new_order))- 还对数组数据类型的所有字段和子数组进行更改。 - new_order: 字符串,可选
- 字节顺序强制;来自以下字节顺序规范的值。 new_order 代码可以是以下任何一种: - ‘S’ - 将 dtype 从当前交换到相反的字节序 
- {‘<’, ‘little’} - 小端 
- {‘>’, ‘big’} - 大端 
- {‘=’, ‘native’} - 原生顺序,相当于 - sys.byteorder
- {‘|’, ‘I’} - 忽略(不改变字节顺序) 
 - 默认值 (‘S’) 会导致交换当前字节顺序。 
 
- new_arr: 数组
- 具有反映给定字节顺序更改的 dtype 的新数组对象。 
 
 - 参数:- 返回:
相关用法
- Python numpy ndarray.nbytes用法及代码示例
- Python numpy ndarray.ndim用法及代码示例
- Python numpy ndarray.astype用法及代码示例
- Python numpy ndarray.flat用法及代码示例
- Python numpy ndarray.setflags用法及代码示例
- Python numpy ndarray.setfield用法及代码示例
- Python numpy ndarray.sort用法及代码示例
- Python numpy ndarray.real用法及代码示例
- Python numpy ndarray.strides用法及代码示例
- Python numpy ndarray.itemset用法及代码示例
- Python numpy ndarray.__class_getitem__用法及代码示例
- Python numpy ndarray.partition用法及代码示例
- Python numpy ndarray.transpose用法及代码示例
- Python numpy ndarray.flatten用法及代码示例
- Python numpy ndarray.resize用法及代码示例
- Python numpy ndarray.dtype用法及代码示例
- Python numpy ndarray.imag用法及代码示例
- Python numpy ndarray.dot用法及代码示例
- Python numpy ndarray.size用法及代码示例
- Python numpy ndarray.fill用法及代码示例
- Python numpy ndarray.item用法及代码示例
- Python numpy ndarray.tobytes用法及代码示例
- Python numpy ndarray.copy用法及代码示例
- Python numpy ndarray.ctypes用法及代码示例
- Python numpy ndarray.view用法及代码示例
注:本文由纯净天空筛选整理自numpy.org大神的英文原创作品 numpy.ndarray.newbyteorder。非经特殊声明,原始代码版权归原作者所有,本译文未经允许或授权,请勿转载或复制。
