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

key "HB1" not found in forcefield #124

Open
overshiki opened this issue Apr 27, 2023 · 1 comment
Open

key "HB1" not found in forcefield #124

overshiki opened this issue Apr 27, 2023 · 1 comment

Comments

@overshiki
Copy link

Hi,
I'm trying to use Molly.jl to reproduce some of the work I have done in Gromacs, however, it raises error in System building stage.
Specifically, I use the following Gromacs commands to prepare the pdb file(with water box and ions):

gmx pdb2gmx -ff amber99sb -f input.pdb -water spce -ignh -o pro.pdb #-ff forcefiled; -f input file
gmx editconf -f pro.pdb -o pro-box.pdb -d 1.0 -bt octahedron #Add box
gmx solvate -cp pro-box.pdb -cs spc216.gro -p topol.top -o pro-sol.gro #Add solvate
gmx grompp -f em-steep.mdp -c pro-sol.gro -p topol.top -o ion.tpr -maxwarn 1 
echo 14 | gmx genion -s ion.tpr -neutral -conc 0.15 -p topol.top -o pro-ion.pdb 

And use the following Molly.jl code to generate the system:

using Molly
ff = MolecularForceField("ff99SB.xml", "spce_standard.xml")
sys = System("pro-ion.pdb", ff)

the ff99SB.xml and spce_standard.xml files are found from openmm source code.

This gives me the following error:

ERROR: LoadError: KeyError: key "HB1" not found

and a lot of warning:

┌ Warning: PDB reader: found unexpected, non-standard atom 'CD1' in residue 'ILE' (resid 527)
└ @ Chemfiles ~/.julia/packages/Chemfiles/NoLfC/src/misc.jl:29
┌ Warning: PDB reader: found unexpected, non-standard atom 'CD1' in residue 'ILE' (resid 527)
└ @ Chemfiles ~/.julia/packages/Chemfiles/NoLfC/src/misc.jl:29
┌ Warning: PDB reader: found unexpected, non-standard atom 'CD1' in residue 'ILE' (resid 527)
└ @ Chemfiles ~/.julia/packages/Chemfiles/NoLfC/src/misc.jl:29
┌ Warning: PDB reader: found unexpected, non-standard atom 'O' in residue 'LYS' (resid 528)
└ @ Chemfiles ~/.julia/packages/Chemfiles/NoLfC/src/misc.jl:29
┌ Warning: PDB reader: found unexpected, non-standard atom 'O' in residue 'LYS' (resid 528)

...

I know the process of combining openmm, Gromacs and Molly.jl toolchain is kind of error prone. However, since Molly.jl currently does not have toolset for processing pdb files(creating water box, adding ions, etc), this is the best I come up with...

Do you have any clues about what's going on here? Any suggestions on pdb preparation for Molly.jl?

@jgreener64
Copy link
Collaborator

This certainly is an area where Molly is lacking features at the moment. In this case it looks like the atom names in the PDB file are different from those in the XML force field. Currently they have to match exactly, whereas more mature software matches residues based on topology and allows different atom names.

This issue can be left open to track this. In the mean time I would consider using OpenMM's protein preparation tools, which should match their force field file better. The system you get out won't be directly comparable to the Gromacs system, but depending on system size you may struggle to sample long enough with Molly to make a direct comparison anyway.

All of this will hopefully be fixed long term. More robust setup tools is on the todo list but not at the top.

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

2 participants