Skip to content

Fix neuroexplorer version 106 - #1907

Open
h-mayorquin wants to merge 4 commits into
NeuralEnsemble:masterfrom
h-mayorquin:fix_neuroexplorer_version_106
Open

h-mayorquin wants to merge 4 commits into
NeuralEnsemble:masterfrom
h-mayorquin:fix_neuroexplorer_version_106

Conversation

@h-mayorquin

Copy link
Copy Markdown
Contributor

NeuroExplorer has written .nex version 106 since 2011, and the reader cannot open those files when a waveform variable has a prethreshold time. This PR enables that. Version 106 added the prethreshold time, the part of each waveform snippet recorded before the threshold crossing, stored as the float64 PrethresholdTimeInSeconds.

So now:

  • Version 106 files with a non-zero prethreshold time open, where before they raised UnicodeDecodeError.
  • wf_left_sweep carries the file's prethreshold time in samples (8 for 0.0002 s at 40 kHz) instead of a hardcoded 0.
  • Files before version 106 still report a left sweep of 0, since those bytes are padding there.

For tests I added nonzero_prethreshold.nex, a version 106 file already on gin, cut from the vendor sample. Critically, the compliance tests were not running on any NeuroExplorer file because the attribute was misnamed: it was files_to_download, and I changed it to the correct entities_to_test.

@h-mayorquin h-mayorquin self-assigned this Oct 2, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant