BufferGraph is an innovative model to adjust message passing of possible majority-minority edge in the graph, meticulously crafted to address the class-imbalanced node classification tasks. The overview of the model is shown in following figure.
This code repository consists of several folders:
model: BufferGraph code.ablation study: Ablation study code of BufferGraph: deduct distance loss; deduct original graph; deduct updating message passing.
We list main requirements of this repository below. For full requirements, please refer to the provided environment.yml file
- dgl==1.1.0
- torch==2.0.0+cu117
- torch-cluster==1.6.1+pt20cu117
- torch-geometric==2.3.0
- torch-scatter==2.1.1+pt20cu117
- torch-sparse==0.6.17+pt20cu117
- torch-spline-conv==1.2.2+pt20cu117
- torchaudio==2.0.1+cu117
- torchmetrics==0.11.4
- torchvision==0.15.1+cu117
- transformers==4.30.2
For example, if you want to run BufferGraph code on the dataset Amazon-Computers, go to the model folder first, then run the following commands:
```
python pre_train.py --dataset="amazoncomputers"
python buffgraph.py --dataset="amazoncomputers"
```
This dataset is under license CC BY-SA 4.0.
