Giter Site home page Giter Site logo

sailfish009 / bilevel-graph-neural-network Goto Github PK

View Code? Open in Web Editor NEW

This project forked from codekgu/bilevel-graph-neural-network

0.0 1.0 0.0 9.56 MB

Bi-Level Graph Neural Networks for Drug-Drug Interaction Prediction. ICML 2020 Graph Representation Learning and Beyond (GRL+) Workshop

License: MIT License

Python 99.56% Dockerfile 0.44%

bilevel-graph-neural-network's Introduction

BiLevel-Graph-Neural-Networks

License: MIT codebeat badge

Overview

This repo contains the code for Bi-Level Graph Neural Networks for Drug-Drug Interaction Prediction. For details please refer to the our paper

Bi-Level Graph Neural Networks for Drug-Drug Interaction Prediction. Yunsheng Bai*, Ken Gu*, Yizhou Sun, Wei Wang. ICML 2020 Graph Representation Learning and Beyond (GRL+) Workshop [Paper] [Workshop].

Model

DDI image

We introduce Bi-GNN for modeling biological link prediction tasks such as drug-drug interaction (DDI) and protein-protein interaction (PPI). Taking drug-drug interaction as an example, existing methods using machine learning either only utilize the link structure between drugs without using the graph representation of each drug molecule, or only leverage the individual drug compound structures without using graph structure for the higher-level DDI graph. The key idea of our method is to fundamentally view the data as a bi-level graph, where the highest level graph represents the interaction between biological entities (interaction graph), and each biological entity itself is further expanded to its intrinsic graph representation (representation graphs), where the graph is either flat like a drug compound or hierarchical like a protein with amino acid level graph, secondary structure, tertiary structure, etc.

Usage

Environment Setup

The code is implemented in python 3.6. The libraries used can be seen in the Dockerfile. To set up the docker environment

$ docker build . -t bilevel_gnn
$ nvidia-docker run -e "HOSTNAME=$(cat /etc/hostname)" -v [path_to_repo]:/workspace -it bilevel_gnn bash

There is also an option to use comet.ml for experiment tracking.

Project Navigation

  • data contains the raw data for the datasets
  • model contains pytorch modules for building our model as well as baseline models
  • src contains the main source code
    • config.py is used for all experiment configuration
    • main.py is the main script
  • utils contains utility functions and data processing and loading
  • save folder (not included in repo) for storing intermediary data klepto objects for faster data loading

Datasets

The raw data for the Drugbank dataset and the Drugcombo dataset are available in the data folder. For faster dataloading feel free to download the BiGNNDataset klepto objects from google drive. Place the files in the save/dataset folder.

Running the model

Change experiment configurations in config.py. If you want to use comet.ml set COMET_ML_API_KEY to your comet.ml api key and set YOUR_COMET_PROJECT_NAME to your comet project name. You will also want to set use_comet_ml to True. For example you can change the model, dataset etc.

After simply run

$ cd src && python main.py

Support

If you have any questions about the code or algorithm please reach out to [email protected].

bilevel-graph-neural-network's People

Contributors

codekgu avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.