root
root copied to clipboard
Make IsAboveMaxEdm() return true if Edm is NaN
Minuit2's MnHesse sometimes returns success, but the matrix contains only NaN values (this should be fixed, but that is a bigger issue not addressed here).
In this case, IsAboveMaxEdm() returns false, since NaN < threshold is false, irregardless of the threshold. This leads to Minuit2 wrongly reporting that the minimum is "valid".
This fix makes sure that IsAboveMaxEdm() returns true if the Edm value is NaN, which is not perfect but better than the current confusing behavior.
Checklist:
- [x] tested changes locally
Can one of the admins verify this patch?