NeuralEnsemble / python-neo

Neo is a package for representing electrophysiology data in Python, together with support for reading a wide range of neurophysiology file formats
http://neo.readthedocs.io/en/latest/
BSD 3-Clause "New" or "Revised" License
325 stars 248 forks source link

Added a sorted to the listdir of the files in neuralynx folder to avo… #1512

Closed Antho2422 closed 4 months ago

Antho2422 commented 4 months ago

This pull request is fixing an issue coming from this : https://github.com/NeuralEnsemble/python-neo/pull/1440

The issue was causing mixed channel ids : https://github.com/SpikeInterface/spikeinterface/issues/3248 when loading data into spikeinterface.

We need to keep the sorted() when doing an os.listdir() here because the list directory depends on the os. This avoids mixing the filenames when reading the headers.

Thanks, Anthony

zm711 commented 4 months ago

Thanks @Antho2422,

We will merge after tests pass!