SkyRiver-2000 / EE226-Final-Project

Final assignment of EE226 course in SJTU by Group 12

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

EE226 Final Project

This repository stores the source code and some preprocessed data of Group 12 for the final project of EE226 in SJTU.
For more details please refer to our paper.

Performance

  • 0.51895 mean F1-score (2nd) on private leaderboard of node classification
  • 0.79756 AUC score (2nd) on private leaderboard of link prediction

Note: Combining our SEAL solution with node2vec+lightgbm solution, we achieve 0.81069 on link prediction.

Environment

We use a conda environment with python 3.7.0. Key packages (with necessary dependencies):

  • pytorch 1.8.1
  • torch-geometric 1.7.0
  • lightgbm 3.1.1

Lower version of these packages might also work fine, but we only test with the specified versions above.
Some basic packages like numpy, pandas, scipy, and tqdm are also required, and conda/pip makes things fine.

Node Classification

For task 1 (node classification), just enter the node directory and run the following command to check our results:

mkdir submission # if this directory does not exist
mkdir models # if this directory does not exist
mkdir models/saves # if this directory does not exist
python example.py

Some parameters can be set by passing arguments.
For example, if you want to use GCN rather than default SGC as single GNN layers, run the following command:

python example.py --conv GCN

At present, some parameters are not supported to be set directly by passing arguments.
If you want to revise them, check utils.py and example.py.

Link Prediction

For task 2 (link prediction), just enter the link directory and run the following command to check our results:

mkdir submission # if this directory does not exist
mkdir models # if this directory does not exist
mkdir models/saves # if this directory does not exist
python src/seal.py

Some parameters can be set by passing arguments.
For example, if you want to eliminate our ensemble learning trick, run the following command:

python src/seal.py --n_models 1

At present, some parameters are not supported to be set directly by passing arguments.
If you want to revise them, check utils.py, seal_utils.py and seal.py.

We also provide node2vec and metapath2vec demo:

Trained embeddings (.npy files) are provided under the link folder.
Demo of generative models are to be updated in the future.

References

[1] A. Grover, and J. Leskovec. node2vec: Scalable Feature Learning for Networks, KDD 16'.
[2] Y. Dong, N. Chawla, et al. metapath2vec: Scalable Representation Learning for Heterogeneous Networks, KDD 17'.
[3] F. Wu, T. Zhang, et al. Simplifying Graph Convolutional Networks, ICML 19'.
[4] Y. Rong, W. Huang, et al. DropEdge: Towards Deep Graph Convolutional Networks on Node Classification, ICLR 20'.
[5] M. Zhang, and Y. Chen. Link Prediction Based on Graph Neural Networks, NeurIPS 18'.

About

Final assignment of EE226 course in SJTU by Group 12

License:Apache License 2.0


Languages

Language:Python 100.0%