Deep Recurrent Encoder: an end-to-end network to model magnetoencephalography at scale

Omar Chehab, Alexandre Défossez, Jean-Christophe Loiseau, Alexandre Gramfort, Jean-Rémi King

TL;DR

This paper introduces the Deep Recurrent Encoder (DRE), a novel end-to-end deep learning model that significantly improves the prediction of brain activity from MEG data. By effectively modeling complex neural dynamics, inter-subject variability, and the relationship between stimuli and brain responses, DRE offers a three-fold improvement over traditional linear methods.

What Problem Does This Paper Address?

Understanding how the brain responds to sensory input is a fundamental goal in neuroscience. However, analyzing non-invasive brain recordings like Magnetoencephalography (MEG) presents significant challenges:

  • High-dimensional and complex dynamics: Neuronal activity is incredibly intricate and difficult to model.
  • Variability across subjects and trials: Brain signals can differ substantially between individuals and even within the same individual across different attempts.
  • Non-trivial stimulus-response relationships: The connection between what a person experiences (e.g., a word) and their brain's reaction isn't always straightforward.

Existing methods often tackle these challenges in isolation using linear models. This paper aims to address all three simultaneously with a unified deep learning approach.

Methods

The core of this work is the Deep Recurrent Encoder (DRE), a novel end-to-end deep learning architecture. Key aspects of the DRE include:

  • Long Short-Term Memory (LSTM) layers: These are used to model the complex, nonlinear, and non-stationary dynamics of brain activity. LSTMs are well-suited for sequential data and can capture long-range dependencies.
  • Convolutional Auto-encoder: This component is used for processing the MEG data, enabling efficient feature extraction and dimensionality reduction. It also contributes to computational efficiency by reducing the number of time steps the LSTM needs to process.
  • Subject Embeddings: A dedicated layer is introduced to learn a representation for each subject. This allows the model to capture and leverage inter-individual variability, effectively "re-aligning" brain responses across subjects.
  • Augmented Control Input: The model's input is enhanced with information about the current stimulus, the subject's embedding, and a mask indicating the presence of a stimulus, allowing it to better adapt to different conditions.

The DRE is trained to predict MEG responses by taking into account past brain activity and current experimental conditions.

Datasets

The study utilizes the Mother Of Unification Studies (MOUS) dataset. This dataset consists of:

  • 99 subjects performing a one-hour reading task.
  • MEG recordings from a 273-channel CTF MEG scanner.
  • Approximately 2,700 words presented sequentially.
  • Stimuli included both random word lists and actual sentences.

The data was preprocessed and segmented into trials, with 70% used for training, 10% for validation, and 20% for testing.

Key Insights and Ideas

  • Deep learning excels at complex neural dynamics: The DRE's ability to outperform linear models by a significant margin highlights the power of deep learning in capturing the intricate, nonlinear, and time-varying nature of brain signals.
  • Subject embeddings are crucial for inter-individual variability: Explicitly modeling subject-specific information allows the DRE to generalize better across individuals, a significant challenge in neuroscience.
  • Recurrence captures subtle brain modulations: The recurrent nature of the DRE, particularly its ability to leverage pre-stimulus brain activity, allows it to capture phenomena like alpha-band modulations that linear models miss.
  • Interpretability is achievable with deep models: Despite being a "black-box" deep learning model, the DRE's predictions can be analyzed using feature importance techniques, revealing meaningful relationships between stimuli and brain responses, consistent with prior neuroscience findings.

Key Results

  • Three-fold improvement in prediction: The DRE achieved a three-fold improvement in predicting MEG responses compared to classic linear methods (TRF and RTRF).
  • Significant performance gains: The DRE achieved a mean correlation score (R) of 0.20 ± 0.003, significantly outperforming RTRF (R=0.10 ± 0.003) and TRF (R=0.064 ± 0.002).
  • Effective capture of inter-trial variability: The DRE, by incorporating pre-stimulus MEG activity, showed a significant performance increment (AR = 0.12) compared to a DRE without this initialization.
  • Alpha-dependent responses captured: The DRE successfully modeled the modulation of brain responses based on pre-stimulus alpha power, a phenomenon not captured by linear models.
  • Feature importance aligns with neuroscience: Permutation importance analysis confirmed that word length and word frequency influenced brain responses in expected temporal and spatial patterns, consistent with existing literature.

Limitations and Future Work

  • Focus on "evoked" activity: The current loss functions (MSE) primarily train the models to predict "evoked" activity, which is phase-locked to stimuli. The paper notes that capturing "induced" activity (e.g., non-phase-locked oscillations) would require different loss functions.
  • Computational cost: While the DRE is efficient, training deep models on large MEG datasets can still be computationally intensive. The use of convolutional layers was motivated by computational efficiency.
  • Future directions: The authors suggest combining rich stimulus representations (e.g., from pre-trained deep networks) with the DRE's dynamical modeling capabilities to further enhance prediction accuracy. They also note that probabilistic models like Gaussian Processes could offer uncertainty quantification, which might be beneficial for forecasting scenarios, especially at later time points.

Summary updated

BibTeX
@inproceedings{chehab2022deep,
  author = {Omar Chehab and Alexandre Défossez and Jean-Christophe Loiseau and Alexandre Gramfort and Jean-Rémi King},
  title = {{Deep Recurrent Encoder: an end-to-end network to model magnetoencephalography at scale}},
  booktitle = {Neurons},
  year = {2022},
  doi = {10.51628/001c.38668},
}
Figure