Eggeling-Lab-Microscope-Software / TRAIT2D

TRAIT2D is a cross-platform Python software package with compilable graphical user interfaces (GUIs) to support Single Particle Tracking experiments.
GNU General Public License v3.0
10 stars 10 forks source link

Runaway "Divide by Zero" warnings in background of analysis GUI #74

Open FReina opened 2 years ago

FReina commented 2 years ago

From the review by Xavier Michalet in the associated paper, the testing of the analysis GUI on one of the test CSV files produces the following warnings

 c:\xxxxx\trait2d test\lib\site-packages\trait2d\analysis\models.py:22: RuntimeWarning: divide by zero encountered in true_divide
  return D + delta**2 / (2*t*(1-2*self.R*self.dt/t))
c:\xxxxx\trait2d test\lib\site-packages\trait2d\analysis\models.py:22: RuntimeWarning: invalid value encountered in multiply
  return D + delta**2 / (2*t*(1-2*self.R*self.dt/t))
c:\xxxxx\trait2d test\lib\site-packages\trait2d\analysis\models.py:34: RuntimeWarning: divide by zero encountered in true_divide
  return D_micro * (tau/t) * (1 - np.exp(-t/tau)) + \
c:\xxxxx\trait2d test\lib\site-packages\trait2d\analysis\models.py:34: RuntimeWarning: invalid value encountered in multiply
  return D_micro * (tau/t) * (1 - np.exp(-t/tau)) + \
c:\xxxxx\trait2d test\lib\site-packages\trait2d\analysis\models.py:35: RuntimeWarning: divide by zero encountered in true_divide
  delta ** 2 / (2 * t * (1 - 2 * self.R * self.dt / t))
c:\xxxxx\trait2d test\lib\site-packages\trait2d\analysis\models.py:35: RuntimeWarning: invalid value encountered in multiply
  delta ** 2 / (2 * t * (1 - 2 * self.R * self.dt / t))
c:\xxxxx\trait2d test\lib\site-packages\trait2d\analysis\models.py:48: RuntimeWarning: divide by zero encountered in true_divide
  D_micro * (tau/t) * (1 - np.exp(-t/tau)) + \
c:\xxxxx\trait2d test\lib\site-packages\trait2d\analysis\models.py:48: RuntimeWarning: invalid value encountered in multiply
  D_micro * (tau/t) * (1 - np.exp(-t/tau)) + \
c:\xxxxx\trait2d test\lib\site-packages\trait2d\analysis\models.py:49: RuntimeWarning: divide by zero encountered in true_divide
  delta ** 2 / (2 * t * (1 - 2 * self.R * self.dt / t))
c:\xxxxx\trait2d test\lib\site-packages\trait2d\analysis\models.py:49: RuntimeWarning: invalid value encountered in multiply
  delta ** 2 / (2 * t * (1 - 2 * self.R * self.dt / t))

These need to be looked at, and eventually addressed in the documentation.