Menu

Commit [r25495]  Maximize  Restore  History

Fix for inf values beeing returned from C-code exponential function. Values are now converted to high values.

This fixes systemtest Relax_disp.test_finite_value.

Example:
x = np.array([np.inf, -np.inf, np.nan, -128, 128])
np.nan_to_num(x)
array([ 1.79769313e+308, -1.79769313e+308, 0.00000000e+000,
-1.28000000e+002, 1.28000000e+002]
)

bug #22552(https://gna.org/bugs/index.php?22552): Chi2 value returned from C-code Curve-fitting return 0.0 for wrong parameters -> Expected influence on Monte-Carlo sim.
Ref: http://docs.scipy.org/doc/numpy/reference/generated/numpy.nan_to_num.html

tlinnet 2014-08-31

changed /trunk/specific_analyses/relax_fit/optimisation.py
/trunk/specific_analyses/relax_fit/optimisation.py Diff Switch to side-by-side view
Loading...
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.