Repo: GitHub - shivasankarka/hdf5-mojo: High-level HDF5 bindings for Mojo · GitHub
Updated both ffi and core API with some nice upgrades! This update is focused on making things feel more natural (especially if you’ve used h5py before) and generally easier to work with.
What’s new
- API updated to be slightly more more h5py-compatible
- Added NuMojo NDArray as the backend for array ops (finally it’s very easy to work with N-D data!)
- Reworked HDF5 handle ownership (there were too many UnsafePointers floating around):
Filenow ownsHDF5LibviaOwnedPointer- Wrappers (groups/datasets/attrs) now carry typed, origin-aware references (This was a good exercise on mojo origin system
which still confuses and surprises me.)
UnsafePointeris now only used in raw FFI buffers.- Added
.get()for access (temporary replacement for__getitem__while I figure out how to make__getitem__work seamlessly in all scenarios.) - Standardized examples/docs around
read[dtype]() - Cleaned up some docstring + dtype wording issues.
If you run into anything missing or weird, feel free to open an issue or PR. As always, happy computing!
Also thanks to @duck_tape for his work on pixi-build-mojo, it’s been a life saver in all the projects! ![]()