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

correct merging of [ atomtypes ] when bondtypes are used within. #21

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

Conversation

zetadin
Copy link

@zetadin zetadin commented Oct 27, 2021

Merging [ atomtypes ] with _merge_FF_files() in alchemy.py was retaining only the first 6 columns.
However when [ atomtypes ] also had a bond type or an atom number column, the final epsilon column would get cut off.
Eg.
c3 c3 0.00000 0.00000 A 3.39967e-01 4.57730e-01
would become
c3 c3 0.00000 0.00000 A 3.39967e-01
when we want
c3 0.00000 0.00000 A 3.39967e-01 4.57730e-01

This change parses the input [ atomtypes ], recognizes whether these optional columns are present, and outputs only the required columns (ie no bond type and no atom number) into the merged file.

There is also a new unit test to verify functionality on both GAFF and OPLS atomtypes formats.
CGENFF ligands tend to directly include the charmm ff and have empty [ atomtypes ] sections, so testing on them is pointless.

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.

1 participant