Explore HDF5 files in an HTML view
Project description
H5Glance lets you explore HDF5 files in the terminal or an HTML interface.
Install it with:
pip install h5glance
In the terminal, you can get a tree view of a file:
$ h5glance sample.h5 sample.h5 └path └inside └file [float64: 100 × 100]
The names of datasets, groups and links are colour-coded by default. If you want to disable this, set the environment variable H5GLANCE_COLORS=0. H5Glance also respects the NO_COLOR convention.
Inspect a group or dataset inside it:
$ h5glance sample.h5 path/inside/file sample.h5/path/inside/file dtype: float64 shape: 100 × 100 maxshape: 100 × 100 layout: Contiguous sample data: [[-0.27756437 0.36923643 -0.28113527 ...
In bash & zsh, h5glance offers tab-completion for the paths inside HDF5 files. To set this up, run:
python -m h5glance.completer
Alternatively, use - as the second argument, and h5glance will prompt you for the object path with tab completion:
$ h5glance sample.h5 - Object path: sample.h5/ # try tapping tab
HTML interface
The HTML interface lets you inspect HDF5 files in a Jupyter Notebook. Demo.ipynb shows how to use it.
Why H5Glance?
There are plenty of other tools to view HDF5 files, including HDFView and ViTables, as well as various web-based viewers in development. Why might you choose H5Glance?
Practical terminal interface: if you’re working in a terminal, it’s much quicker to use something there than to start a GUI application and click through it.
Tab completions are part of this - take a moment to set them up (see above).
Static Jupyter views: H5Glance shows your HDF5 objects in simple HTML, which doesn’t talk to the server. Export your notebook to HTML, or view it on nbviewer, and the H5Glance view is still there.
Deeply nested structure: It was written at European XFEL, where data files can easily have 6 layers of nested groups. It tries to make working with that easy.
Some things it’s not designed for:
Viewing data: The terminal interface can show raw data, but it focuses on the structure of HDF5 files, not their content. H5Glance won’t show you plots or images.
Machine-readable output: It’s meant for people, not programs. In Python, your code can use h5py. For shell pipelines, use tools like h5ls and h5dump.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file h5glance-0.9.0.tar.gz
.
File metadata
- Download URL: h5glance-0.9.0.tar.gz
- Upload date:
- Size: 22.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 36c4b20d132fdc766efad09939465ebd4836095999420d0ada094da6f475ba6d |
|
MD5 | 1249efa1563a009d7779620f43be84c1 |
|
BLAKE2b-256 | 62b29e522e0ecba22de841b59ebe2523817bacd435de49275f9ae0d07aebedc2 |
Provenance
The following attestation bundles were made for h5glance-0.9.0.tar.gz
:
Publisher:
tests.yml
on European-XFEL/h5glance
-
Statement type:
https://in-toto.io/Statement/v1
- Predicate type:
https://docs.pypi.org/attestations/publish/v1
- Subject name:
h5glance-0.9.0.tar.gz
- Subject digest:
36c4b20d132fdc766efad09939465ebd4836095999420d0ada094da6f475ba6d
- Sigstore transparency entry: 149746794
- Sigstore integration time:
- Predicate type:
File details
Details for the file h5glance-0.9.0-py3-none-any.whl
.
File metadata
- Download URL: h5glance-0.9.0-py3-none-any.whl
- Upload date:
- Size: 18.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | db1810f8e8e5dda8528eee199e4c5fff61b8b37c5ce2291c2bd71d04f0d5b354 |
|
MD5 | 238d705ded17c76858aa1eac5f81b681 |
|
BLAKE2b-256 | 3d7d5f718d5eb41368d05bb7017cf41dde55b09c66658c912d2fc36ebbcde399 |
Provenance
The following attestation bundles were made for h5glance-0.9.0-py3-none-any.whl
:
Publisher:
tests.yml
on European-XFEL/h5glance
-
Statement type:
https://in-toto.io/Statement/v1
- Predicate type:
https://docs.pypi.org/attestations/publish/v1
- Subject name:
h5glance-0.9.0-py3-none-any.whl
- Subject digest:
db1810f8e8e5dda8528eee199e4c5fff61b8b37c5ce2291c2bd71d04f0d5b354
- Sigstore transparency entry: 149746795
- Sigstore integration time:
- Predicate type: