Main package requirements:
CUDA == 12.1Python == 3.8.12PyTorch == 2.3.1PyTorch-Geometric == 2.6.1
To install the complete requiring packages, use the following command at the root directory of the repository:
pip install -r requirements.txt
To train TGT, run the following command in the directory ./scripts:
python main.py --mode=train --use_cfg=1 --attack=<attack_mode> --distribution=<dis_name> --dataset=<dataset_name>
To evaluate TGT with trained models, run the following command in the directory ./scripts:
python main.py --mode=eval --use_cfg=1 --attack=<attack_mode> --distribution=<dis_name> --dataset=<dataset_name>
Please put the trained model in the directory ./saved_model. We have already provided the pre-trained models for all settings. Note that, the model under evasive adversarial attacks is trained on the clean dataset and tested on the evasive attacked data, so the pre-trained model parameters are the same as models trained on the clean datasets in ./saved_model/original_evasive.
We have already provided experiment logs in the directory ./logs/history.