You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Loading a protein with a C terminal amide (NH2) cap using Molecule.from_polymer_pdb fails.
To Reproduce
MWE using ACE-ALA-NH2 Molecule.from_polymer_pdb('ace-ala-nh2.pdb') with the following PDB file:
ATOM 1 HH33 ACE A 0 -5.284 -2.981 5.320 1.00 0.00
ATOM 2 CH3 ACE A 0 -4.851 -3.877 5.426 1.00 0.00
ATOM 3 HH31 ACE A 0 -5.412 -4.481 6.144 1.00 0.00
ATOM 4 HH32 ACE A 0 -4.840 -4.406 4.474 1.00 0.00
ATOM 5 C ACE A 0 -3.431 -3.679 5.966 1.00 0.00
ATOM 6 O ACE A 0 -2.705 -2.809 5.481 1.00 0.00
ATOM 7 N ALA A 1 -2.983 -4.446 6.956 1.00 0.00
ATOM 8 CA ALA A 1 -1.682 -4.415 7.599 1.00 0.00
ATOM 9 CB ALA A 1 -1.818 -3.599 8.890 1.00 0.00
ATOM 10 C ALA A 1 -1.154 -5.834 7.868 1.00 0.00
ATOM 11 O ALA A 1 -1.891 -6.699 8.345 1.00 0.00
ATOM 12 H ALA A 1 -3.478 -5.294 6.716 1.00 0.00 H
ATOM 13 HA ALA A 1 -1.025 -3.946 6.994 1.00 0.00 H
ATOM 14 HB1 ALA A 1 -2.653 -3.055 8.848 1.00 0.00 H
ATOM 15 HB2 ALA A 1 -1.860 -4.221 9.669 1.00 0.00 H
ATOM 16 HB3 ALA A 1 -1.028 -2.996 8.983 1.00 0.00 H
ATOM 17 N NH2 A 2 0.110 -6.138 7.586 1.00 0.00
ATOM 18 HN1 NH2 A 2 0.717 -5.444 7.199 1.00 0.00
ATOM 19 HN2 NH2 A 2 0.453 -7.061 7.761 1.00 0.00
TER
END
Output
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: type object 'Molecule' has no attribute 'from_polymer'. Did you mean: 'from_polymer_pdb'?
>>> offmol = Molecule.from_polymer_pdb('ace-ala-nh2.pdb')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/ccavende/anaconda3/envs/openff-proteinbenchmark/lib/python3.10/site-packages/openff/utilities/utilities.py", line 80, in wrapper
return function(*args, **kwargs)
File "/home/ccavende/anaconda3/envs/openff-proteinbenchmark/lib/python3.10/site-packages/openff/toolkit/topology/molecule.py", line 3855, in from_polymer_pdb
offmol = toolkit_registry.call(
File "/home/ccavende/anaconda3/envs/openff-proteinbenchmark/lib/python3.10/site-packages/openff/toolkit/utils/toolkit_registry.py", line 356, in call
raise e
File "/home/ccavende/anaconda3/envs/openff-proteinbenchmark/lib/python3.10/site-packages/openff/toolkit/utils/toolkit_registry.py", line 352, in call
return method(*args, **kwargs)
File "/home/ccavende/anaconda3/envs/openff-proteinbenchmark/lib/python3.10/site-packages/openff/toolkit/utils/openeye_wrapper.py", line 259, in _polymer_openmm_topology_to_offmol
oemol = self._polymer_openmm_topology_to_oemol(omm_top, substructure_dictionary)
File "/home/ccavende/anaconda3/envs/openff-proteinbenchmark/lib/python3.10/site-packages/openff/toolkit/utils/openeye_wrapper.py", line 362, in _polymer_openmm_topology_to_oemol
raise UnassignedChemistryInPDBError(
openff.toolkit.utils.exceptions.UnassignedChemistryInPDBError: Some bonds or atoms in the input could not be identified.
Computing environment (please complete the following information):
* fix#1579 and add test
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* update file names and release history
---------
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Describe the bug
Loading a protein with a C terminal amide (NH2) cap using
Molecule.from_polymer_pdb
fails.To Reproduce
MWE using ACE-ALA-NH2
Molecule.from_polymer_pdb('ace-ala-nh2.pdb')
with the following PDB file:Output
Computing environment (please complete the following information):
conda list
Additional context
Loading a protein with an NME cap works as intended. Using the python debugger, I can find
So it looks like the bond between "N" in the NH2 cap and the carbonyl "C" in the previous residue is not recognized.
The text was updated successfully, but these errors were encountered: