-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Zarr links should be relative to root #44
Comments
I believe ultimately the issue is most likely in how paths are being determined for links in: hdmf-zarr/src/hdmf_zarr/backend.py Line 500 in 48ab39f
Links are currently stored as part of the reserved attribute
Could you post the contents from the JSON
I agree, links should be relative to the Zarr root. |
Thanks @oruebel Attached is a miniml toy example with a broken link (Device): |
@mavaylon1 could you take a look at this? |
Excited to see that you are working on this! Allen Institute for Neural Dynamics is running a small workshop in January and we want to use NWB-Zarr files. |
I'll take a look |
Thanks @mavaylon1 for taking a look. While the issue refers to links, the same problem likely also exists for object references (which are links that are stored in datasets or attributes). All links are constructed via: hdmf-zarr/src/hdmf_zarr/backend.py Line 448 in 48ab39f
I.e., to fix the write of links, this is probably where we need to fix things. The hdmf-zarr/src/hdmf_zarr/backend.py Line 500 in 48ab39f
hdmf-zarr/src/hdmf_zarr/backend.py Line 603 in 48ab39f
hdmf-zarr/src/hdmf_zarr/backend.py Line 311 in 48ab39f
To construct the definition of references for storing them as links or in datasets or attributes. I.e., fixing this for write I think may only require some minor changes in However, changing the logic in hdmf-zarr/src/hdmf_zarr/backend.py Line 988 in 48ab39f
hdmf-zarr/src/hdmf_zarr/backend.py Line 1084 in 48ab39f
hdmf-zarr/src/hdmf_zarr/backend.py Line 1130 in 48ab39f
hdmf-zarr/src/hdmf_zarr/backend.py Line 1022 in 48ab39f
will likely not need to change, but I just wanted to mention just in case there are changes needed there as well. I think the changes needed for read should be fairly simple, i.e., once the read for links works, the changes should translate to the other functions fairly directly. Let me know in case you run into any issues. |
@dyf that's great. Let us know in case there is anything we can do to help. |
Will do thanks @oruebel. If we can get useable files by end of the year that would be awesome. We want to show them off in the Jupyter NWB Widgets, so if you want to do some sanity checks there that would also be appreciated. |
Thanks, that is good to know. I'll try to put together an example with NWBWidgets + Zarr next week. I have not tried this before but I think it should work since NWBWidgets uses NWBFile from PyNWB as an input. |
@mavaylon1 any update on this |
This PR illustrates the problem #46 |
Hi guys,
I was able to successfully export to NWB-zarr sorting info + waveforms and electrode table (using
neuroconv
).I performed the conversion remotely and then downloaded the resulting files. When I try to read the file locally, I get a bad link error:
After debugging, the
l_path
is indeed the path on my remote machine. I think saving links relative to the zarr root should fix it.The text was updated successfully, but these errors were encountered: