Add architecture-only model card
Browse files
README.md
ADDED
|
@@ -0,0 +1,96 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: bsd-3-clause
|
| 3 |
+
library_name: braindecode
|
| 4 |
+
pipeline_tag: feature-extraction
|
| 5 |
+
tags:
|
| 6 |
+
- eeg
|
| 7 |
+
- biosignal
|
| 8 |
+
- pytorch
|
| 9 |
+
- neuroscience
|
| 10 |
+
- braindecode
|
| 11 |
+
|
| 12 |
+
---
|
| 13 |
+
|
| 14 |
+
# EEGNetv4
|
| 15 |
+
|
| 16 |
+
Deprecated alias for EEGNet.
|
| 17 |
+
|
| 18 |
+
> **Architecture-only repository.** This repo documents the
|
| 19 |
+
> `braindecode.models.EEGNetv4` class. **No pretrained weights are
|
| 20 |
+
> distributed here** — instantiate the model and train it on your own
|
| 21 |
+
> data, or fine-tune from a published foundation-model checkpoint
|
| 22 |
+
> separately.
|
| 23 |
+
|
| 24 |
+
## Quick start
|
| 25 |
+
|
| 26 |
+
```bash
|
| 27 |
+
pip install braindecode
|
| 28 |
+
```
|
| 29 |
+
|
| 30 |
+
```python
|
| 31 |
+
from braindecode.models import EEGNetv4
|
| 32 |
+
|
| 33 |
+
model = EEGNetv4(
|
| 34 |
+
n_chans=22,
|
| 35 |
+
sfreq=250,
|
| 36 |
+
input_window_seconds=4.0,
|
| 37 |
+
n_outputs=4,
|
| 38 |
+
)
|
| 39 |
+
```
|
| 40 |
+
|
| 41 |
+
The signal-shape arguments above are example defaults — adjust them
|
| 42 |
+
to match your recording.
|
| 43 |
+
|
| 44 |
+
## Documentation
|
| 45 |
+
|
| 46 |
+
- Full API reference (parameters, references, architecture figure):
|
| 47 |
+
<https://braindecode.org/stable/generated/braindecode.models.EEGNetv4.html>
|
| 48 |
+
- Interactive browser with live instantiation:
|
| 49 |
+
<https://huggingface.co/spaces/braindecode/model-explorer>
|
| 50 |
+
- Source on GitHub: <https://github.com/braindecode/braindecode/blob/master/braindecode/models/eegnet.py#L353>
|
| 51 |
+
|
| 52 |
+
## Architecture description
|
| 53 |
+
|
| 54 |
+
The block below is the rendered class docstring (parameters,
|
| 55 |
+
references, architecture figure where available).
|
| 56 |
+
|
| 57 |
+
<div class='bd-doc'><main>
|
| 58 |
+
<p>Deprecated alias for EEGNet.</p>
|
| 59 |
+
<blockquote>
|
| 60 |
+
<p class="rubric">Hugging Face Hub integration</p>
|
| 61 |
+
<p>When the optional <span class="docutils literal">huggingface_hub</span> package is installed, all models
|
| 62 |
+
automatically gain the ability to be pushed to and loaded from the
|
| 63 |
+
Hugging Face Hub. Install with:</p>
|
| 64 |
+
<pre class="literal-block">pip install braindecode[hub]</pre>
|
| 65 |
+
<p><strong>Pushing a model to the Hub:</strong></p>
|
| 66 |
+
<p><strong>Loading a model from the Hub:</strong></p>
|
| 67 |
+
<p><strong>Extracting features and replacing the head:</strong></p>
|
| 68 |
+
<p><strong>Saving and restoring full configuration:</strong></p>
|
| 69 |
+
<p>All model parameters (both EEG-specific and model-specific such as
|
| 70 |
+
dropout rates, activation functions, number of filters) are automatically
|
| 71 |
+
saved to the Hub and restored when loading.</p>
|
| 72 |
+
<p>See :ref:`load-pretrained-models` for a complete tutorial.</p>
|
| 73 |
+
</blockquote>
|
| 74 |
+
</main>
|
| 75 |
+
</div>
|
| 76 |
+
|
| 77 |
+
## Citation
|
| 78 |
+
|
| 79 |
+
Please cite both the original paper for this architecture (see the
|
| 80 |
+
*References* section above) and braindecode:
|
| 81 |
+
|
| 82 |
+
```bibtex
|
| 83 |
+
@article{aristimunha2025braindecode,
|
| 84 |
+
title = {Braindecode: a deep learning library for raw electrophysiological data},
|
| 85 |
+
author = {Aristimunha, Bruno and others},
|
| 86 |
+
journal = {Zenodo},
|
| 87 |
+
year = {2025},
|
| 88 |
+
doi = {10.5281/zenodo.17699192},
|
| 89 |
+
}
|
| 90 |
+
```
|
| 91 |
+
|
| 92 |
+
## License
|
| 93 |
+
|
| 94 |
+
BSD-3-Clause for the model code (matching braindecode).
|
| 95 |
+
Pretraining-derived weights, if you fine-tune from a checkpoint,
|
| 96 |
+
inherit the licence of that checkpoint and its training corpus.
|