DRDCAE-STGNN: An End-to-End Discrimina-tive Autoencoder with Spatio-Temporal Graph Learning for Motor Imagery Classification

Yi Wang, Haodong Zhang, Hongqi Li · DOI

TL;DR

DRDCAE-STGNN is a new end-to-end deep learning framework that achieves state-of-the-art accuracy in classifying motor imagery (MI) from EEG signals. By combining a discriminative autoencoder with a learnable spatio-temporal graph neural network, the model adaptively discovers functional brain connectivity and delivers high-performance decoding fast enough for real-time BCI applications.

What Problem Does This Paper Address?

Brain-Computer Interfaces (BCIs) that rely on Motor Imagery—the mental rehearsal of movement—offer a powerful way for individuals with motor impairments to control assistive devices. However, decoding these intentions from Electroencephalogram (EEG) signals is notoriously difficult.

EEG data is "non-stationary" (it changes over time), has a very low signal-to-noise ratio, and varies significantly between different people and even different sessions for the same person. Traditional machine learning often relies on handcrafted features that fail to capture the complex, dynamic interactions between different brain regions. While recent deep learning models have improved performance, many still use fixed, "hard-coded" graph structures to represent brain connectivity, which limits their ability to adapt to individual neural patterns.

Methods

The authors propose a hybrid architecture called DRDCAE-STGNN, which consists of two primary modules:

  1. Discriminative Residual Dense Convolutional Autoencoder (DRDCAE):
    • Unlike standard autoencoders that only focus on reconstructing the input signal, this module is "discriminative." It uses a joint loss function that optimizes for both signal reconstruction (fidelity) and task classification (utility).
  2. It employs residual-dense connections, which allow for better gradient flow and feature reuse, helping the model learn compact, high-level representations of the raw EEG data.
  3. Spatio-Temporal Graph Neural Network (STGNN):
    • Adaptive Spatial Learning: Instead of using a fixed map of electrode locations, the model uses a learnable adjacency matrix. It starts with a prior (Pearson correlation) and then "learns" the actual functional connectivity between channels during training.
  4. Temporal Modeling: It uses a Bidirectional Long Short-Term Memory (Bi-LSTM) network to capture the time-varying dynamics of the brain signals.
  5. Attention-Based Pooling: An attention mechanism identifies which temporal embeddings are most relevant to the specific motor task, filtering out noise.

Datasets

The model was rigorously tested on three gold-standard public benchmarks:

  • BCI Competition IV 2a: A 4-class dataset (left hand, right hand, feet, tongue) from 9 subjects.
  • BCI Competition IV 2b: A binary-class dataset (left vs. right hand) from 9 subjects.
  • PhysioNet EEG Motor Movement/Imagery Dataset: A large-scale dataset featuring 109 subjects, providing a robust test for generalizability.

Key Insights and Ideas

  • The "Aha" Moment in Connectivity: The most compelling finding is that the model's learnable graph autonomously discovers neurophysiologically meaningful patterns. Post-hoc analysis showed the model strengthened connections between the frontal, central, and parietal regions—aligning perfectly with known sensorimotor networks—without any explicit anatomical instructions.
  • Reconstruction as a Regularizer: By forcing the model to reconstruct the signal while classifying it, the DRDCAE acts as a powerful feature extractor that is less likely to overfit to noise, a common pitfall in EEG analysis.
  • Efficiency vs. Complexity: While the architecture sounds heavy (dense connections + graphs + LSTMs), the authors optimized it to maintain a feasible parameter count (~42K parameters).

Key Results

The DRDCAE-STGNN outperformed several state-of-the-art baselines (including EEGNet and various Transformer-based models) across all datasets:

  • Accuracy: Achieved 95.42% on BCI 2a, 97.51% on BCI 2b, and 90.15% on PhysioNet.
  • Consistency: It showed a significantly lower standard deviation in accuracy across subjects compared to other models, indicating high robustness.
  • Real-time Readiness: The average inference time is just 0.32 ms per sample, which is well below the 100 ms threshold required for real-time BCI interaction.

Limitations and Future Work

