Fine-tune generated molecular poses with a force field

Some molecular pose generation methods benefit from an energy relaxation post-processing step.

Predicted pose before energy minimization
Example of a small molecule pose before and after energy minimization. The pose before minimization is shown in white, the optimized prediction is shown in pink, and a crystal pose is shown as reference in light blue. Note how the aromatic rings are flattened and the leftmost bond is shortened by the optimization.

Here is a quick way to do this using OpenMM via a short script I prepared:

1. Get script

git clone https://github.com/maabuu/posebusters_em.git
cd posebusters_em

2. Setup environment

conda create -n posebusters_em openff-forcefields openff-interchange openff-toolkit "openmm>=8" "openmmforcefields>=0.11" pdbfixer "rdkit>=2022" -c conda-forge
conda activate posebusters_em

3. Run minimization

python energy_minimization.py test_cases/7MYU_ZR7/7MYU_ZR7_protein.pdb test_cases/7MYU_ZR7/7MYU_ZR7_prediction.sdf 7MYU_ZR7_prediction_minimized.sdf -t cache_dir

This example takes ~2 minutes to run on a desktop computer. Depending on the system’s complexity, runs may take much longer.

The script is available on https://github.com/maabuu/posebusters_em.

Author