h5py writes a dataset (libver earliest, so version-1 object headers) and the script damages one field of a copy: a layout message flagged shareable, a message size that is not a multiple of 8, a compound field that repeats an earlier name or overlaps it, an empty enum member name, a float exponent overlapping the mantissa. h5py refuses every damaged copy, and clawhdf5 must refuse exactly those and read the valid files. All of them but the unaligned one (then an UnexpectedEof) read before this branch. The helper now reads any datatype (File::read_multi) rather than only integers. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
clawhdf5
Pure-Rust HDF5 reader/writer — no C dependencies.
Features
- Read and write HDF5 files entirely in Rust
- Memory-mapped I/O for large files (
mmapfeature, enabled by default) - Parallel chunk reads via Rayon (
parallelfeature) - Lazy dataset access for minimal memory usage
- h5py-compatible file output
Usage
use clawhdf5::File;
let file = File::open("data.h5").unwrap();
let dataset = file.dataset("/group/data").unwrap();
let values: Vec<f64> = dataset.read_1d().unwrap();
License
MIT