preprint Open access

MEEGNet: An open source python library for the application of convolutional neural networks to MEG

  • bioRxiv (Cold Spring Harbor Laboratory)
  • Cold Spring Harbor Laboratory
Research footprint

At a glance

Citations
1
References
31
Comments
0
Paper overview

Abstract

Abstract Artificial Neural Networks (ANNs) are rapidly gaining traction in neuroscience, proving invaluable for decoding and modeling brain signals from techniques such as electroencephalography (EEG) and functional magnetic resonance imaging (fMRI). Although these networks are beginning to find applications in magnetoencephalography (MEG), their use in this domain is still in the early stages. Here, we introduces MEEGNet, a novel Python library paired with an intuitive convolutional neural network (CNN) architecture designed primarily for MEG data, yet adaptable to EEG signals. The MEEGNet model was trained and cross-validated using MEG data from 643 participants across four classification tasks, including auditory and visual stimulus classification and age prediction. Our model achieves competitive performance across all tasks, with a notable balance of accuracy and efficiency—for instance, reaching 92.70% test accuracy in an auditory vs. visual classification task while maintaining shorter training times than other architectures. The MEEGNet pipeline also integrates latent space visualization tools, adapted for MEG and EEG data. These include saliency maps and Grad-CAM methods, which enhance the interpretability of ANN-based classification and help address the black-box critique of such models. Importantly, the MEEGNet library is designed for extensibility, allowing the neuroscience and machine learning communities to add functionalities and ANN models. By prioritizing usability, transparency, and interpretability, MEEGNet empowers MEG- and EEG-based research with a user-friendly and modular framework.

Record transparency

Publication details

DOI
10.1101/2025.03.20.644276
OpenAlex
W4408802802
Document type
preprint
Language
EN
Source
bioRxiv (Cold Spring Harbor Laboratory)
Last metadata update
Community

Comments

Log in to join the discussion.

  1. No comments yet. Start the discussion.