XENONnT / straxen

Streaming analysis for XENON
BSD 3-Clause "New" or "Revised" License
19 stars 33 forks source link

Save `max_time` in `lone_hits` #1360

Open dachengx opened 3 months ago

dachengx commented 3 months ago

In strax.hit_dtype https://github.com/AxFoundation/strax/blob/ebcb699fd85edb30b133fcb00e48dafa46faca4c/strax/dtypes.py#L103, there is no field telling you about the time in the lone_hits where the records reached the maximum. It can be easily calculated by straxen.plugins.peaklets.peaklets.hit_max_sample https://github.com/XENONnT/straxen/blob/02210f9650dddfbd4600f765ed92ad2f5a39919d/straxen/plugins/peaklets/peaklets.py#L321.

But to do it, we need to first modify strax.hit_dtype.