S23D-S

S23D-S generates 3D conformers of molecules from SMILES. It is the small model from the preprint A standard transformer and attention with linear biases for molecular conformer generation by Viatcheslav Gurev and Timothy Rumbell. Code: https://github.com/IBM/S23D

Usage

Create a conda environment and install the smiles23d package from GitHub (Python 3.11 or later):

conda create -n s23d python=3.11 -y
conda activate s23d
git clone https://github.com/IBM/S23D.git
cd S23D
pip install .

Generate conformers:

from rdkit import Chem
from smiles23d.huggingface import S23DDiffusionHF

model = S23DDiffusionHF.from_pretrained("ibm-research/S23D.8m.v1", map_location="cuda")  # or "cpu"
model.eval()
model.set_predict_parameters(kind="VPSDE", n_steps=300)  # 300 steps, as in the paper

conformers = model.predict("CC(=O)Nc1ccc(O)cc1", samples_per_molecule=10)

# conformers[0] is a list of RDKit molecules, one conformer each.
with Chem.SDWriter("conformers.sdf") as writer:
    for m in conformers[0]:
        writer.write(m)

predict also takes an RDKit molecule or a list of SMILES strings or molecules. The README describes its options and the GEOM-DRUGS evaluation with s23dtest.

Model

A diffusion model whose score network is a standard, non-equivariant transformer. A graph encoder turns atom tokens and the 2D molecular graph into atom representations, and a structural module combines them with the 3D coordinates to predict the score. Graph structure enters attention as a negative bias that grows linearly with the shortest-path distance between atoms, with a different slope per head.

Graph encoder blocks 1
Structural module blocks 9
Hidden size 256
Attention heads 8
Parameters 8,545,030

Training

GEOM-DRUGS as preprocessed by MCF, 20 conformers per molecule, in two stages: 100 epochs on molecules without hydrogens, then 35 epochs on complete molecules. This checkpoint is the last epoch (epoch 134). AdamW, learning rate 1e-4, weight decay 1e-3, 2 GPUs, global batch 256. Configs: configs/s23d_s_stage1.yaml and configs/s23d_s_stage2.yaml.

Evaluation

Results from the preprint for S23D-S-1/9 (S) on GEOM-DRUGS test_1000: 2K generated conformers for a molecule with K reference conformers, 300 diffusion steps, heavy-atom RMSD after alignment, coverage threshold 0.75 Ã…, no chirality correction. Mean / median:

Recall COV (%) ↑ Recall AMR (Å) ↓ Precision COV (%) ↑ Precision AMR (Å) ↓
80.7 / 89.9 0.483 / 0.458 57.5 / 57.5 0.757 / 0.700

The benchmark data is in ibm-research/S23D.GEOM.processed; the evaluation needs only its zarr/test_1000 and index/eval_index/test_1000 folders.

Citation

@misc{gurev2025standard,
  title         = {A standard transformer and attention with linear biases for molecular conformer generation},
  author        = {Gurev, Viatcheslav and Rumbell, Timothy},
  year          = {2025},
  eprint        = {2506.19834},
  archivePrefix = {arXiv},
  primaryClass  = {q-bio.BM},
  url           = {https://arxiv.org/abs/2506.19834}
}

License

Apache License 2.0.

Downloads last month
-
Safetensors
Model size
8.55M params
Tensor type
F32
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Dataset used to train ibm-research/S23D.8m.v1

Paper for ibm-research/S23D.8m.v1