Code Monkey home page Code Monkey logo

chemprojector's Introduction

ChemProjector

cover

๐ŸŽฏ Projecting Molecules into Synthesizable Chemical Spaces (ICML 2024)

[Paper]

Install

Clone Repo

Please clone the repository with the --recurse-submodules flag to include the third-party submodules.

git clone --recurse-submodules https://github.com/luost26/ChemProjector.git

Environment

# Install conda environment
conda env create -f env.yml -n chemprojector
conda activate chemprojector

# Install ChemProjector package
pip install -e .

The default CUDA version is 11.8. If you have to use a different version, please modify the env.yml file accordingly.

Building Block Data

We provide preprocessed building block data. You can download it from here and put it in the data directory.

However, the data is derived from Enamine's building block catalog, which are available only upon request. Therefore, you should first request the data from Enamine here and download the US Stock catalog into the data directory. Then run the following script which will check whether you have a copy of the Enamine's catalog and unarchive the preprocessed data for you:

python unarchive_wizard.py

You may also process the building block data by yourself. Please refer to the scripts/preprocess_data directory for more details.

Trained Weights

You can download the trained weights from here and put them in the data/trained_weights directory.

Usage

Project Molecules

You can create a list of SMILES strings in CSV format (example: data/example.csv) and run the following command to project them into the synthesizable chemical space.

python sample.py \
    --model-path data/trained_weights/original_default.ckpt \
    --input data/example.csv \
    --output results/example.csv

Model Evaluation

Bottom-Up Synthesis Planning

Using the test split:

./scripts/synthesis_planning_test_split.sh

or using the ChEMBL dataset:

./scripts/synthesis_planning_chembl.sh

Structure-Based Drug Design

Please refer to the scripts/sbdd directory for details.

Goal-Directed Generation

Please refer to the scripts/goal_directed directory for details.

Train

python train.py ./configs/original_default.yml

Reference

@inproceedings{luo2024chemprojector,
  title={Projecting Molecules into Synthesizable Chemical Spaces},
  author={Shitong Luo and Wenhao Gao and Zuofan Wu and Jian Peng and Connor W. Coley and Jianzhu Ma},
  booktitle={Forty-first International Conference on Machine Learning},
  year={2024}
}

chemprojector's People

Contributors

luost26 avatar pre-commit-ci[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

chemprojector's Issues

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.