Skip to content
Zohix1Public

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

ATDGCN

跑TSception模型的时候,参数为:

    parser.add_argument('--input-shape', type=tuple, default=(1, 28, 512))
    parser.add_argument('--model', type=str, default='TSception', choices=['LGGNet', 'ATDCGN', 'EEGNet', 'DeepConvNet', 'ShallowConvNet', 'EEGTCNet', 'MBEEG_SENet', 'EEGNetClassifier', 'TSception'])
    parser.add_argument('--T', type=int, default=15)
    parser.add_argument('--graph-type', type=str, default='TS', choices=['fro', 'gen', 'hem', 'BL', 'TS'])
conda create --name ATGCN python=3.8

Activate the virtual environment by:

conda activate ATGCN

Install the requirements by:

pip3 install -r requirements.txt

Run the code

Please download the DEAP dataset at this website. Please place the "data_preprocessed_python" folder in the same location as the script. To run the code for the emotion (valence) classification, please type the following command in the terminal:

python3 main.py --data-path '/Users/xiaominghao/code/EEG-Music/eeg/' --label-type 'V' --graph-type 'gen'

To run the code for preference (liking) classification, please type the following command in the terminal:

python3 main.py --data-path './Users/xiaominghao/code/EEG-Music/deap_format/' --label-type 'L' --graph-type 'hem'

The results will be saved into "result_DEAP.txt" located at './save/result/'.

Reproduce the results

We highly suggest running the code on a Ubuntu 18.04 or above machine using anaconda with the provided requirements to reproduce the results. You can also download the saved model at this website to reproduce the results in the paper. After extracting the downloaded "save.zip", please place it at the same location as the scripts, and run the code by:

python3 main.py --data-path './data_preprocessed_python/' --label-type 'V' --graph-type 'gen' --reproduce

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages