Meeko: preparation of small molecules for AutoDock
Meeko reads an RDKit molecule object and writes a PDBQT string (or file) for AutoDock-Vina and AutoDock-GPU. Additionally, it has tools for post-processing of docking results which are not yet fully developed. Meeko supports the following features:
- Docking with explicit water molecules attached to the ligand (paper)
- Sampling of macrocyclic conformations during docking (paper)
- Creation of RDKit molecules with docked coordinates from PDBQT or DLG files without loss of bond orders.
Meeko is developed by the Forli lab at the Center for Computational Structural Biology (CCSB) at Scripps Research.
Dependencies
- Python (>=3.5)
- Numpy
- Scipy
- RDKit
Conda or Miniconda can install the dependencies:
conda install -c conda-forge numpy scipy rdkit
Installation (from PyPI)
$ pip install meeko
If using conda, pip installs the package in the active environment.
Installation (from source)
$ git clone https://github.com/forlilab/Meeko
$ cd Meeko
$ pip install .
Optionally include --editable. Changes in the original package location
take effect immediately without the need to run pip install . again.
$ pip install --editable .
Usage notes
Meeko does not calculate 3D coordinates or assign protonation states. Input molecules must have explicit hydrogens.
Examples using the command line scripts
mk_prepare_ligand.py -i molecule.sdf -o molecule.pdbqt
mk_prepare_ligand.py -i multi_mol.sdf --multimol_outdir folder_for_pdbqt_files
mk_copy_coords.py vina_results.pdbqt -o vina_results.sdf
mk_copy_coords.py adgpu_results.dlg -o adgpu_results.sdf
Quick Python tutorial
1. flexible macrocycle with attached waters
from meeko import MoleculePreparation
from rdkit import Chem
input_molecule_file = 'example/BACE_macrocycle/BACE_4.mol2'
mol = Chem.MolFromMol2File(input_molecule_file)
preparator = MoleculePreparation(hydrate=True) # macrocycles flexible by default since v0.3.0
preparator.prepare(mol)
preparator.show_setup()
output_pdbqt_file = "test_macrocycle_hydrate.pdbqt"
preparator.write_pdbqt_file(output_pdbqt_file)
Alternatively, the preparator can be initialized from a dictionary,
which is useful for saving and loading configuration files with json.
The command line tool mk_prepare_ligand.py can read the json files.
import json
from meeko import MoleculePreparation
mk_config = {"hydrate": True}
print(json.dumps(mk_config), file=open('mk_config.json', 'w'))
with open('mk_config.json') as f:
mk_config = json.load(f)
preparator = MoleculePreparation.from_config(mk_config)
2. RDKit molecule from docking results
Assuming that 'docked.dlg' was written by AutoDock-GPU and that Meeko prepared the input ligands.
from meeko import PDBQTMolecule
with open("docked.dlg") as f:
dlg_string = f.read()
pdbqt_mol = PDBQTMolecule(dlg_string, is_dlg=True, skip_typing=True)
# alternatively, read the .dlg file directly
pdbqt_mol = PDBQTMolecule.from_file("docked.dlg", is_dlg=True, skip_typing=True)
for pose in pdbqt_mol:
rdkit_mol = pose.export_rdkit_mol()
For Vina's output PDBQT files, omit is_dlg=True.
pdbqt_mol = PDBQTMolecule.from_file("docking_results_from_vina.pdbqt", skip_typing=True)
Release files for meeko 0.3.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| meeko-0.3.2.tar.gz | 64.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| meeko-0.3.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 147.7 kB
Release files / meeko-0.3.2.tar.gz
| Download URL | meeko-0.3.2.tar.gz |
|---|---|
| Size | 64.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
97bdf78628db2e0d473ef9942b73d3e01e85e92c20b572d1752326cc91437cb4
|
|
BLAKE2b-256 checksum How to use checksums |
04fd03d4d7fb97c6ce5789eea55cc8a5a27b3c9ba2e9e8944c46855d0356786d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.63.0 importlib-metadata/4.11.2 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.2
|
Release files / meeko-0.3.2-py3-none-any.whl
| Download URL | meeko-0.3.2-py3-none-any.whl |
|---|---|
| Size | 83.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
0aa671be6f0e1ab88d4df31c60151f95757f8cb967a92b2ff2f0d746a20a445e
|
|
BLAKE2b-256 checksum How to use checksums |
1a9d28755e7eb7679082f4e00ef3e9ad3365e9f90c0d341e95289306a7d10831
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.63.0 importlib-metadata/4.11.2 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.2
|