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

Mk_prepare_ligand fails for Vanadium-containing ligands #307

Open
frgoe003 opened this issue Jan 9, 2025 · 3 comments
Open

Mk_prepare_ligand fails for Vanadium-containing ligands #307

frgoe003 opened this issue Jan 9, 2025 · 3 comments
Assignees

Comments

@frgoe003
Copy link

frgoe003 commented Jan 9, 2025

I noticed that the ligand preparation pipeline seems to fail for vanadium-containing ligands. Seems to be an issue with charge assignment:

..
atom number 23 has non finite charge, mol name: 1.B, charge: nan
atom number 24 has non finite charge, mol name: 1.B, charge: nan
atom number 25 has non finite charge, mol name: 1.B, charge: inf
..

Raised from meeko/writer.py

Code to reproduce:
mk_prepare_ligand.py -i AD9.sdf -o AD9.pdbqt

Examples:
AD9 from PDB 3MJX
-> AD9.sdf.zip

AOV from PDB 4AE3

@rwxayheee
Copy link
Contributor

rwxayheee commented Jan 9, 2025

Hi @frgoe003
I have a PR pending review: #273. It provides the charge method to support the complicated chemical group involving metals. Please give it a try.

It takes two steps:
(1) Please check out my branch from PR #273 (equivalently this branch) and install with pip install -e ..

(2) Even with the charging method, it's required to manually put in the additional atom types. In your local branch, please edit this file: <directory to the downloaded repository>/Meeko/meeko/data/params/ad4_types.json
Add a new line anywhere, for example, after Mg:

    {"smarts": "[#12]",             "atype": "Mg"},
    {"smarts": "[#23]",             "atype": "V"},

To declare a unique autodock atom type for generic V atoms.

Now, you can run the command:
mk_prepare_ligand.py -i AD9.sdf

My output is:
AD9.pdbqt.txt

We would like to know your feedback and suggestions in handling these ligands. Please let us know what you think and if you have any further questions.

@rwxayheee rwxayheee self-assigned this Jan 10, 2025
@MatthewWiens101
Copy link

Hi @rwxayheee thank you for providing a solution to this, I have encountered what I believe to be the same issue with potassium and calcium metal complexes (not sure if these would cause complex bonds, I am new to this field):

Output:

atom number 0 has None type, mol name:
atom number 0 has None type, mol name:
atom number 0 has non finite charge, mol name: , charge: nan
atom number 1 has non finite charge, mol name: , charge: nan
atom number 2 has non finite charge, mol name: , charge: nan
...

I will try out your branch, but I will look forward to completion of the PR, hope it goes forward.

@rwxayheee
Copy link
Contributor

rwxayheee commented Feb 6, 2025

Hi @MatthewWiens101

Thank you! I think the PR is ready; it's also up-to-date with the most recent develop branch. But before it's merged needs to be reviewed and maybe discussed again with my lab. We (including myself) are a bit hesitant because - even though it technically works and provides a way to assign charges for metal complexes, none of us has extensively tested the charge method, as we're a bit caught up with other projects.

I made this PR with the hope of encouraging more users/developers/chemists to help us explore this method, and tell us whether this is valid for their systems. This method is, at least, a working charge model with the gasteiger charge, which itself is not much more accurate in my opinion.. However, a very, very big limitation with this method is: It is completely blind to metal element types and more of a charge-redistribution method rather than a charge model. The only property taken into account is the charge and valence state of the metal, regardless of its identity. This means, if we have a Copper(II) - porphyrin complex and Iron (II) - porphyrin complex, the partial charge of these metal centers could be the same, which in reality shall be different. If your calculation aims at evaluating the difference between metal types in the system, then this method is not suitable

I do not see myself working on a new project that develops a new charge model of metal complexes for docking in the near future. However, I believe there are ways to physically derive the partial charges (for example, natural population analysis) and maybe modern, more recently developed charge models that are specialized for metal complexes. If you want to import charges from a third-party software, or a database, you can use the additional feature in this PR (#258 (comment)), which is currently available the develop branch.

I really hoped you could give it a try, but I understand the concerns you may have about using it. If you have a specific charge method that you would wish to be available in Meeko, please let us know and maybe we can work together to create a pythonic workflow to integrate it :D

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

No branches or pull requests

3 participants