Despite the strong results, the authors note a few areas for improvement:

  • Subject Variability: While the model is robust, performance still dipped for certain "difficult" subjects (e.g., subjects S8 and S9 in BCI 2a), suggesting that even adaptive models struggle with extreme physiological differences.
  • Training Overhead: The computational cost during the training phase is relatively high compared to simpler models, which could slow down the process of personalizing a BCI for a new user.
  • Future Directions: The team plans to explore adversarial domain alignment to improve cross-subject generalization and develop more granular explainability tools to pinpoint exactly which frequency bands or time points contribute most to a classification decision.

Summary updated

Abstract

Motor imagery (MI) based brain-computer interfaces (BCIs) hold significant potential for assistive technologies and neurorehabilitation. However, the precise and efficient decoding of MI remains challenging due to their non-stationary nature and low signal-to-noise ratio. This paper introduces a novel end-to-end deep learning framework of Discriminative Residual Dense Convolutional Autoencoder with Spatio-Temporal Graph Neural Network (DRDCAE-STGNN) to enhance the MI feature learning and classification. Specifically, the DRDCAE module leverages residual-dense connections to learn discriminative latent representations through joint reconstruction and classifica-tion, while the STGNN module captures dynamic spatial dependencies via a learnable graph adjacency matrix and models temporal dynamics using bidirectional long short-term memory (LSTM). Extensive evaluations on BCI Competition IV 2a, 2b, and PhysioNet datasets demonstrate state-of-the-art performance, with average accuracies of 95.42%, 97.51%, and 90.15%, respectively. Ablation studies confirm the contribution of each component, and interpreta-bility analysis reveals neurophysiologically meaningful connectivity patterns. Moreover, despite its complexity, the model maintains a feasible parameter count and an inference time of 0.32 ms per sample. These results indicate that our method offers a robust, accurate, and interpretable solution for MI-EEG decoding, with strong generalizability across subjects and tasks and meeting the requirements for potential real-time BCI applications.

Empirical ResultsBrowse all benchmarks →

BenchmarkMethodMetricScoreProtocol / Evidence
BCI IV-2bDRDCAE-STGNNaverage accuracy (Avg Acc)97.51%+4.87 vs baselineMotor Imagery Classification · params=2b · classes=2 · subjects=S1-S9
Source quote
L208: 2025 │ DRDCAE-STGNN │ 98.5 │ 97.5 │ 98.25 │ 95.95 │ 96.43 │ 97.00 │ 98.25 │ 97.50 │ 98.25 │ 97.51 │ 0.90 │ 0.96
PhysioNetDRDCAE-STGNNaverage accuracy95.9%Motor Imagery Classification · classes=2
Source quote
L233: 2025 │ DRDCAE-STGNN │ 95.9 │ 0.958 │ 0.917 │ 0.986 │ 2025 │ DRDCAE-STGNN │ 90.2 │ 0.901 │ 0.936 │ 0.868
PhysioNetDRDCAE-STGNNaverage accuracy90.2%Motor Imagery Classification · classes=4
Source quote
L233: 2025 │ DRDCAE-STGNN │ 95.9 │ 0.958 │ 0.917 │ 0.986 │ 2025 │ DRDCAE-STGNN │ 90.2 │ 0.901 │ 0.936 │ 0.868
Reported baseline / comparator measurements (1)
BenchmarkMethodMetricScoreProtocol / Evidence
BCI IV-2bTrinet baselineaverage accuracy (Avg Acc)92.64%Motor Imagery Classification · params=2b · classes=2 · subjects=S1-S9
Source quote
L206: 2025 │ Trinet \cite{43} │ 93.65 │ 90.43 │ 91.70 │ 95.43 │ 96.09 │ 92.26 │ 90.48 │ 88.67 │ 95.08 │ 92.64** │ 2.57
BibTeX
@misc{wang2025drdcae,
  author = {Yi Wang and Haodong Zhang and Hongqi Li},
  title = {{DRDCAE-STGNN: An End-to-End Discrimina-tive Autoencoder with Spatio-Temporal Graph Learning for Motor Imagery Classification}},
  year = {2025},
  eprint = {2509.05943},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2509.05943},
}
Figure