flatironinstitute / neurosift

Browser-based NWB visualization and DANDI exploration
Apache License 2.0
42 stars 6 forks source link

TwoPhotonSeries data not loading for recent dataset #203

Open bendichter opened 1 week ago

bendichter commented 1 week ago

https://neurosift.app/?p=/nwb&url=https://api.dandiarchive.org/api/assets/879c8d7e-3735-467b-8c77-3464532fafbc/download/&dandisetId=001188&dandisetVersion=0.240912.1925

image
magland commented 1 week ago

It seems that the data has shape (0,0,0). Any idea why?

import remfile
import h5py
url = 'https://api.dandiarchive.org/api/assets/879c8d7e-3735-467b-8c77-3464532fafbc/download/'

# Load the remote file
remf = remfile.File(url)
f = h5py.File(remfile.File(url), 'r')

# load the neurodata object
X = f['/acquisition/TwoPhotonSeries']

print(X['data'].shape)

# output: (0, 0, 0)
magland commented 1 week ago

I think it's because the format is "external" => shape of data = (0, 0, 0)

bendichter commented 1 week ago

ah, ok. This is something we enabled early in NWB, where data contributors could store 2p data in external TIFF files, but this isn't something that's fully supported by DANDI. DANDI prefers data to be stored in the NWB files so it can benefit from lossless compression and chunking. I think we should add a best practice to prevent this type of data from being contributed in the future.