A neural network for online spike classification that improves decoding accuracy
- PMID: 32101491
- PMCID: PMC7191521
- DOI: 10.1152/jn.00641.2019
A neural network for online spike classification that improves decoding accuracy
Abstract
Separating neural signals from noise can improve brain-computer interface performance and stability. However, most algorithms for separating neural action potentials from noise are not suitable for use in real time and have shown mixed effects on decoding performance. With the goal of removing noise that impedes online decoding, we sought to automate the intuition of human spike-sorters to operate in real time with an easily tunable parameter governing the stringency with which spike waveforms are classified. We trained an artificial neural network with one hidden layer on neural waveforms that were hand-labeled as either spikes or noise. The network output was a likelihood metric for each waveform it classified, and we tuned the network's stringency by varying the minimum likelihood value for a waveform to be considered a spike. Using the network's labels to exclude noise waveforms, we decoded remembered target location during a memory-guided saccade task from electrode arrays implanted in prefrontal cortex of rhesus macaque monkeys. The network classified waveforms in real time, and its classifications were qualitatively similar to those of a human spike-sorter. Compared with decoding with threshold crossings, in most sessions we improved decoding performance by removing waveforms with low spike likelihood values. Furthermore, decoding with our network's classifications became more beneficial as time since array implantation increased. Our classifier serves as a feasible preprocessing step, with little risk of harm, that could be applied to both off-line neural data analyses and online decoding.NEW & NOTEWORTHY Although there are many spike-sorting methods that isolate well-defined single units, these methods typically involve human intervention and have inconsistent effects on decoding. We used human classified neural waveforms as training data to create an artificial neural network that could be tuned to separate spikes from noise that impaired decoding. We found that this network operated in real time and was suitable for both off-line data processing and online decoding.
Keywords: BCI; decoding; neural network; prefrontal cortex; spike-sorting.
Conflict of interest statement
No conflicts of interest, financial or otherwise, are declared by the authors.
Figures






Similar articles
-
To sort or not to sort: the impact of spike-sorting on neural decoding performance.J Neural Eng. 2014 Oct;11(5):056005. doi: 10.1088/1741-2560/11/5/056005. Epub 2014 Aug 1. J Neural Eng. 2014. PMID: 25082508 Free PMC article.
-
Spike detection and spike sorting with a hidden Markov model improves offline decoding of motor cortical recordings.J Neural Eng. 2019 Feb;16(1):016014. doi: 10.1088/1741-2552/aaeaae. Epub 2018 Oct 23. J Neural Eng. 2019. PMID: 30523823
-
Comparison of spike sorting and thresholding of voltage waveforms for intracortical brain-machine interface performance.J Neural Eng. 2015 Feb;12(1):016009. doi: 10.1088/1741-2560/12/1/016009. Epub 2014 Dec 11. J Neural Eng. 2015. PMID: 25504690 Free PMC article.
-
Reliability of motor and sensory neural decoding by threshold crossings for intracortical brain-machine interface.J Neural Eng. 2019 Jun;16(3):036011. doi: 10.1088/1741-2552/ab0bfb. Epub 2019 Mar 1. J Neural Eng. 2019. PMID: 30822756
-
Decoding Local Field Potentials for Neural Interfaces.IEEE Trans Neural Syst Rehabil Eng. 2017 Oct;25(10):1705-1714. doi: 10.1109/TNSRE.2016.2612001. Epub 2016 Nov 14. IEEE Trans Neural Syst Rehabil Eng. 2017. PMID: 28113942 Free PMC article. Review.
Cited by
-
Compact deep neural network models of visual cortex.bioRxiv [Preprint]. 2023 Nov 23:2023.11.22.568315. doi: 10.1101/2023.11.22.568315. bioRxiv. 2023. PMID: 38045255 Free PMC article. Preprint.
-
Robustness of working memory to prefrontal cortex microstimulation.bioRxiv [Preprint]. 2025 Jan 14:2025.01.14.632986. doi: 10.1101/2025.01.14.632986. bioRxiv. 2025. Update in: J Neurosci. 2025 May 30:e2197242025. doi: 10.1523/JNEUROSCI.2197-24.2025. PMID: 39868186 Free PMC article. Updated. Preprint.
-
Brain-wide arousal signals are segregated from movement planning in the superior colliculus.bioRxiv [Preprint]. 2025 Jun 27:2024.04.26.591284. doi: 10.1101/2024.04.26.591284. bioRxiv. 2025. PMID: 38746466 Free PMC article. Preprint.
-
Recent Visual Experience Reshapes V4 Neuronal Activity and Improves Perceptual Performance.J Neurosci. 2024 Oct 9;44(41):e1764232024. doi: 10.1523/JNEUROSCI.1764-23.2024. J Neurosci. 2024. PMID: 39187380 Free PMC article.
-
Interactions across hemispheres in prefrontal cortex reflect global cognitive processing.bioRxiv [Preprint]. 2025 Jun 13:2025.06.12.659406. doi: 10.1101/2025.06.12.659406. bioRxiv. 2025. PMID: 40661521 Free PMC article. Preprint.
References
-
- Abadi M, Agarwal A, Barham P, Brevdo E, Chen Z, Citro C, Corrado GS, Davis A, Dean J, Devin M, Ghemawat S, Goodfellow I, Harp A, Irving G, Isard M, Jia Y, Jozefowicz R, Kaiser L, Kudlur M, Levenberg J, Mane D, Monga R, Moore S, Murray D, Olah C, Schuster M, Shlens J, Steiner B, Sutskever I, Talwar K, Tucker P, Vanhoucke V, Vasudevan V, Viegas F, Vinyals O, Warden P, Wattenberg M, Wicke M, Yu Y, Zheng X. TensorFlow: large-scale machine learning on heterogeneous distributed systems. In: OSDI'16: Proceedings of the 12th USENIX Conference on Operating Systems ... Berkeley, CA: USENIX Association, 2016.
Publication types
MeSH terms
Grants and funding
LinkOut - more resources
Full Text Sources