You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Proposal: record pretraining corpora for foundation models and add a "held-out evaluation" check #1492
I contributed #1033, #1034 and #1037, and I have been using the foundation models in braindecode for subject-independent evaluation. While doing that I ran into a problem that I think the library can help users avoid.
Several pretrained EEG models in braindecode were pretrained on datasets that are also standard downstream benchmarks. LaBraM, for example, lists both PhysioNet Motor Imagery and the Siena Scalp EEG Database in its pretraining corpus. A user who fine-tunes InterpolatedLaBraM on either dataset and reports "unseen subjects" is in fact testing on subjects whose unlabeled EEG the encoder has already seen. In my own runs, the motor-imagery advantage of LaBraM over EEGNet shrank from 24 to 13.5 points when I moved from PhysioNet to a dataset outside its corpus (Cho2017), and the seizure-detection advantage largely disappeared from Siena to CHB-MIT. Report and code: https://doi.org/10.5281/zenodo.23423535
Proposal, in two small steps:
Metadata. Add a pretraining_datasets attribute (dataset names plus source) to each pretrained model class or to its Hugging Face card, filled from each paper's appendix. I have already compiled these lists, with page-cited quotes, for 20 EEG foundation models (142 reported results): https://github.com/YihengLi-1/eeg-motor-imagery-decoding/blob/main/docs/pretraining_overlap_eeg_fm.md. In that table, 33 results use a dataset that is in, or is a sub-corpus of, the model's own pretraining data (mostly TUAB/TUEV/TUSL/TUAR as subsets of TUEG), and only 4 of those report a re-pretraining control. I can open the PR.
Check helper. A small utility, for example braindecode.util.check_pretraining_overlap(model, dataset), that warns when a MOABB or BIDS dataset being used for evaluation appears in the model's pretraining corpus, so users can label results as in-corpus or held-out.
I am happy to implement both, add tests and docs, and maintain the metadata as new models are added. Would this be welcome, and is there a preferred place for this kind of model metadata?
Activity
ENH record foundation-model pretraining corpora and add check_pretrai…
bruAristimunha commentedon Oct 29, 2026
It is mostly to evolve the model cards, right?
I'm just wondering if I can adapt something closer to Hugging Face here.
YihengLi-1 commentedon Oct 31, 2026
Yes, mostly evolving the model cards. I wrote up what the other libraries do and a three-step proposal on the PR: #1493.
ENH record foundation-model pretraining corpora and add check_pretrai…