Update for new strax version
Created by: JelleAalbers
This updates straxen for the upcoming strax v0.9.0 release. This will be the biggest strax change since strax was born. Details are in https://github.com/AxFoundation/strax/pull/235.
For straxen, the changes are:
- Add a
refresh_raw_records
script to convert existingraw_records
data to the new format. All other data has to be reprocessed fromraw_records
. The raw_records hash does not change. - Update the DAQReader to:
- Output strax.Chunks instead of raw numpy arrays. This requires the new settings
daq_chunk_duration
anddaq_overlap_chunk_duration
to be passed. - Create artificial deadtime, indicated by signals in the non-existent channel 799, when the data is too dense to break it over chunks. This was always envisaged but never implemented: now that chunk starts/stops must be specified, the old kludge of just letting data hang over the chunk breaks if needed (and silently corrupting the results) would not work anymore.
- No longer baseline and fliip the data. This is done in PulseProcessing, so raw_records really is just the raw output of the digitizers (with baselines around 16000 and signals pointing down)
- Output strax.Chunks instead of raw numpy arrays. This requires the new settings
- Update the PulseProcessing plugin to do baselining, flipping and integration of records. The artificial deadtime markers in channel 799 are not yet processed.
- Update the other plugins to
- Add time and endtime fields to all data types. These are mandatory from now on.
- Remove some hacks to compensate for the sloppy empty-data handling of the previous strax versions.
I tested this by:
- Converting our favorite 1-minute run 180215_1029 with
refresh_raw_records
- Running the
fake_daq
with this as input - Processing this to event_info (with and without multiprocessing)
- Verifying that the result still has nice-looking events with
plot_waveform
The pax conversion plugin has not yet been updated.