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
We have a simulation that does not trigger an ignition (the temperature never rises quite enough) and end up with 'average error function' of Inf and 'average deviation function' of -Inf. for the whole data set.
# calculate error function for this dataseterror_func=numpy.power(
(numpy.log(ignition_delays_sim) -numpy.log(ignition_delays_exp)) /standard_dev, 2
)
error_func=numpy.nanmean(error_func)
I'm guessing the nanmean is supposed to take a mean excluding NaN values, but the result of numpy.log(ignition_delays_sim) is not NaN but is -Inf when no ignition is detected, because process_results() sets ignition delay to zero if no ignition:
else:
warnings.warn('No ignition for case '+self.meta['id'] +', setting value to 0.0 and continuing',
RuntimeWarning
)
self.meta['simulated-ignition-delay'] =0.0*units.second
So we end up with 'average error function' of Inf and 'average deviation function' of -Inf.
Should we exclude infinities before averaging? include them somehow?
I guess technically it is an infinite error, but that doesn't help you rank things!
The text was updated successfully, but these errors were encountered:
We have a simulation that does not trigger an ignition (the temperature never rises quite enough) and end up with
'average error function'
of Inf and'average deviation function'
of -Inf. for the whole data set.Looking at
PyTeCK/pyteck/eval_model.py
Line 405 in bba7984
I'm guessing the
nanmean
is supposed to take a mean excluding NaN values, but the result ofnumpy.log(ignition_delays_sim)
is not NaN but is -Inf when no ignition is detected, becauseprocess_results()
sets ignition delay to zero if no ignition:So we end up with
'average error function'
of Inf and'average deviation function'
of -Inf.Should we exclude infinities before averaging? include them somehow?
I guess technically it is an infinite error, but that doesn't help you rank things!
The text was updated successfully, but these errors were encountered: