Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve basic support for elements (single-atom residues, metal, noble gas) that are unsupported by ad4 #259

Open
wants to merge 12 commits into
base: develop
Choose a base branch
from

Conversation

rwxayheee
Copy link
Contributor

@rwxayheee rwxayheee commented Dec 1, 2024

This is for #252. Although still very primitive, it has the basic support to allow all elements (1-118 is this even necessary), single-atom residues, metal or noble gas to be in receptor (polymer).

Here's a summary of major changes:

  1. Removed redundant reference tables: covalent_radius from meeko.utils.rdkitutils, mini_periodic_table from meeko.utils.utils
    They were replaced by the equivalent references, which are:
from .utils.covalent_radius_table import covalent_radius
from meeko.utils.autodock4_atom_types_elements import autodock4_atom_types_elements
periodic_table = Chem.GetPeriodicTable()

Made some other minimal adjustments in accordance to the replacement.

  1. When constructing a polymer, always not make intermol (between two monomers) bonds involving metal or noble gas, since there isn't a good solution for padding either.

  2. Allow single-atom residues and stop checking for unsupported elements in template generation.
    Single-atom residues like Co2+, Ar, etc., although not registered, they can now be fetched from PDB (CCD) and will have integer charges unless overridden by user. The template will always be built following the unbound ligand routine not linked.

  3. For receptor preparation involving ad4-unsupported elements, it's always possible to generate the receptor json/pdb file but the PDBQT file requires a valid atom type in the parameter file. Unspecified atom type shall not be forgiven and the error message will be:

RuntimeError: Cannot write PDBQT file. The following atom does not have an atom type: 
ATOM   3411  CO  CO  A 501       4.245  -2.575  79.904  1.00  0.00     2.000 None
Consider declaring a custom atom type in the parameter file or revising the input structure. 
  1. Some small fixex for CLI script mk_prepare_receptor.py
  • Print error message and exit, when ProDy parser is invoked but extension of input file is unsupported.
  • Fixed a small problem with --write_pdb
  • polymer.to_pdb() writes element in columns 78-79, which should be 77-78. This made our output PDB not readable by some parsers (including mk_prepare_receptor iteself). Fixed in 9391c01

@rwxayheee rwxayheee requested a review from diogomart December 1, 2024 06:33
@rwxayheee rwxayheee changed the base branch from develop to release December 1, 2024 06:33
@rwxayheee rwxayheee changed the base branch from release to develop December 1, 2024 07:16
@diogomart diogomart changed the base branch from develop to release December 4, 2024 19:43
@diogomart diogomart changed the base branch from release to develop December 4, 2024 19:43
@rwxayheee rwxayheee linked an issue Dec 11, 2024 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support for metal atoms
1 participant