Feature Extraction
Safetensors
braindecode
eeg
foundation-model
adammnrr commited on
Commit
10cd774
·
verified ·
1 Parent(s): f8246d9

Re-host ZUNA encoder weights (bit-identical mirror of Zyphra/ZUNA, apache-2.0)

Browse files
Files changed (3) hide show
  1. README.md +51 -0
  2. config.json +25 -0
  3. model.safetensors +3 -0
README.md ADDED
@@ -0,0 +1,51 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ library_name: braindecode
4
+ tags:
5
+ - eeg
6
+ - foundation-model
7
+ - braindecode
8
+ pipeline_tag: feature-extraction
9
+ ---
10
+
11
+ # ZUNA (braindecode re-host)
12
+
13
+ Faithful re-host of the **ZUNA** EEG foundation-model encoder weights for use with
14
+ [braindecode](https://github.com/braindecode/braindecode).
15
+
16
+ - **Original model:** [`Zyphra/ZUNA`](https://huggingface.co/Zyphra/ZUNA)
17
+ - **Original code:** https://github.com/Zyphra/zuna
18
+ - **Paper:** Warner, C., Mago, J., Huml, J.R., Osman, M. and Millidge, B. (2026).
19
+ *ZUNA: Flexible EEG Superresolution with Position-Aware Diffusion Autoencoders.*
20
+ arXiv:2602.18478
21
+ - **Original authors (Zyphra):** Chris Warner, Jonas Mago, Jon Huml, et al.
22
+ - **License:** Apache-2.0 (inherited from the upstream release)
23
+
24
+ ## Why this re-host
25
+
26
+ The braindecode `ZUNA` port loads these weights through
27
+ `ZUNA.from_pretrained(...)`. Re-hosting under the `braindecode` org gives a
28
+ stable, permanent location that the library can point to by default, so the
29
+ integration does not depend on the upstream repository staying unchanged. The
30
+ weights file is **bit-identical** to the upstream checkpoint (same SHA-256);
31
+ only the filename is normalised to the standard `model.safetensors`.
32
+
33
+ ## What is (and is not) pretrained
34
+
35
+ These are the pretrained **encoder** weights (a position-aware diffusion
36
+ autoencoder trained for EEG superresolution). The braindecode wrapper adds a
37
+ **classification head that is randomly initialised** and must be fine-tuned on
38
+ your downstream task — loading these weights alone does not give a trained
39
+ classifier.
40
+
41
+ ## Usage
42
+
43
+ ```python
44
+ from braindecode.models import ZUNA
45
+
46
+ # Defaults to this repo (braindecode/ZUNA); n_chans / n_outputs are montage-
47
+ # and task-dependent and must be supplied.
48
+ model = ZUNA.from_pretrained(n_chans=19, n_outputs=4)
49
+
50
+ # Inputs are 5 s EEG windows sampled at 256 Hz (n_times = 1280).
51
+ ```
config.json ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "model": {
3
+ "dim": 1024,
4
+ "n_layers": 16,
5
+ "head_dim": 64,
6
+ "seqlen_t": false,
7
+ "huber_c": null,
8
+ "input_dim": 32,
9
+ "encoder_input_dim": 32,
10
+ "encoder_output_dim": 32,
11
+ "encoder_latent_downsample_factor": 1,
12
+ "encoder_sliding_window": 65536,
13
+ "sliding_window": 65536,
14
+ "xattn_sliding_window": 65536,
15
+ "max_seqlen": 50,
16
+ "adaptive_loss_weighting": true,
17
+ "num_fine_time_pts": 32,
18
+ "rope_dim": 4,
19
+ "rope_theta": 10000.0,
20
+ "tok_idx_type": "{x,y,z,tc}",
21
+ "dont_noise_chan_xyz": false,
22
+ "stft_global_sigma": 0.1,
23
+ "dropout_type": "zeros"
24
+ }
25
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:31e68d142c142f1c99fe05125ee01a00e075835b8ec3fc0c983e29c929011a28
3
+ size 1528134925