You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
clarity/evaluator/msbg/smearing.py tests failing with numpy 1.25 or later.
Tracked it down to the smear3 function in smearing.py which computes power by multiply complex number by its conjugate, which should give a real result but in the newer numpy there are precision errors.
Solution is to use np.abs to get the length and then square it. In smear3() the function needs to look like this.
clarity/evaluator/msbg/smearing.py tests failing with numpy 1.25 or later.
Tracked it down to the smear3 function in smearing.py which computes power by multiply complex number by its conjugate, which should give a real result but in the newer numpy there are precision errors.
Solution is to use np.abs to get the length and then square it. In smear3() the function needs to look like this.
With this it passes the tests with all numpy versions, i.e. 1.24 or 1.25
The text was updated successfully, but these errors were encountered: