Skip to content

Commit

Permalink
Merge branch 'main' into exclude-zattrs-when-empty
Browse files Browse the repository at this point in the history
  • Loading branch information
magland committed Mar 16, 2024
2 parents a8d894b + d091b5e commit f816989
Showing 1 changed file with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,21 +1,23 @@
# LINDI - Linked Data Interface

warning: Please note, LINDI is currently under development and not yet operational.
:warning: Please note, LINDI is currently under development and not yet operational.

LINDI is a Python library that facilitates handling NWB (Neurodata Without Borders) files in an efficient, flexible manner that minimizes the need for excessive data downloads. Our goal is to enable composition of NWB files by integrating data from multiple sources.

Key features include:

- A read-only [Zarr store](https://zarr.readthedocs.io/en/stable/) for hdf5 files, including NWB (in progress)
- A read-only [Zarr storage backend](https://zarr.readthedocs.io/en/stable/) for HDF5 files, including NWB. In other words, a Zarr wrapper for HDF5. *(in progress)*
- Generation of a relatively small JSON file representing the NWB Zarr store, inspired by [kerchunk](https://github.com/fsspec/kerchunk).
- An [h5py](https://www.h5py.org/)-like interface for accessing NWB Zarr stores that can be used with [pynwb](https://pynwb.readthedocs.io/en/stable/), although this feature is not yet functional.
- The ability to assemble composite NWB files that draw from multiple sources, which is also not yet functional.
- An [h5py](https://www.h5py.org/)-like interface for accessing NWB Zarr stores that can be used with [pynwb](https://pynwb.readthedocs.io/en/stable/). In other words an h5py-like wrapper for Zarr. This feature is only partially functional.
- The ability to assemble composite NWB files that draw from multiple sources. Also not yet functional.

This project was inspired by [kerchunk](https://github.com/fsspec/kerchunk) and [hdmf-zarr](https://hdmf-zarr.readthedocs.io/en/latest/index.html).
Why a Zarr wrapper of HDF5, and then an h5py-like wrapper of Zarr? It's because we need a Zarr representation of existing files HDF5 NWB files, but we want to still leverage tools that utilize h5py.

This project was inspired by [kerchunk](https://github.com/fsspec/kerchunk) and [hdmf-zarr](https://hdmf-zarr.readthedocs.io/en/latest/index.html) and depends on [zarr](https://zarr.readthedocs.io/en/stable/), [h5py](https://www.h5py.org/), [remfile](https://github.com/magland/remfile), [fsspec](https://filesystem-spec.readthedocs.io/en/latest/), and [numcodecs](https://numcodecs.readthedocs.io/en/stable/).

## Installation

Clone this repo and then
For now, install from source. Clone this repo and then

```bash
cd lindi
Expand Down Expand Up @@ -44,7 +46,7 @@ rfs = store.to_reference_file_system()
with open("example.zarr.json", "w") as f:
json.dump(rfs, f, indent=2)

# Create the client from the reference file system
# Create the h5py-like client from the reference file system
client = lindi.LindiClient.from_reference_file_system(rfs)

# Try to read using pynwb
Expand All @@ -54,6 +56,8 @@ with pynwb.NWBHDF5IO(file=client, mode="r") as io:
print(nwbfile)
```

The idea is that you would then be able to augment, mix, and merge the reference file system JSON files, creating NWB files that can involve chunk data from multiple sources.

## License

See [LICENSE](LICENSE).

0 comments on commit f816989

Please sign in to comment.