Python 读取GIST Data Set(二)
来源:互联网 发布:电脑网络钓鱼游戏 编辑:程序博客网 时间:2024/05/21 07:07
摘取自:http://www.cnblogs.com/gala/archive/2011/09/22/2184801.html
以读取GIST SIFT数据集为目的对原文进行了摘选和修改:
对struct.unpack_from('<I' , Buffer , index)中重要参数'<I' 进行说明:
struct支持以下格式:
Format C Type Python 字节数
对于Matlab中的Uint8数据类型,可以替换为unsigned char.
struct根据本地机器字节顺序转换(Big-endian, Little-endian).可以用格式中的第一个字符来改变对齐方式.
定义如下:
Character
Byte order
Size and alignment
@
native
native 凑够4个字节
=
native
standard 按原字节数
<
little-endian
standard 按原字节数
>
big-endian
standard 按原字节数
!
network (= big-endian)
standard 按原字节数
'<IIII'小端方式读入连续16字节,解析为4个Python中4字节整形数据类型.
'>I6f7BI'大端方式读入连续(4+6*4+7*1+4)字节。
解析为连续的1个4字节整形数据类型,6个4字节float数据类型,7个1字节整形数据类型,一个4字节整形数据类型.
0 0
- Python 读取GIST Data Set(二)
- Python 读取GIST Data Set(一)
- GIST
- gist
- gist
- 二、Python Data Types
- [gist]How to use Mock testing Python
- python提取GIST特征,安装pyleargist包
- Data Set
- Data Set
- python读取xml(二)
- 使用jQuery的data读取标签缓存数据 ( 二 )
- Python积累(二).Python中集合使用(set)
- 基于jmeter3.0版本的csv data set config二次开发(实现从指定行开始读取)
- python读取excel群发邮件(二)
- Opencv-Python(二) 读取, 写入/出视频
- Disjoint-set Data Structures
- Disjoint-set Data Structures
- hive 元数据 mysql-1
- 餐饮管理系统大作业SQL/C#
- 有用的Matlab、C、C++、Python和LaTeX代码以及数据集
- Swift如何取得View所属的ViewController
- Linux 命令小结
- Python 读取GIST Data Set(二)
- CodeForces 366A Dima and Guards (暑期小练习)
- 选数[CQOI2015][bzoj3930]
- hive 元数据 mysql-2
- 第十六周实践项目之阅读程序————2
- 历史数据查询(流程实例、活动、任务、流程变量)
- Spring3.x中各个jar包的作用总结
- linux gzip、bzip2常用压缩、解压缩指令总结
- Android Studio 打包