Open weiglszonja opened 2 years ago
My main point is just that the data access through the actual NWBFile is 'fine' - has no issues and is clear what dims represent. Error stems from how the widgets code expects the output shape to be, which I think ought to be able to handle this case.
Rendering
SpatialSeries
data withnwbwidgets
is not possible whenspatial_series.data.shape[1] == 1
. I noticed this issue when when trying to visualiseSpatialSeries
data for a dandi dataset : "animal_direction" which is aSpatialSeries
with a shape of(90050, 1)
(see below steps to reproduce).We discussed with @CodyCBakerPhD that this should be handled on the widgets side, as this data was created with
pynwb
without complains. Currently, this case gets handled as:https://github.com/NeurodataWithoutBorders/nwb-jupyter-widgets/blob/c891978d74a2e52a3ccbf65949f5b8192858e1dc/nwbwidgets/behavior.py#L93-L94
If you agree this should be handled on the widgets side as well, I'll try to create a PR for this as well.
Steps to reproduce with the real data: