Lightweight Transformer for EEG Classification via Balanced Signed Graph Algorithm Unrolling
Junyi Yao, Parham Eftekhar, Gene Cheung, Xujin Chris Liu, Yao Wang, Wei Hu
TL;DR
This work tackles EEG-based epilepsy classification by constructing a lightweight, interpretable transformer-like network through algorithm unrolling of a denoising process on balanced signed graphs. By mapping balanced signed graphs to corresponding positive graphs and learning a data-driven low-pass cutoff via Lanczos approximation, the model achieves competitive accuracy with orders-of-magnitude fewer parameters than conventional transformers. The approach uses two class-specific denoisers to capture posterior statistics, with classification driven by reconstruction errors, and a graph-learning module that functions as a compact self-attention mechanism. Experiments on the Turkish Epilepsy EEG Dataset demonstrate strong performance in both standard and leave-one-subject-out settings, with substantial gains in efficiency and robustness, highlighting practical potential for resource-constrained EEG devices.
Abstract
Samples of brain signals collected by EEG sensors have inherent anti-correlations that are well modeled by negative edges in a finite graph. To differentiate epilepsy patients from healthy subjects using collected EEG signals, we build lightweight and interpretable transformer-like neural nets by unrolling a spectral denoising algorithm for signals on a balanced signed graph -- graph with no cycles of odd number of negative edges. A balanced signed graph has well-defined frequencies that map to a corresponding positive graph via similarity transform of the graph Laplacian matrices. We implement an ideal low-pass filter efficiently on the mapped positive graph via Lanczos approximation, where the optimal cutoff frequency is learned from data. Given that two balanced signed graph denoisers learn posterior probabilities of two different signal classes during training, we evaluate their reconstruction errors for binary classification of EEG signals. Experiments show that our method achieves classification performance comparable to representative deep learning schemes, while employing dramatically fewer parameters.
