Gallicchio-Lab / AToM-OpenMM

OpenMM-based framework for absolute and relative binding free energy calculations with the Alchemical Transfer Method
Other
118 stars 31 forks source link

"Particle coordinate is nan" Error in prep.sh step in ABFE #35

Closed satvikkg closed 11 months ago

satvikkg commented 1 year ago

Hi, I am getting an error saying "Particle coordinate is nan" Error in prep.sh in the annealing to lambda step. Until then everything runs smoothly.

egallicc commented 1 year ago

This behavior usually points to setup issues with the alchemical schedule or the displacement vector.

A large ligand could also cause failures in ABFE. ABFE with more than 20 heavy atoms is unlikely to work, but this issue has yet to be studied systematically.

satvikkg commented 1 year ago

Thank you for the clarification. Can we expect a fix for this error in the near future ?

egallicc commented 1 year ago

Do you suspect a bug? Did you find a workaround?

satvikkg commented 1 year ago

No @egallicc I don't even know where to begin.

egallicc commented 1 year ago

It's likely a setup issue rather than a bug. Please post the input (.prmtop, .inpcrd, .cntl files) if you need help figuring out the problem.

satvikkg commented 1 year ago

I have attached the .prmtop, .inpcrd, .cntl files. It would be really great if you could help me figure it out. bace1-error.zip

qsabanes commented 1 year ago

As @egallicc points out, it should probably a set-up issue. In my case, when this happens is usually due to an unoptimal selection of restraining atoms. Have you tried with different complexes to see if you get the same error?

egallicc commented 1 year ago

The residues selected for the binding site do not appear to surround the ligand. The binding site restraint would exert a large force on the ligand and cause the MD crash.

image

To test this hypothesis, turn off the binding site restraint by setting CM_KF = 0.0 in asyncre_template.cntl and run the setup and abfe_structprep.py again. If the test is successful, find a better set of protein residues to define the binding site volume. The center of mass of the C-alpha atoms of these residues should be near the CM of the ligand.

As a side note: in absolute binding free energy (ABFE) calculations such as this one the definition of the binding site volume is definitively necessary. Without it, the ligand would wander away from the receptor in the unbound state. The definition of the binding site volume is less of a concern in relative binding free energy (RBFE) calculations between strong binders.

Also, ABFE calculations are much more difficult than RBFE calculations. Do you require ABFE for a specific reason? RBFE is the norm for ligand pairs this similar.