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

Test and fix for mp_f19_decoy_discrimination failure #49

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

roccomoretti
Copy link
Member

The mp_f19_decoy_discrimination scientific test has a hard failure. It's crashing with the following issue in the minimization routine of relax.

core.scoring.hbonds.hbonds_geom: [ ERROR ] NAN occurred in H-bonding calculations!
core.scoring.hbonds.hbonds_geom: [ ERROR ] Dxyz                    -NAN                    -NAN                    -NAN  Hxyz                    -NAN                    -NAN                    -NAN

This PR pulls out the offending run/structure as an integration test.

Playing around with it, I figured out two things

  1. The -constrain_relax_to_start_coords true flag is needed to show symptoms
  2. It was specifically the derivative calculations which were causing NaN issues.

Inserting a number of std::isnan() checks and trying to trace back the source indicates the problem was MembraneGeometry::g_radius_gradient_dz(), specifically where it did a (p.x()-xo)/std::abs(p.x()-xo)), which results in a NaN if p.x() equals xo. We can rearrange this slightly, not only to avoid the NaN, but also to reduce the number of calculations needed. While I was at it, additional efficiency changes in MembraneGeometry were also made.

@roccomoretti roccomoretti added ready_for_review This PR is ready to be reviewed and merged. 90 standard tests labels Apr 16, 2024
@Rituparnasamanta
Copy link
Member

The changes look good to me. elegant fix to the problem. Was the 90 test done once?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
90 standard tests ready_for_review This PR is ready to be reviewed and merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants