Skip to content

official repo for the NeurIPS 2022 paper "GREED: A Neural Framework for Learning Graph Distance Functions"

License

Notifications You must be signed in to change notification settings

idea-iitd/greed

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GREED: A Neural Framework for Learning Graph Distance Functions

This repository contains the official reference implementation for the paper "GREED: A Neural Framework for Learning Graph Distance Functions" accepted at NeurIPS 2022. neuro contains our implementation of the neural models presented in the paper along with supporting code for experiments. pyged contains our python wrapper over GEDLIB, which can be used to compute SED/GED values and graph alignments using non-neural techniques.

Data and Model Weights

The data and trained models can be downloaded from this Google Drive link. Please see the README contained therein for further details.

If you have gdown installed (pip install gdown or conda install -c conda-forge gdown), you can download on terminal with:

gdown 1bRf6isnbfIrDc7V8xStlwEFX1ZtIMBEB

Experiments

The Jupyter notebooks for the experiments in the paper can be found at the sister repository greed-expts.

Installation

We recommend using a conda environment for installation.

  1. Install Python, Jupyter, PyTorch and PyTorch Geometric (also networkx and matplotlib). The code has been tested to work with Python 3.6.13, PyTorch 1.8.0 and PyTorch Geometric 1.6.3, but later versions are also expected to run smoothly.

  2. Install pyged:

    2.1. Install GEDLIB at pyged/ext/gedlib as a header-only library (see Section 4.1 in the docs).

    Detailed steps are as follows:

    mkdir pyged/ext
    cd pyged/ext
    git clone --branch v1.0 --depth 1 https://github.com/dbblumenthal/gedlib
    cd gedlib
    python install.py
    cd ext
    wget https://boostorg.jfrog.io/artifactory/main/release/1.82.0/source/boost_1_82_0.tar.gz
    tar -xzf boost_1_82_0.tar.gz

    2.2. Install Gurobi 9.1.1 at pyged/ext/gurobi911. Later versions can be used with suitable naming changes. Gurobi requires a licence. Free academic licenses are available. Gurobi is required for ground truth SED computation. Alternatively, one could use one of the non-MIP methods available in GEDLIB or use the generated data provided by us. To build without Gurobi, comment out #define GUROBI in pyged/src/pyged.cpp.

    Detailed steps are as follows:

    cd pyged/ext
    wget https://packages.gurobi.com/9.1/gurobi9.1.1_linux64.tar.gz
    tar -xzf gurobi9.1.1_linux64.tar.gz
    cd gurobi911/linux64/src/build
    make

    2.3. Install PyBind11.

    Example step:

    conda install -c conda-forge pybind11

    2.4. Build pyged (you can install cmake with conda if it's not available):

    mkdir pyged/build
    cd pyged/build
    cmake ..
    make

    This will create a Python module for pyged in pyged/lib.

Usage

Check out the experiment notebooks at greed-expts for example usage. The notebooks contain code for training, testing, visualization, etc.

Contact

If you face any difficulties in using this repo feel free to raise a GitHub issue (recommended) or reach out via email at [email protected]. I am unable to respond to queries sent to [email protected] in a timely manner.

Citation

@inproceedings{ranjan&al22,
  author = {Ranjan, Rishabh and Grover, Siddharth and Medya, Sourav and Chakaravarthy, Venkatesan and Sabharwal, Yogish and Ranu, Sayan},
  keywords = {Machine Learning (cs.LG), FOS: Computer and information sciences, FOS: Computer and information sciences},
  title = {GREED: A Neural Framework for Learning Graph Distance Functions},
  booktitle = {Advances in Neural Information Processing Systems 36: Annual Conference
               on Neural Information Processing Systems 2022, NeurIPS 2022, November 29-Decemer 1, 2022},
  year = {2022},
}

About

official repo for the NeurIPS 2022 paper "GREED: A Neural Framework for Learning Graph Distance Functions"

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published