HelloWorldLTY / BAITSAO

A foundation model for drug synergy analysis

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

BAITSAO

This is the offical code repo for manuscript: BAITSAO: Building A Foundation Model for Drug Synergy Analysis.

Installation

We reply on OpenAI api for constructing the training dataset:

pip install openai

We reply on pytorch and pytorch lightnining for model training. We also use scanpy for analysis.

conda activate baitsao
conda install pytorch torchvision torchaudio pytorch-cuda=12.1 -c pytorch -c nvidia
conda install lightning -c conda-forge
pip install pandas
pip install scanpy
pip install scipy
pip install scikit-learn

Optional: To reproduce our work based on SHAP, please install SHAP:

pip install shap

Optional: To reproduce our work based on CPA, please install CPA:

pip install git+https://github.com/theislab/cpa

Optional: To reproduce our work based on TabNet, please install TabNet:

pip install pytorch-tabnet

Optional: To reproduce our work based on BERT, please install transformer:

pip install transformer

Optional: To reproduce our work based on linearMTL, please use R and install linearMTL:

install.packages("linearMTL")

Training

To pretrain our model based on your own dataset, please refer codes under pretraining. We upload our model checkpoint in the folder:

To finetune our model or train it from scartch, please refer codes under finetuning.

We also have modified CPA codes under CPA folder, with a notebook about how to use it.

To test the performance of methods implemented in this manuscript, please refer the codes under benchmarking. Please refer official codes of DeepSynergy, MARSY, and DeepDDs for their implementation.

Query

To use our pretrained model for zero-shot learning, please refer codes under query. We allow the inference for the combiantions with at most 10 drugs and one cell line.

Datasets

We offer a demo dataset in this folder.

Acknowledgement

We refer codes from UW, PCGARD, GRADVAC, and NashMTL for the implementation of multi-task learning framework. Thanks for their great codes!

Citation

@article {Liu2024.04.08.588634,
	author = {Tianyu Liu and Tinyi Chu and Xiao Luo and Hongyu Zhao},
	title = {BAITSAO: Building A Foundation Model for Drug Synergy Analysis Powered by Language Models},
	elocation-id = {2024.04.08.588634},
	year = {2024},
	doi = {10.1101/2024.04.08.588634},
	publisher = {Cold Spring Harbor Laboratory},
	URL = {https://www.biorxiv.org/content/early/2024/04/12/2024.04.08.588634},
	eprint = {https://www.biorxiv.org/content/early/2024/04/12/2024.04.08.588634.full.pdf},
	journal = {bioRxiv}
}

About

A foundation model for drug synergy analysis


Languages

Language:Python 63.0%Language:Jupyter Notebook 37.0%