Skip to main content

SynFormer: Generative Model for Synthesizable Molecule Generation

Project description

SynFormer

SynFormer is a generative modeling framework designed to efficiently explore and navigate synthesizable chemical space.

[Paper]

Install

Environment

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

# Install SynFormer package
pip install --no-deps -e .

Building Block Database

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/building_blocks 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 scripts/unarchive_wizard.py

Trained Models

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

Usage

Bottom-Up Synthesis Planning

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

Reference

If you find our code/model useful, please cite our papers:

@article{gao2024synformer,
  title={Generative artificial intelligence for navigating synthesizable chemical space},
  author={Wenhao Gao and Shitong Luo and Connor W. Coley},
  year={2024}
}

@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}
}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

synformer-0.1.2.tar.gz (57.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

synformer-0.1.2-py3-none-any.whl (106.1 kB view details)

Uploaded Python 3

File details

Details for the file synformer-0.1.2.tar.gz.

File metadata

  • Download URL: synformer-0.1.2.tar.gz
  • Upload date:
  • Size: 57.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.10.0

File hashes

Hashes for synformer-0.1.2.tar.gz
Algorithm Hash digest
SHA256 b604899457798f53b8d290d8eb3a8789ebd33d2c688f1657eab392ff20ee5913
MD5 951fb6c3804ad554a912811d26216f2e
BLAKE2b-256 fd8b7f0a8b14292fef12e10aea08da1c30fcab79b3bf1abc389a921d5c44bbef

See more details on using hashes here.

File details

Details for the file synformer-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: synformer-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 106.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.10.0

File hashes

Hashes for synformer-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 07a4b1bc860b85354510fbf7e72a79add154559b96f0934033aa8c05487659d5
MD5 93aa2c2eb260c7a4fe32c4a2499c18c8
BLAKE2b-256 011247ac19885d5087082b8310d99a345353a7039140087e5c218d174fb98f24

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page