Code for the link prediction task on graphs using autoencoders.
link_prediction is the python package that can be easily imported by doing
import link_predictionThe code in this repository is the same present in the Colab Notebook, which was used to run the experiments (The notebook is in the notebook folder or here).
The following dependencies are needed in order to use the package:
- scikit-learn
- dgl
- torch
- numpy
- scipy
The package exposes the model's classes used during the experiments:
- Graph Convolution AutoEncoder (GCAE)
- Graph Normalized Convolution AutoEncoder (GNCAE)
- Graph ATtention AutoEncoder (GATAE)
- Graph Transformer AutoEncoder (GTAE)
And the main functions to train them using k-fold:
train_kfoldfor simple trainingtrain_contrastive_kfoldfor contrastive training