H5FS is a mountable Linux virtual file system that allows to read the content of HDF5 as if they were real files.
H5FS (Hierarchical Data Format FileSystem) is a file system for Linux (and other operating systems with a FUSE implementation, such as Mac OS X or FreeBSD) capable of operations on an HDF5 file.
On the local computer where the HDF5 file is mounted, the implementation makes use of the FUSE (Filesystem in Userspace) kernel module. The practical effect of this is that the end user can interact with the content of a HDF5 file in a natural way as HDF5 uses a filesystem-like data format to access the resources.
GROUPS are exposed as folders and DATASETS are exposed as files.
This example shows how to mount an HDF5 file /path/to/file.h5:
% mkdir /tmp/mountpoint % h5fs /path/to/file.h5 /tmp/mountpoint
The filesystem is now mounted and visible in /tmp/mountpoint. Assuming that the file contains a group "picture" with two datasets "image1" and "pallete", the resources can be listed using the tree program:
% tree /tmp/mountpoint /tmp/mountpoint `-- picture |-- image1.npy `-- pallete.npy 1 directories, 2 files
The array of a dataset can be read using python and the numpy module:
>>> import numpy >>> arr = numpy.load('/tmp/mountpoint/picture/image1.npy') >>> arr.shape (200, 400, 1) >>> exit()
To unmount the filesystem, use fusermount with the -u (unmount) option:
% fusermount -u /tmp/mountpoint % rm -r /tmp/mountpoint
|source repository||h5fs repository|
|test environment||testenv for h5fs|
|may be discussed on||<not specified>|
|use license||<not specified>|