Implementation of the Paper: "Parameterized Hypercomplex Graph Neural Networks for Graph Classification" by Tuan Le, Marco Bertolini, Frank Noé and Djork-Arné Clevert

Overview

Parameterized Hypercomplex Graph Neural Networks (PHC-GNNs)

PHC-GNNs (Le et al., 2021): https://arxiv.org/abs/2103.16584

PHM Linear Layer Illustration PHC-GNN Layer Computation Diagram

Overview

Here we provide the implementation of Parameterized Hypercomplex Graph Neural Networks (PHC-GNNs) in PyTorch Geometric, along with 6 minimal execution examples in the benchmarks/ directory.

This repository is organised as follows:

  • phc/hypercomplex/ contains the implementation of the PHC-GNN with all its submodules. This directory resembles the quaternion/ in most cases, with the user-defined phm-dimension n. For more details, check the subdirectory README.md
  • phc/quaternion/ contains the implementation for quaternion GNN with all its submodules. For more details, check the subdirectory README.md
  • benchmarks/ contains the python training-scripts for 3 datasets from Open Graph Benchmark (OGB) and 3 datasets from Benchmarking-GNNs. Additionally, we provide 6 bash-scripts with default arguments to run our models.

Generally speaking, the phc/hypercomplex/ subdirectory also includes the quaternion-valued GNN, with the modification to only work on torch.Tensor objects. The phc/quaternion/ subdirectory was first implemented with the fixed rules of the quaternion-algebra, such as how to perform addition, and multiplication which can be summarized in the quaternion-valued affine transformation. The phc/hypercomplex/ directory generalizes such operations to work directly on torch.Tensor objects, making it applicable to many already existing projects.
For completeness and to share our initial motivation of this project, we also provide the implementations from the phc/quaternion/ subdirectory.

Installation

Requirements

To run our examples, the main requirements are listed in the environment_gpu.yml file. The main requirements used are the following:

python=3.8.5
pytest=6.2.1
cudatoolkit=10.1
cudnn=7.6.5
numpy=1.19.2
scipy=1.5.2
pytorch=1.7.1
torch-geometric=1.6.1
ogb=1.2.4

Conda

Create a new environment:

git clone https://github.com/bayer-science-for-a-better-life/phc-gnn.git
cd phc-gnn
conda env create -f environment_gpu.yml
conda activate phc-gnn

Install Pytorch Geometric and this module with pip by executing the bash-script install_pyg.sh

chmod +x install_pyg.sh
bash install_pyg.sh

#install this library
pip install -e .

Run the implemented pytests in the subdirectories, by executing:

pytest .

Getting started

Run our example scripts in the benchmarks/ directory. Make sure to have the phc-gnn environment activated. For more details, please have a look at benchmarks/README.md.

Reference

If you make use of the implementations of quaternion or parameterized hypercomplex GNN in your research, please cite our manuscript:

