pymepix icon indicating copy to clipboard operation
pymepix copied to clipboard

Paketprocessor throws exception if amount of triggers is not enough

Open BenMoon opened this issue 2 years ago • 0 comments

For the edge case that the packetprocessor.py receives not enough triggers, basepipeline.py:run terminate the while loop in line 200 with this stack trace:

Traceback (most recent call last):
  File "/miniconda3/envs/timepix/lib/python3.7/multiprocessing/process.py", line 297, in _bootstrap
    self.run()
  File "/timepix/pymepix/pymepix/processing/basepipeline.py", line 191, in run
    output_type, result = self.process()
  File "/timepix/pymepix/pymepix/processing/packetprocessor.py", line 182, in process
    events = self.find_events_fast()
  File "/timepix/pymepix/pymepix/processing/packetprocessor.py", line 222, in find_events_fast
    self._trigger_counter = trigger_counter[-1] + 1
IndexError: index -1 is out of bounds for axis 0 with size 0

To reproduce this, we use the UDPsampler with 0.01 which gets terminated arbitrarily. The data-set being used is run0017 from 2019.

BenMoon avatar Jul 23 '21 14:07 BenMoon