The repository contains the implementation of "Domain Generalization for Zero-calibration BCIs with Knowledge Distillation-based Phase Invariant Feature Extraction".
This is a demo of the proposed Knife.
alg/algs/Knife.py contains the core code of the proposed method, which includes the realization of knowledge distillation framework, Correlation alignment, and spectrum transfer. The graphical abstract is shown below:
Python: 3.7.11
PyTorch: 1.10.0
Torchvision: 0.11.1
CUDA: 10.2
CUDNN: 7605
NumPy: 1.21.2
PIL: 6.2.1
pip install -r requirements.txt
python train_OpenBMI.py
A demo to run Knife on OpenBMI dataset.
Please request data from the above link.
An example dataset used for train_OpenBMI.py: OpenBMI_GoogleDrive
Put the downloaded OpenBMI data into the data/OpenBMI/filterdMat/.
Note: This dataset is for demo purposes only. For further use of the data, please request for authorization from the original source.
Great thanks to deepDG. We extend our method based on this toolkit and have compared and validated our method on it.
To be continued...