@misc{le2021parameterized,
      title={Parameterized Hypercomplex Graph Neural Networks for Graph Classification}, 
      author={Tuan Le and Marco Bertolini and Frank Noé and Djork-Arné Clevert},
      year={2021},
      eprint={2103.16584},
      archivePrefix={arXiv},
      primaryClass={cs.LG},
      url={https://arxiv.org/abs/2103.16584}
}

License

GPL-3

Owner
Bayer AG
Science for a better life
Bayer AG
pip install python-office

🍬 python for office 👉 http://www.python4office.cn/ 👈 🌎 English Documentation 📚 简介 Python-office 是一个 Python 自动化办公第三方库,能解决大部分自动化办公的问题。而且每个功能只需一行代码,

程序员晚枫 272 Dec 29, 2022
Multiple style transfer via variational autoencoder

ST-VAE Multiple style transfer via variational autoencoder By Zhi-Song Liu, Vicky Kalogeiton and Marie-Paule Cani This repo only provides simple testi

13 Oct 29, 2022
Voice Conversion by CycleGAN (语音克隆/语音转换):CycleGAN-VC3

CycleGAN-VC3-PyTorch 中文说明 | English This code is a PyTorch implementation for paper: CycleGAN-VC3: Examining and Improving CycleGAN-VCs for Mel-spectr

Kun Ma 110 Dec 24, 2022
Jremesh-tools - Blender addon for quad remeshing

JRemesh Tools Blender 2.8 - 3.x addon for quad remeshing. Currently it is a wrap

Jayanam 89 Dec 30, 2022
Code for MarioNette: Self-Supervised Sprite Learning, in NeurIPS 2021

MarioNette | Webpage | Paper | Video MarioNette: Self-Supervised Sprite Learning Dmitriy Smirnov, Michaël Gharbi, Matthew Fisher, Vitor Guizilini, Ale

Dima Smirnov 28 Nov 18, 2022
Distributed Deep learning with Keras & Spark

Elephas: Distributed Deep Learning with Keras & Spark Elephas is an extension of Keras, which allows you to run distributed deep learning models at sc

Max Pumperla 1.6k Jan 05, 2023
Training Very Deep Neural Networks Without Skip-Connections

DiracNets v2 update (January 2018): The code was updated for DiracNets-v2 in which we removed NCReLU by adding per-channel a and b multipliers without

Sergey Zagoruyko 585 Oct 12, 2022
Meta Self-learning for Multi-Source Domain Adaptation: A Benchmark

Meta Self-Learning for Multi-Source Domain Adaptation: A Benchmark Project | Arxiv | YouTube | | Abstract In recent years, deep learning-based methods

CVSM Group - email: <a href=[email protected]"> 188 Dec 12, 2022
Continuum Learning with GEM: Gradient Episodic Memory

Gradient Episodic Memory for Continual Learning Source code for the paper: @inproceedings{GradientEpisodicMemory, title={Gradient Episodic Memory

Facebook Research 360 Dec 27, 2022
1st Solution For ICDAR 2021 Competition on Mathematical Formula Detection

This project releases our 1st place solution on ICDAR 2021 Competition on Mathematical Formula Detection. We implement our solution based on MMDetection, which is an open source object detection tool

yuxzho 94 Dec 25, 2022
CUAD

Contract Understanding Atticus Dataset This repository contains code for the Contract Understanding Atticus Dataset (CUAD), a dataset for legal contra

The Atticus Project 273 Dec 17, 2022
SMCA replication There are no extra compiled components in SMCA DETR and package dependencies are minimal

Usage There are no extra compiled components in SMCA DETR and package dependencies are minimal, so the code is very simple to use. We provide instruct

22 May 06, 2022
Source code of all the projects of Udacity Self-Driving Car Engineer Nanodegree.

self-driving-car In this repository I will share the source code of all the projects of Udacity Self-Driving Car Engineer Nanodegree. Hope this might

Andrea Palazzi 2.4k Dec 29, 2022
Panoptic SegFormer: Delving Deeper into Panoptic Segmentation with Transformers

Panoptic SegFormer: Delving Deeper into Panoptic Segmentation with Transformers Results results on COCO val Backbone Method Lr Schd PQ Config Download

155 Dec 20, 2022
The official implementation of Variable-Length Piano Infilling (VLI).

Variable-Length-Piano-Infilling The official implementation of Variable-Length Piano Infilling (VLI). (paper: Variable-Length Music Score Infilling vi

29 Sep 01, 2022
PyTorch implementation of the TTC algorithm

Trust-the-Critics This repository is a PyTorch implementation of the TTC algorithm and the WGAN misalignment experiments presented in Trust the Critic

0 Nov 29, 2021
CVPR2021: Temporal Context Aggregation Network for Temporal Action Proposal Refinement

Temporal Context Aggregation Network - Pytorch This repo holds the pytorch-version codes of paper: "Temporal Context Aggregation Network for Temporal

Zhiwu Qing 63 Sep 27, 2022
A library for implementing Decentralized Graph Neural Network algorithms.

decentralized-gnn A package for implementing and simulating decentralized Graph Neural Network algorithms for classification of peer-to-peer nodes. De

Multimedia Knowledge and Social Analytics Lab 5 Nov 07, 2022
Code for testing convergence rates of Lipschitz learning on graphs

📈 LipschitzLearningRates The code in this repository reproduces the experimental results on convergence rates for k-nearest neighbor graph infinity L

2 Dec 20, 2021
MMdet2-based reposity about lightweight detection model: Nanodet, PicoDet.

Lightweight-Detection-and-KD MMdet2-based reposity about lightweight detection model: Nanodet, PicoDet. This repo also includes detection knowledge di

Egqawkq 12 Jan 05, 2023