Run autodock-vina from ODDT #oddt #chemoinformatics #SBDD

I posted about auto_dock vina python bindings. It’s useful for python user because it can call autodock vina from python and run docking study on your python interprinter, jupyter notebook or script.

I knew that ODDT (open drug discovery toolkit) supports virtual screening with vina and it has lots of useful method for drug discovery project. So I tried to use oddt for vina docking.

To run vina from oddt, autodock-vina should be globally installed in my system. But I didn’t do that so I passed ‘executable’ option to tall oddt where vina is.

OK let’s write code. I used previously prepared ABL pdbqt file as receptor. It’s useful point that if auto_ligand is used, ODDT automatically calculates center of docking box (default size is 20 x 20 x 20 aungstrom).

import oddt
from rdkit import Chem
from rdkit.Chem import AllChem
mol = Chem.AddHs(Chem.MolFromSmiles('CC1=C(C=C(C=C1)NC(=O)C2=CC=C(C=C2)CN3CCN(CC3)C)NC4=NC=CC(=N4)C5=CN=CC=C5'))
AllChem.EmbedMolecule(mol)
odmol = oddt.toolkits.rdk.Molecule(mol)
obmol = oddt.toolkits.ob.Molecule(odmol) # converted ob.Molecule because vs.dock caused error when I used rdk.Molecule

from oddt.docking import autodock_vina
vina_path = '/home/iwatobipen/src/autodock_vina_1_1_2_linux_x86/bin/vina'

vs = autodock_vina(protein='../generatedfile/1iep_receptor.pdbqt',
                  auto_ligand='../generatedfile/1iep_ligand.pdbqt',
                   executable=vina_path,
                   n_cpu=5,
                  )


Now I finished setting up of docking experiments. At first I read molecule from rdk and use it but it failed. So I converted molecule as Openbabel mol object and run docking. Following result indicates that I could get 4 docking poses. I saved each pose as pdb format.

vs.center
> array([15.714, 53.057, 15.644], dtype=float32)

res = vs.dock(ligands=[obmol])
n_pose = len(res)
for i in range(n_pose):
    res[i].write('pdb', f'pose{i}.pdb', overwrite=True)

for i in range(n_pose):
    print(res[i].data['vina_affinity'])
> -12.1
> -10.6
> -10.3
> -9.6

OK let’s check pose with pymol. Here is the screen shot of receptor, ligand from pdb(pink) and the highest rank pose from vina (yellow). It’s easy to get docking data from res object.

res[0].data

> {'vina_affinity': '-12.1', 'vina_rmsd_lb': '0.000', 'vina_rmsd_ub': '0.000', 'vina_rmsd_input': '58.3439', 'vina_rmsd_input_min': '58.3439', 'Formula': 'C29H31N7O'}

I think it’s worth to know that by using oddt, the process of virtual screening with vina will be simple and easy even if we need additional effort for receptor and ligand preparation before docking experiments.

Here is a very useful blog post about structure based virtual docking written in Japanse. https://magattaca.hatenablog.com/entry/2019/04/04/003557

If you have an interested in vina and docking with OSS, I would like to recommend to check it.

Advertisement

Published by iwatobipen

I'm medicinal chemist in mid size of pharmaceutical company. I love chemoinfo, cording, organic synthesis, my family.

One thought on “Run autodock-vina from ODDT #oddt #chemoinformatics #SBDD

  1. I’ve just tried ODDT using the code above with larger molecule (‘CC(=O)O[C@H]1CC@@HC(C)(C)[C@@H]2CC@@H[C@]3(C)C@H[C@@]12C’). Kernel keep restarting after filling up the whole memory because of some python process. I tried this on two machines (win and linux). The same thing happen. Any similar experiences? It seems like this ODDT’s vina wrapper doesn’t work well with larger molecules. It worked fine using vina solely.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: