1 SPD-DANN
SPD-DANN is a single-source unsupervised domain-adversarial network that extracts manifold-valued EEG features and aligns their marginal and class-conditional distributions with Log-Euclidean losses.
Ref: @SPDDANNSPDManifold
Code not available.
Overview
SPD-DANN uses labeled trials from one source subject and unlabeled data from one target subject. It combines a gradient-reversal domain discriminator with explicit alignment of SPD feature means and pseudo-labeled class prototypes.
Datasets:
- BCI Competition IV Dataset 2a: 9 subjects, 22 EEG + 3 EOG channels, 250 Hz, four classes, two sessions, 72 trials/class/session.
- BCI Competition IV Dataset 2b: 9 subjects, 3 EEG + 3 EOG channels, 250 Hz, binary MI, five sessions; the first 120 trials of each session selected.
- BCI Competition III Dataset IIIa: 3 subjects, 60 channels, 250 Hz, four classes; 40 trials per experiment, imagery 3-7 s.
- BCI Competition III Dataset IVa: 5 subjects, 118 channels, 1,000 Hz, binary right-hand vs right-foot MI, 280 trials per subject, imbalanced classes.
Preprocessing: downsample all datasets to 128 Hz; remove irrelevant channels (incl. EOG); band-pass 8-32 Hz; retain 3 s after cue onset for 2a, 4 s for 2b and IIIa, and the first 3 s for IVa.
Protocol: every ordered source-target subject pair is evaluated for cross-subject transfer. For 2a, target session 1 is available for unsupervised adaptation/training and session 2 for testing; for 2b, target sessions 1-3 for adaptation/training and 4-5 for testing; IIIa and IVa are randomly divided into training and test sets “in proportion” (proportion not reported). No target labels are used for training, although confident target pseudo-labels are used by the prototype loss.
Architecture
The feature extractor is
EEG → convolution → batch normalization → split into n temporal/feature parts → covariance → trace normalization → manifold attention → ReEig.
For each part , the covariance is transformed into
The manifold attention module uses three BiMap transformations to construct SPD queries, keys, and values. Attention-weighted values are aggregated with a Log-Euclidean mean; ReEig then rectifies the resulting SPD representation.
Two heads receive this feature:
- Class head: LogEig → Euclidean layers → source-class prediction.
- Domain head: gradient reversal → LogEig → a deeper Euclidean network → source/target prediction.
The class loss and binary domain loss are
SPD Domain Feature Alignment
For source features and target features , compute Log-Euclidean means
and the alignment loss
SPD Class Prototype Pair Loss
Source prototype for class :
Target pseudo-label confidence is measured by entropy ; only the 50% of target samples with lowest entropy are retained. With Log-Euclidean distance , the margin loss is
with .
The full objective is
where follows the dynamic DANN schedule and is added with unit weight.
Model Parameters
- Covariance regularizer: .
- Covariance scale normalization: divide by trace.
- Target pseudo-label retention: 50% lowest-entropy predictions.
- Prototype margin: .
- Prototype-loss weight at the reported optimum: (sensitivity tested in
{0, 0.01, 0.02, 0.05, 0.1, 0.15, 0.2}). - Number of convolution filters, temporal parts, BiMap output dimensions, ReEig threshold, and classifier/discriminator layer widths: not reported.
Training Parameters
- Framework: PyTorch.
- Optimizer: Riemannian Adam.
- Learning rate: .
- Weight decay: .
- Batch size: 32.
- Classification loss: source cross-entropy; domain loss: binary cross-entropy optimized adversarially through gradient reversal.
- : dynamically updated according to the cited DANN strategy.
- Epochs, early stopping, LR schedule, random-seed count, and hardware: not reported.
Results
Cross-subject accuracy (%). BCIC-IV-2a:
| Method | A1 | A2 | A3 | A4 | A5 | A6 | A7 | A8 | A9 | Avg |
|---|---|---|---|---|---|---|---|---|---|---|
| DALN | 40.4 | 25.0 | 40.1 | 39.4 | 28.9 | 36.5 | 38.4 | 35.4 | 32.6 | 35.2 |
| DANN | 39.5 | 24.6 | 37.2 | 38.5 | 26.9 | 35.0 | 36.7 | 32.2 | 30.4 | 33.4 |
| MCD | 43.4 | 30.7 | 43.4 | 41.9 | 32.9 | 38.6 | 39.8 | 38.1 | 36.2 | 38.3 |
| JDD | 43.0 | 26.8 | 45.1 | 43.0 | 29.0 | 36.9 | 40.7 | 39.0 | 39.5 | 38.1 |
| SPD-DANN | 49.7 | 38.5 | 50.5 | 44.5 | 41.5 | 45.4 | 43.5 | 46.5 | 44.2 | 44.9 |
SPD-DANN exceeds MCD by 6.6 pp and DANN by 11.5 pp.
BCIC-IV-2b:
| Method | B1 | B2 | B3 | B4 | B5 | B6 | B7 | B8 | B9 | Avg |
|---|---|---|---|---|---|---|---|---|---|---|
| DALN | 69.9 | 50.9 | 67.8 | 61.9 | 66.9 | 69.8 | 68.3 | 66.9 | 65.8 | 65.3 |
| DDAN | 71.8 | 59.0 | 66.3 | 65.2 | 66.2 | 71.9 | 69.0 | 66.3 | 70.5 | 67.4 |
| DANN | 64.6 | 60.7 | 58.3 | 60.9 | 63.3 | 64.8 | 69.9 | 59.5 | 64.2 | 62.9 |
| JDD | 70.7 | 50.8 | 61.9 | 64.7 | 69.4 | 71.0 | 70.7 | 66.6 | 66.8 | 65.8 |
| SPD-DANN | 78.5 | 77.0 | 75.4 | 76.2 | 74.6 | 77.6 | 77.5 | 73.9 | 77.7 | 76.5 |
BCIC-III IIIa:
| Method | K3b | K6b | L1b | Avg |
|---|---|---|---|---|
| DALN | 33.6 | 37.5 | 37.8 | 36.3 |
| MCD | 38.2 | 40.6 | 39.8 | 39.5 |
| JDD | 38.8 | 40.3 | 39.2 | 39.4 |
| SPD-DANN | 41.6 | 55.9 | 50.7 | 49.4 |
BCIC-III IVa:
| Method | aa | al | av | aw | ay | Avg |
|---|---|---|---|---|---|---|
| DDAN | 66.7 | 67.5 | 63.6 | 65.5 | 61.6 | 65.0 |
| JDD | 67.9 | 67.2 | 65.2 | 67.2 | 66.2 | 66.7 |
| SPD-DANN | 72.1 | 76.7 | 69.9 | 81.3 | 73.9 | 74.7 |
Ablation on 2a: without both losses 39.8; only 41.7; only 42.4; full 44.9. Removing reduces accuracy by 3.2 points; removing by 2.5 points.
Notes
- The random train/test proportion for IIIa and IVa is not specified.