Neurotheque Resources is a comprehensive, modular toolkit for EEG data processing and analysis. Built on state‐of‐the‐art libraries such as MNE-Python, autoreject it enables:
- Preprocessing & Channel Setup: Automatic bad channel detection and re-referencing with standardized electrode montages.
- Artifact Rejection: Advanced methods like ICA and auto-rejection for high-quality EEG data.
- Task & Trigger Parsing: Flexible logic to merge triggers for tasks like Go/No-Go, finger tapping, or mental imagery.
- Epoching & Analysis: Efficient epoch slicing, ROI averaging, time–frequency transforms, and ERP analyses.
- Report Generation: Automated HTML reporting (via MNE's
Report
) for visual inspection and documentation of analysis results.
This repository is designed for both single-subject and multi-subject pipelines, ensuring reproducibility and scalability.
- Repository Structure
- Installation & Quick Start
- Usage Examples
- Contributors & Acknowledgments
- Contributing
- License
- Contact
-
notebooks/
- tutorials/ – Step-by-step Jupyter notebooks illustrating basic usage and pipeline demos.
- preprocessing/ – Notebooks focusing on data cleaning (filtering, ICA, etc.).
- analysis/ – Notebooks showing advanced analysis tasks (ERP, ROI-based metrics, time–frequency transforms).
-
src/
- pipeline.py – The main pipeline driver, reading YAML configs or Python dicts to run each pipeline step in sequence.
- steps/ – A suite of modular processing steps (e.g.,
LoadData
,FilterStep
,AutoRejectStep
,ICAStep
,SplitTasksStep
,TriggerParsingStep
) that can be combined in various orders. - strategies/ – Specialized scripts/pipelines for different paradigms (e.g., finger tapping, mental imagery).
- utilities/ – Helper scripts like
combine_py_files.py
(for merging .py files) orexport_repo_structure.py
(for generating directory trees).
-
doc/ – Additional documentation, user guides, or methodology reports.
-
configs/ – YAML files detailing pipeline configurations (e.g.,
pilot_preprocessing_strategy.yml
,gonogo_analysis.yml
, etc.).
- Clone the repository:
git clone https://github.com/UNFmontreal/neurotheque_resources.git cd neurotheque_resources
- Install dependencies:
pip install -r requirements.txt
-
Run a Pipeline with a YAML Configuration
python src/pipeline.py --config configs/pilot_preprocessing_strategy.yml
This loads the steps specified in the config (e.g.
LoadData
,FilterStep
,AutoRejectStep
, etc.) and applies them to your EEG data. -
Use a Strategy Script
# Example: Using the finger tapping strategy from src.strategies.finger_tapping_strategy import run_finger_tapping_pipeline input_path = "data/raw/sub-01_ses-001_eeg.edf" output_path = "data/processed/sub-01_ses-001_preprocessed.fif" run_finger_tapping_pipeline(input_path, output_path)
-
Explore the Jupyter Notebooks