Desktop App: NeuroStream
Published:
Application: NeuroStream Title: Real-time BCI Motor Imagery Streaming Author: Yiming Shen License: MIT
Overview
NeuroStream trains a cross-subject EEG motor imagery classifier on the Zhou2016 dataset via MOABB, then replays a held-out subject as a pseudo-online stream. All feature extraction and classification pipelines are sourced from MOABB and pyriemann.
Highlights
- Four selectable pipelines via MOABB / pyriemann: CSP, FBCSP, TS+LDA, TS+SVM
- Euclidean Alignment (EA) for cross-subject covariance shift reduction
- Riemannian geometry (pyriemann): covariance estimation → Tangent Space classifier
- Desktop UI built with
tkinter, background training thread, real-time streaming - Live visualization: confidence bar, band power, trial history, confusion matrix
Pipelines
CSP
Classic Common Spatial Patterns with bandpass filtering (8–30 Hz), Euclidean Alignment, and LDA/SVM classification. Baseline from Jayaram & Barachant (2018).
FBCSP
Filter-Bank CSP with configurable frequency bands (default: 6 bands from 8–32 Hz). CSP applied per band with features concatenated. Based on Ang et al. (2012).
TS+LDA / TS+SVM
Riemannian Tangent Space approach using OAS covariance estimation and pyriemann’s TangentSpace projection. Top-performing family in MOABB motor imagery benchmarks, based on Barachant et al. (2013).
Live Dashboard
| Area | Purpose |
|---|---|
| Train & Load | Build and fit the model without freezing the GUI |
| Live Feed | Pseudo-online trial countdown and prediction state |
| Confidence Bar | LEFT vs RIGHT class probability |
| Band Power | Relative mu and beta power for the current trial |
| Trial History | Recent hits/misses and cumulative accuracy line |
| Confusion Matrix | Running class-level performance |
Tech Stack
Python 3.9+, MOABB, pyriemann, MNE-Python, scikit-learn, tkinter, matplotlib.