goldsluice.reference.rise_time¶
Python mirror of src/rise_time.rs: the 10-90 % rise time of the largest pulse of a trace (s), as goldpan.algorithms.rise_time.
For one trace x of n samples:
baseline= mean ofx[glitch_samples:pretrigger_samples], andy[i] = x[i] - baseline;the peak is the first largest
yover allnsamples (the glitch and the window included), at indexpeakwith heightamp;i_lo(i_hi) = the last indexi <= peakwithy[i] < lo * amp(hi * amp), or -1 if there is none;rise_time_s=(i_hi - i_lo) * sample_period_s, andnanunlessamp > 0and both indices were found (a trace with no positive peak, or that never lies below thelolevel before its peak).
lo and hi have no defaults here (the collaboration’s 10 and 90 % are lo = 0.1, hi = 0.9): they are part of the definition of
the quantity, so a definition file writes them. This file is written in the kernel subset (see PORTING.md) so that it can be
ported to Rust line by line.
Functions
Inputs both versions must refuse, with the same message: |
|
|
The standard inputs the parity test runs both versions on: |
|
The same numbers from |
|
|
|
Why the parameters do not fit a trace of |
- goldsluice.reference.rise_time.goldpan_expected(traces, params)[source]¶
The same numbers from
goldpan.algorithms.rise_time:{output: array}.
- goldsluice.reference.rise_time.problem(n_samples, glitch_samples, pretrigger_samples, sample_period_s, lo, hi)[source]¶
Why the parameters do not fit a trace of
n_samples, orNoneif they do.
- goldsluice.reference.rise_time.kernel(trace, glitch_samples, pretrigger_samples, sample_period_s, lo, hi)[source]¶