Skip to content

carpenter-singh-lab/motive

Repository files navigation

MOTI$\mathcal{VE}$

Source code and documentation for "MOTI$\mathcal{V}\mathcal{E}$: A Drug-Target Interaction Graph For Inductive Link Prediction".

See the Wiki for full documentation, operational details and other information.

Installation

We recommend using Mamba for environment management. The following commands clone the repository, create the environment from scratch, and install the required packages.

git clone https://github.com/carpenter-singh-lab/motive.git
mamba env create --file environment.yml
mamba activate graphdti

Download data

The MOTI$\mathcal{VE}$ dataset files are available in the Cell Painting Gallery viewer. We provide two options for programmatic access. Both will populate the working directory with the necessary gene-compound relationships, node features, and metadata. For more information about the directory contents, refer to the Wiki page.

Using aws-cli

The following command will download inputs and data folders:

aws s3 sync --no-sign-request s3://cellpainting-gallery/cpg0034-arevalo-su-motive/broad/workspace/publication_data/2024_MOTIVE . 

Run the snakemake pipeline

Alternatively, you can also run the Snakemake pipeline included in this repo which downloads the necessary inputs and generates the data files.

snakemake -c1

With 1 being the number of cores you want to use.

Train

Run the following command to train a model on the MOTI$\mathcal{VE}$ dataset. The config file should indicate the graph type (optimized configs are only provided for the bipartite and st_expanded graph structures), gene type, data split, and model. An example is provided below.

python run_training.py configs/train/st_expanded/cold_source/gnn_cp.json outputs/

The training will produce a test_results.parquet file in the outputs/ folder with the predicted scores and percentiles for each source target pair in the test set.

score y_pred y_true percentile
(1537, 1352) 0.992261 True 1 1
(336, 2637) 0.977271 True 1 0.999981
(1714, 2506) 0.949711 True 1 0.999962
(40, 1452) 0.923437 True 1 0.999943
(412, 110) 0.917436 True 1 0.999924

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages