_mass2tof
returns negative time of flight values for extremely low masses
#68
Labels
_mass2tof
returns negative time of flight values for extremely low masses
#68
Describe the bug
Certain users have started to specify panels with mass ranges 15 or lower. However, the
_mass2tof
function will return a negative time of flight value for these.Because we convert the returned TOF array of
_mass2tof
tonp.uint16
, this causes the final range passed into the corresponding_extract_bin.pyx
function to be incorrect, because any negative values get wrapped around to 65536 + (negative TOF value). Additionally, these TOF ranges will be incredibly large, and if it is part of a lowest-highest TOF range specification, it will cause memory issues.Expected behavior
We'll need to discuss further, I'm not sure what the explanation of a negative TOF value should be.
To Reproduce
Run the function as is, and specify a mass in the provided panel with
"Stop"
equal to 15 or lower.The text was updated successfully, but these errors were encountered: