Skip to content

SukwonYun/S-Mixup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

S-Mixup: Structural Mixup for Graph Neural Networks

The official source code for "S-Mixup: Structural Mixup for Graph Neural Networks", accepted at CIKM 2023 (Short Paper).

Overview

Existing studies for applying the mixup technique on graphs mainly focus on graph classification tasks, while the research in node classification is still under-explored. In this paper, we propose a novel mixup augmentation for node classification called Structural Mixup (S-Mixup). The core idea is to take into account the structural information while mixing nodes. Specifically, S-Mixup obtains pseudo-labels for unlabeled nodes in a graph along with their prediction confidence via a Graph Neural Network (GNN) classifier. These serve as the criteria for the composition of the mixup pool for both inter and intra-class mixups. Furthermore, we utilize the edge gradient obtained from the GNN training and propose a gradient-based edge selection strategy for selecting edges to be attached to the nodes generated by the mixup. Through extensive experiments on real-world benchmark datasets, we demonstrate the effectiveness of S-Mixup evaluated on the node classification task. We observe that S-Mixup enhances the robustness and generalization performance of GNNs, especially in heterophilous situations.

Requirements

  • python version: 3.7.11
  • numpy version: 1.19.2
  • pytorch version: 1.8.0
  • torch-geometric version: 2.0.1

How to run

Following Options can be passed to main.py

--dataset: Name of the dataset. cora, citeseer, pubmed, cs, physics are available.
usage example: --dataset cora

--target_ratio: Determine upper and lower $r$% for high and low-confidence node mixup pool.
usage example: --target_ratio 0.3

--edge_ratio: Determine top $m$% of edge gradeint values.
usage example: --edge_ratio 0.1

--eta: Controls loss between inter-class and intra-class node mixup.
usage example: --eta 0.5

--mixup_start: Determine when mixup starts.
usage example: --mixup_start 30

Example

python main.py --dataset cora --target_ratio 0.3 --edge_ratio 0.1 --eta 0.5 --mixup_start 30

Cite (Bibtex)

  • If you find S-Mixup useful in your research, please cite the following paper:
    • Junghurn Kim, Sukwon Yun, and Chanyoung Park. "S-Mixup: Structural Mixup for Graph Neural Networks." CIKM 2023.
    • Bibtex
@article{s-mixup,
  title={S-Mixup: Structural Mixup for Graph Neural Networks},
  author={Kim, Junghurn and Yun, Sukwon and Park, Chanyoung},
  journal={arXiv preprint arXiv:2308.08097},
  year={2023}
}

About

The official source code for "S-Mixup: Structural Mixup for Graph Neural Networks", accepted at CIKM 2023 (Short Paper).

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages