/ Модель

Характеристики

Лицензия
CC BY 4.0
Опубликована
27 сен 2026

eeg-fm-masking_mae_r9cm_L8

ЭмбеддингиТекст → embedding3 профессии

Предварительно обученный MAE-энкодер ЭЭГ для извлечения признаков и последующей оценки или дообучения на задачах анализа сигналов мозга.

289скачиваний за 30 дней0лайковвеса обновлены29 сен 2026

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

Это предварительно обученный энкодер ЭЭГ, опубликованный PierreGtch как один из 58 вариантов эксперимента по геометрии маскирования для ЭЭГ-фундаментальных моделей. Модель использует masked autoencoder (MAE): энкодер обрабатывает незамаскированные фрагменты сигнала, а при обучении лёгкий декодер восстанавливает замаскированные участки. В репозитории сохранён только энкодер; декодер MAE не включён. Вариант использует пространственный радиус маски 9 см и временную длину 8 патчей.

Энкодер предназначен для извлечения контекстных признаков ЭЭГ и последующей оценки или дообучения на задачах классификации и регрессии, например в OpenEEGBench. Для входа нужны сигналы с частотой 200 Гц, напряжением в вольтах и трёхмерными координатами каналов; обёртка выполняет масштабирование и нормализацию по окну. Модель допускает разное число и расположение каналов при наличии координат. Обучение выполнено на открыто лицензированной части корпуса REVE из 323 записей в течение 10 эпох. В статье рекомендуются другие варианты маскирования с временной длиной 2 патча, поэтому данный вариант не является рекомендованной конфигурацией авторов. Лицензия — CC BY 4.0.

Сценарии применения

  • извлечение признаков из многоканальных сигналов ЭЭГ
  • подготовка представлений ЭЭГ для классификации состояний или задач
  • оценка моделей ЭЭГ с замороженным энкодером и ridge probe
  • дообучение энкодера на размеченных наборах ЭЭГ
  • регрессия по контекстным признакам ЭЭГ

Ограничения

Требуются сигнал с частотой 200 Гц, значения в вольтах и 3D-координаты для каждого канала; предварительно стандартизировать сигнал не следует, поскольку масштабирование выполняет обёртка. В репозитории нет декодера MAE, а авторы рекомендуют вариант с временной длиной маски 2 патча вместо 8.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

eeg-fm-masking_mae_r9cm_L8

Pretrained EEG encoder from the paper What masking geometry works best for EEG foundation models? (arXiv:2609.33487 · website · code · all 58 models).

It is one of 58 encoders trained under an identical recipe where only the masking geometry changes: 5 spatial radii × 6 temporal lengths × 2 frameworks (the r = all, L = 33 cell, which would mask the whole window, does not exist). This model is a masked autoencoder (MAE): the encoder sees the unmasked patches and a light decoder reconstructs the raw signal of the masked patches.

FrameworkMAE
Mask spatial radius r9 cm
Mask temporal length L8 patches
Masker parameter pct_unmasked0.45
Checkpointend of epoch 10 of 10 (the one evaluated in the paper); epochs 1–9 in epoch_01/ … epoch_09/
Encoder parameters12.69 M
Training runz8paagta

The paper recommends r = 9 cm, L = 2: see eeg-fm-masking_mae_r9cm_L2 and eeg-fm-masking_jepa_r9cm_L2.

What is in this repo

  • model.safetensors: the encoder only (patch tokeniser feature_encoder.* + transformer model.*), i.e. exactly the tensors loaded for the downstream evaluation of the paper. The MAE decoder is not included; for JEPA the published weights are the student encoder, as evaluated in the paper.
  • epoch_01/ … epoch_09/: model.safetensors of the intermediate checkpoints (end of epochs 1 to 9 of the same run), with the same tensors and key names; they use the same config.json.
  • config.json: the keyword arguments of ContextualEncoderBenchmarkWrapper (architecture + input scaling). Pass it unchanged as model_kwargs.
  • metadata.json: masking parameters, training-run id, checkpoint epoch/step.

