如何创建类似MNIST数据集的文件 [英] How to create a file like the MNIST dataset

查看:407
本文介绍了如何创建类似MNIST数据集的文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

所以我有一堆图像(PNG),它们的名称可用作标签.是否有工具或示例,说明我如何拍摄这些图像并创建像MNIST IDX这样的数据集.

So i have a bunch of images (PNG) and their names can be used as labels. Is there a tool or an example on how i can take those images and create a dataset like the MNIST IDX one.

有很多关于如何阅读它们的示例,但是没有关于如何创建它们的示例.

There are a lot of examples on how to read them but no examples on how to create them.

任何帮助将不胜感激!

推荐答案

这可以帮助您.

-images-文件是使用功能save-idx3-ubyte编写的,-labels-文件是使用功能save-idx1-ubyte编写的.有问题的功能在lush/lsh/libidx/idx-io.lsh中定义.文件格式在标准库"下的可编译I/O的IDX文件格式"部分中说明->"Tensor/Matrix/标量/向量库"->"IDX读写".

The -images- files were written using the function save-idx3-ubyte and the -labels- files with the function save-idx1-ubyte. The functions in questions are defined in lush/lsh/libidx/idx-io.lsh The file format is described in the section "IDX file format for compilable I/O" which is under "standard libraries" -> "Tensor/Matrix/Scalar/Vector libraries" -> "IDX reading and writing".

文件标题中的32位整数可能被字节交换.

The 32-bit ints in the header of the files may be byte-swapped.

-Yann

http://sourceforge.net/p/lush/mailman/message/28879896/

这篇关于如何创建类似MNIST数据集的文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