A Deep Learning Library for Drug Pair Scoring.
Project description
Documentation | External Resources | Datasets | Examples
ChemicalX is a deep learning library for drug-drug interaction, polypharmacy side effect, and synergy prediction. The library consists of data loaders and integrated benchmark datasets. It also includes state-of-the-art deep neural network architectures that solve the drug pair scoring task. Implemented methods cover traditional SMILES string based techniques and neural message passing based models.
Citing
If you find ChemicalX and the new datasets useful in your research, please consider adding the following citation:
@inproceedings{chemicalx,
author = {Benedek Rozemberczki and Charles Tapley Hoyt and Anna Gogleva and Piotr Grabowski and Klas Karis and Andrej Lamov and Andriy Nikolov and Sebastian Nilsson and Michael Ughetto and Yu Wang and Tyler Derr and Benjamin Gyori},
title = {{ChemicalX: A Deep Learning Library fo Drug Pair Scoring}},
year = {2022},
}
Drug Pair Scoring Explained
Our framework solves the drug pair scoring task of computational chemistry. In this task a machine learning model has to predict the outcome of administering two drugs together in a biological or chemical context. Deep learning models which solve this task have an architecture with two distinctive parts:
- A drug encoder layer which takes a pair of drugs as an input (blue and red drugs below).
- A head layer which outputs scores in the administration context - polypharmacy in our explanatory figure.
Getting Started
The API of chemicalx
provides a high-level function for training and evaluating models
that's heavily influenced by the PyKEEN
training and evaluation pipeline:
from chemicalx import pipeline
from chemicalx.models import DeepSynergy
from chemicalx.data import DrugCombDB
model = DeepSynergy(context_channels=112, drug_channels=256)
dataset = DrugCombDB()
results = pipeline(
dataset=dataset,
model=model,
# Data arguments
batch_size=5120,
context_features=True,
drug_features=True,
drug_molecules=False,
labels=True,
# Training arguments
epochs=100,
)
# Outputs information about the AUC-ROC, etc. to the console.
results.summarize()
# Save the model, losses, evaluation, and other metadata.
results.save("~/test_results/")
Case Study Tutorials
We provide in-depth case study like tutorials in the Documentation, each covers an aspect of ChemicalX’s functionality.
Methods Included
In detail, the following drug pair scoring models were implemented.
2018
-
DeepDDI from Deep Learning Improves Prediction of Drug–Drug and Drug–Food Interactions (PNAS)
-
DeepSynergy from DeepSynergy: Predicting Anti-Cancer Drug Synergy with Deep Learning (Bioinformatics)
2019
-
MR-GNN from MR-GNN: Multi-Resolution and Dual Graph Neural Network for Predicting Structured Entity Interactions (IJCAI)
-
MHCADDI from Drug-Drug Adverse Effect Prediction with Graph Co-Attention (ICML)
2020
-
CASTER from CASTER: Predicting Drug Interactions with Chemical Substructure Representation (AAAI)
-
SSI-DDI from SSI–DDI: Substructure–Substructure Interactions for Drug–Drug Interaction Prediction (Briefings in Bioinformatics)
-
EPGCN-DS from Structure-Based Drug-Drug Interaction Detection via Expressive Graph Convolutional Networks and Deep Sets (AAAI)
-
DeepDrug from DeepDrug: A General Graph-Based Deep Learning Framework for Drug Relation Prediction (PMC)
-
GCN-BMP from GCN-BMP: Investigating graph representation learning for DDI prediction task (Methods)
2021
-
DeepDDS from DeepDDS: Deep Graph Neural Network with Attention Mechanism to Predict Synergistic Drug Combinations (Briefings in Bioinformatics)
-
MatchMaker from MatchMaker: A Deep Learning Framework for Drug Synergy Prediction (ACM TCBB)
Head over to our documentation to find out more about installation, creation of datasets and a full list of implemented methods and available datasets.
For a quick start, check out the examples in the examples/
directory.
If you notice anything unexpected, please open an issue. If you are missing a specific method, feel free to open a feature request.
Installation
PyTorch 1.10.0
To install for PyTorch 1.10.0, simply run
pip install torch-scatter -f https://pytorch-geometric.com/whl/torch-1.10.0+${CUDA}.html
pip install torchdrug
pip install chemicalx
where ${CUDA}
should be replaced by either cpu
, cu102
, or cu111
depending on your PyTorch installation.
cpu |
cu102 |
cu111 |
|
---|---|---|---|
Linux | ✅ | ✅ | ✅ |
Windows | ✅ | ✅ | ✅ |
macOS | ✅ |
Running tests
$ python setup.py test
License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file chemicalx-0.1.0.tar.gz
.
File metadata
- Download URL: chemicalx-0.1.0.tar.gz
- Upload date:
- Size: 95.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.6.0 importlib_metadata/4.8.2 pkginfo/1.6.1 requests/2.24.0 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.8.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bce18fdbeee4d657d95d1a888523a23613458f58de82d7aa3a79a33d0695df4c |
|
MD5 | 7974b3328e45004bf16130661488150d |
|
BLAKE2b-256 | 55914ccf3f927c7f4e16293d81e09af3e198f4c6056510855e70754e39a119dd |