- Notifications
You must be signed in to change notification settings - Fork148
Graph convolutional neural network for multirelational link prediction
License
mims-harvard/decagon
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Author:Marinka Zitnik (marinka@cs.stanford.edu)
This repository contains code necessary to run the Decagon algorithm. Decagon is a method for learning nodeembeddings in multimodal graphs, and is especially useful for link prediction in highly multi-relational settings. Seeourpaper for details on the algorithm.
Decagon is used to address a burning question in pharmacology, which is that of predictingsafety of drug combinations.
We construct a multimodal graph of protein-protein interactions, drug-protein target interactions, andpolypharmacy side effects, which are represented as drug-drug interactions, where each side effect is an edge of adifferent type.
Decagon uses graph convolutions to embed the multimodal graph in a compact vector space and then usesthe learned embeddings to predict side effects of drug combinations.
The setup for the polypharmacy problem on a synthetic dataset is outlined inmain.py
. It uses a small syntheticnetwork example with five edge types. Run the code as following:
$ python main.py
The full polypharmacy dataset (described in the paper) is available on theproject website. To run the code on the full dataset first download all data filesfrom theproject website. The polypharmacy dataset is already preprocessed and ready to use.After cloning the project, replace the synthetic example inmain.py
with the polypharmacy dataset and run the model.
If you findDecagon useful for your research, please consider citingthis paper:
@article{Zitnik2018, title = {Modeling polypharmacy side effects with graph convolutional networks.}, author = {Zitnik, Marinka and Agrawal, Monica and Leskovec, Jure}, journal = {Bioinformatics}, volume = {34}, number = {13}, pages = {457–466}, year = {2018}}
Please send any questions you might have about the code and/or thealgorithm tomarinka@cs.stanford.edu.
This code implements several different edge decoders (innerproduct, distmult,bilinear, dedicom) and loss functions (hinge loss, cross entropy). Many deep variants are possible and what worksbest might depend on a concrete use case.
Decagon is tested to work under Python 2 and Python 3.
Recent versions of Tensorflow, sklearn, networkx, numpy, and scipy are required. All the required packages can be installed using the following command:
$ pip install -r requirements.txt
Decagon is licensed under the MIT License.