Input requirements

  • Sampling rate: 200 Hz. The signal is cut into 1 s patches (200 samples, 20-sample overlap).
  • Units: volts. The wrapper multiplies by factor = 1e+06 and applies per-window median_std_clip scaling (clip at σ = 15) itself; do not standardise the data beforehand.
  • Channel positions in metres (MNE info["chs"][i]["loc"][:3]). The model is montage-agnostic: any number and set of channels works, as long as every channel has a 3D position.

Usage

Install the code: pip install git+https://github.com/PierreGtch/eeg-fm-masking.

Loading the model

import json
from huggingface_hub import hf_hub_download
from safetensors.torch import load_file
from eeg_fm_masking.oeb.wrapper import ContextualEncoderBenchmarkWrapper

repo = "PierreGtch/eeg-fm-masking_mae_r9cm_L8"
config = json.load(open(hf_hub_download(repo, "config.json")))
model = ContextualEncoderBenchmarkWrapper(
    n_chans=n_chans, n_times=n_times, n_outputs=n_outputs, sfreq=200.0,
    chs_info=chs_info,  # MNE channel info (info["chs"]), positions in metres
    **config,
)
model.load_state_dict(load_file(hf_hub_download(repo, "model.safetensors")), strict=False)

strict=False only leaves out the dataset-dependent parts (channel-position buffer and classification head).

Evaluation / fine-tuning with OpenEEGBench

import json
from huggingface_hub import hf_hub_download
from open_eeg_bench.backbone import PretrainedBackbone

repo = "PierreGtch/eeg-fm-masking_mae_r9cm_L8"
backbone = PretrainedBackbone(
    model_cls="eeg_fm_masking.oeb.wrapper.ContextualEncoderBenchmarkWrapper",
    hub_repo=repo,
    model_kwargs=json.load(open(hf_hub_download(repo, "config.json"))),
)

Intermediate checkpoints (epochs 1–9)

The end-of-epoch checkpoints of the same run are in the subfolders epoch_01/ … epoch_09/ (the final epoch 10 is the model.safetensors at the root). Build model as above, then:

epoch = 5  # 1 to 9
weights = load_file(hf_hub_download(repo, "model.safetensors", subfolder=f"epoch_{epoch:02d}"))
model.load_state_dict(weights, strict=False)

Downstream results (OpenEEGBench, frozen encoder + ridge probe)

Frozen encoder, ridge regression/classification on the flattened contextual features, 12 datasets × 5 seeds. Balanced accuracy for classification, R² for seed-vig.

DatasetMetricScore (mean ± sd)Seeds
arithmetic_zyma2019balanced acc.0.701 ± 0.0115
bcic2020-3balanced acc.0.273 ± 0.0125
bcic2abalanced acc.0.456 ± 0.0075
chbmitbalanced acc.0.882 ± 0.0185
facedbalanced acc.0.317 ± 0.0075
isruc-sleepbalanced acc.0.668 ± 0.0035
mdd_mumtaz2016balanced acc.0.829 ± 0.0205
physionetbalanced acc.0.558 ± 0.0055
seed-vbalanced acc.0.284 ± 0.0015
seed-vigR²-0.180 ± 0.0075
tuabbalanced acc.0.804 ± 0.0035
tuevbalanced acc.0.920 ± 0.0325

Training

  • Data: the openly-licensed subset of the REVE pre-training corpus (323 recordings), so that the weights can be redistributed.
  • Schedule: 10 epochs, 2 × H100, batch size 600 per GPU, learning rate 0.00024 (warm-up 3080 steps, final 1e-06), weight decay 0.01.

License and citation

Weights released under CC-BY-4.0; code under MIT (GitHub). If you use these models, please cite the paper:

@misc{guetschel2026maskinggeometryworksbest,
      title={What masking geometry works best for EEG foundation models?},
      author={Pierre Guetschel and Bruno Aristimunha and Yassine El Ouahidi and Arnaud Delorme and Thomas Moreau and Michael Tangermann},
      year={2026},
      eprint={2609.33487},
      archivePrefix={arXiv},
      primaryClass={cs.LG},
      url={https://arxiv.org/abs/2609.33487},
}

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм

Нельзя запустить

Не удалось определить, чем загружать веса модели (нет library_name и architectures).

Ревизия весов
3f1f420

0 моделей