Authors: Christophe Pouzat and Georgios Is. Detorakis(corresponding author)
Neuroscientists use extracellular recordings to monitor many neurons while keeping tissue damage at a minimum. But the collected raw data are then mixtures of activities—from many neurons—that have to be separated or sorted before most physiologically relevant questions can be addressed. Sev- eral spike sorting methods have not surprisingly been proposed over time and we implement here, as a Python package, an extension of the method described in . The SPySort package takes advantage of the Numpy arrays and statistical tools, Matplotlib plot functions, Scipy signal processing and statistical modules and the Scikit-learn k-means and Gaussian Mixture model. In addition, some of the Pandas methods are used to provide some robust statistical tools. By exploiting all the aforementioned Python packages, SPySort is a flexible and easy-to-use environment for spike sorting. SPySort consists of five modules. The first module provides methods for reading, normalizing, subset- ting raw data—i.e. selecting specific recording channels—as well as a summary method returning all the important statistics of the raw data. The second module takes care of spikes detection and also includes methods for filtering the data. The third module extracts events—i.e. makes cuts on the raw data around the locations of the detected spikes. The next module performs clustering after an optional dimension reduction using PCA. The user can choose among three presently implemented clustering algorithms: k-means; Gaussian Mixture model; Bagged clustering. The end result of this clustering stage is a set of waveforms associated with the different identified neurons. The last stage goes back to the raw data (or to the next chunk of recorded data) and resolve all detected events including the superposed ones. A new fast and efficient sampling jitter correction algorithm is used at that stage. SPySort has its own github place at: https://github.com/gdetor/SPySort
This work has received support from the French ANR project SynchNeuro.
Keywords: Spike sorting, Python, neural events, spike events clustering, extracellular recordings.