-
Notifications
You must be signed in to change notification settings - Fork 26
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
HTML representation of nwbfile
results in RecursionError
#1010
Labels
category: bug
errors in the code or code behavior
priority: high
impacts proper operation or use of feature important to most users
Comments
Do you have a cyclic structure in your file? |
@rly Sorry, it's not because of linked Device, I managed to reproduce the error by linking timestamps across multiple SpatialSeries objects (which is what I also have in this dataset) You should be able to reproduce the above error if you run this from a Jupyter notebook: from pynwb import NWBHDF5IO
from pynwb.testing.mock.file import mock_NWBFile
from pynwb.testing.mock.behavior import mock_SpatialSeries, mock_Position
import numpy as np
nwbfile = mock_NWBFile()
test_timestamps = np.zeros((1000,))
test_data = np.random.rand(*(1000, 3))
spatial_series1 = mock_SpatialSeries(name="test1", rate=None, data=test_data, timestamps=test_timestamps)
spatial_series2 = mock_SpatialSeries(name="test2", rate=None, data=test_data, timestamps=spatial_series1)
spatial_series3 = mock_SpatialSeries(name="test3", rate=None, data=test_data, timestamps=spatial_series1)
spatial_series4 = mock_SpatialSeries(name="test4", rate=None, data=test_data, timestamps=spatial_series1)
position = mock_Position(spatial_series=[spatial_series1, spatial_series2, spatial_series3, spatial_series4])
nwbfile.create_processing_module("behavior", description="contains processed behavior data")
nwbfile.processing["behavior"].add(position)
with NWBHDF5IO("test.nwb", "w") as io:
io.write(nwbfile)
read_io = NWBHDF5IO("test.nwb", "r")
nwbfile_in = read_io.read()
nwbfile_in In the real dataset, it looks like this:
|
rly
added
category: bug
errors in the code or code behavior
priority: medium
non-critical problem and/or affecting only a small set of users
labels
Dec 14, 2023
3 tasks
rly
added
priority: high
impacts proper operation or use of feature important to most users
priority: medium
non-critical problem and/or affecting only a small set of users
and removed
priority: medium
non-critical problem and/or affecting only a small set of users
labels
Jan 19, 2024
This was referenced Jan 24, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
category: bug
errors in the code or code behavior
priority: high
impacts proper operation or use of feature important to most users
@rly I tried out the fix in #1006 to link a device (which is not named "device") in
OptogeneticStimulusSite
, the read/write is working fine but I get a weird error when trying to show the contents of such a file in a Jupyter notebook (posted here)Is there something I missed?
The full traceback:
The text was updated successfully, but these errors were encountered: