Skip to main content

General Purpose Graph Isomorphism Network is a GNN architecture that is able to process graphs with continuous node and edge features.

Project description

General Purpose Graph Isomorphism Network is a GNN architecture that is able to process graphs with continuous node and edge features.

Installation

We recommend installing PyTorch and PyTorch Geometric before gpgin-cli to avoid compatibility issues related to CUDA versions and hardware acceleration.

Note: we recommend using pip rather than conda, as some PyTorch Geometric dependencies are not available via conda.

Refer to:

The versions that we used, targeting CUDA-11.8:

torch==2.2.2
torch-geometric==2.5.2
rdkit-pypi==2022.09.5

Install script

This may be useful on a blank python 3.10 virtual environment

#!/bin/bash
set -e

# === CONFIGURABLE VARIABLES ===
CUDA_VERSION="cu118"
PYTORCH_VERSION="2.2.2"
TORCHVISION_VERSION="0.17.2"
TORCHAUDIO_VERSION="2.2.2"
TORCH_GEOMETRIC_VERSION="2.5.2"
RDKIT_PYPI_VERSION="2022.09.5"
# === 1. Install PyTorch ===
echo "[1/4] Installing PyTorch with CUDA $CUDA_VERSION..."
pip install torch=="$PYTORCH_VERSION" \
            torchvision=="$TORCHVISION_VERSION" \
            torchaudio=="$TORCHAUDIO_VERSION" \
            --index-url https://download.pytorch.org/whl/$CUDA_VERSION

# === 2. Install PyTorch Geometric core ===
echo "[2/4] Installing PyTorch Geometric $TORCH_GEOMETRIC_VERSION..."
pip install torch_geometric=="$TORCH_GEOMETRIC_VERSION"

# === 3. Install PyTorch Geometric Optional Dependencies ===
echo "[3/4] Installing PyG optional dependencies for CUDA $CUDA_VERSION..."
pip install pyg_lib torch_scatter torch_sparse torch_cluster torch_spline_conv \
            -f https://data.pyg.org/whl/torch-${PYTORCH_VERSION}+${CUDA_VERSION}.html

# === 4. Install RDKit ===
echo "[4/4] Installing RDKit..."
pip install rdkit-pypi==$RDKIT_PYPI_VERSION

# === Final Step: Install Your CLI Package ===
echo "[✓] Installing your CLI package (gpgin-cli)..."
pip install gpgin-cli

Examples:

Our API expects an SDF file for the X field and a line-separated values file for the y and out field

Training:

gpgin train \
  -X ./data/gdb9.sdf \
  -y ./data/gdb9_u0.txt \
  --name my_model \
  --batch_size 100 \
  --n_epochs 100 \
  --dataset_name QM9 \
  --target_name u0
# Notes:
# - Models are saved in ~/.gpgin/models
# - Processed datasets are saved in ~/.gpgin/processed

Inference:

gpgin run \
  -X ./data/gdb9.sdf \
  --out ./results/gdb9_u0.txt \
  --name my_model \
  --batch_size 64

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gpgin_cli-0.1.1.tar.gz (12.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gpgin_cli-0.1.1-py3-none-any.whl (12.5 kB view details)

Uploaded Python 3

File details

Details for the file gpgin_cli-0.1.1.tar.gz.

File metadata

  • Download URL: gpgin_cli-0.1.1.tar.gz
  • Upload date:
  • Size: 12.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.18

File hashes

Hashes for gpgin_cli-0.1.1.tar.gz
Algorithm Hash digest
SHA256 2284b2989e45e72e0408ad87c12e0c19e47eeb580b811999ebd80fc51b7dbdfe
MD5 797e9c4a9da7adc3883a331aafba587d
BLAKE2b-256 d013e27604c3f85f8c1800a04509c3f31f49fe2fea637e8a34b7552a4cc57490

See more details on using hashes here.

File details

Details for the file gpgin_cli-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: gpgin_cli-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 12.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.18

File hashes

Hashes for gpgin_cli-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 bb67100673deaad6a2a87404f8df7e9266d1d1f4e3b7e0fbb7d0dc658f765e1f
MD5 c1b691eef1c6cc2a18468e87e3a820d3
BLAKE2b-256 c09b9dcdd5a74d0d09b5fe16b1902afd9c8211e627273f71ecbbe07c036b9420

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page