This repository is the official PyTorch implementation of DAGAD in the following paper:
DAGAD: Data Augmentation for Graph Anomaly Detection, accepted as a regular paper by the 22nd IEEE International Conference on Data Mining (ICDM 2022) [arXiv]
Brief Intro. DAGAD alleviates anomalous sample scarcity
and class imbalance
issues of anomalous node detection with THREE strengths:
- DAGAD employs a data augmentation module to derive additional training samples in the embedding space, which is also extendable to other graph learning tasks that rely on learning features from a very limited number of labeled instances.
- Augmented samples together with original ones are leveraged by two classifiers in a complementary manner, to learn discriminative representations for the anomalous and normal classes.
- DAGAD develops class-wise losses to alleviate the suffering from class imbalance, which can be easily integrated into semi-supervised anomaly detectors.
If you find this work helpful for your research, please cite this paper:
@inproceedings{liu2022DAGAD,
author = {Fanzhen Liu and Xiaoxiao Ma and Jia Wu and Jian Yang and Shan Xue and Amin Behesht and
Chuan Zhou and Hao Peng and Quan Z. Sheng and Charu C. Aggarwal},
title = {DAGAD: Data Augmentation for Graph Anomaly Detection},
booktitle = {ICDM},
year = {2022},
}
-
('--seed', type=int, default=7, help='Random seed.')
-
('--dataset', type=str, default='BlogCatalog', help="['BlogCatalog', 'ACM', 'Flickr'].")
-
('--gnn_layer', type=str, default='GCN', help="['GCN','GAT']")
-
('--epoch_num', type=int, default=200, help='The number of epochs for training.')
-
('--learning_rate', default=0.005, help='Learning rate of the optimizer.')
-
('--weight_decay', default=5e-4, help='Weight decay of the optimizer.')
-
('--gnn_dim', type=int, default=64)
-
('--fcn_dim', type=int, default=32)
-
('--gce_q', default=0.7, help='gce q')
-
('--alpha', type=float, default=1.5)
-
('--beta', type=float, default=0.5)
-
('--gat_heads', default=8, help='GAT heads')
- Run DAGAD-GCN on BlogCatalog:
python main.py --dataset BlogCatalog --gnn_layer GCN
- Run DAGAD-GAT on BlogCatalog:
python main.py --dataset BlogCatalog --gnn_layer GAT