34 bool _positive)
const override;
50 std::vector<double> wf_aux(ped_pulse);
52 for (
size_t ix = 0; ix < wf_aux.size(); ix++) {
53 wf_aux[ix] = ((double)wf_pulse[ix]) - wf_aux[ix];
57 for (
size_t ix = 0; ix < wf_aux.size(); ix++) {
58 wf_aux[ix] = wf_aux[ix] - ((double)wf_pulse[ix]);
62 auto it_max = max_element(wf_aux.begin(), wf_aux.end());
63 size_t rise = std::lower_bound(wf_aux.begin(), it_max,
fPeakRatio * (*it_max)) - wf_aux.begin();
fhicl::Atom< double > PeakRatio
RiseTimeThreshold(art::ToolConfigTable< Config > const &config)
Interfacce class for a tool to calculate the pulse rise time.
double RiseTime(const pmtana::Waveform_t &wf_pulse, const pmtana::PedestalMean_t &ped_pulse, bool _positive) const override
std::vector< short > Waveform_t
std::vector< double > PedestalMean_t