36 for(
auto const& ptr : clusters)
if(!ptr)
return -1;
38 std::vector<util::PxHit> hits0;
39 std::vector<util::PxHit> hits1;
40 std::vector<util::PxHit> hits2;
43 for(
auto const&
c : clusters)
54 if(
c->Plane() ==0) hits0 =
c->GetHitVector();
55 if(
c->Plane() ==1) hits1 =
c->GetHitVector();
56 if(
c->Plane() ==2) hits2 =
c->GetHitVector();
100 std::vector<float> tprofmatches;
102 tprofmatches.push_back(tprof01);
103 tprofmatches.push_back(tprof02);
104 tprofmatches.push_back(tprof12);
109 for(
unsigned int a=0;
a<tprofmatches.size();
a++)
111 if(tprofmatches[
a]==-1)
continue;
113 matchscore +=tprofmatches[
a];
120 matchscore /= avgcounter;
146 std::vector< std::vector<TH1D*> > signals(nplanes);
147 std::vector< std::vector<TH1D*> > pulses(nplanes);
155 for(
auto const&
h : hita) {
156 if(
h.t > max_time) max_time =
h.t;
157 if(
h.t < min_time) min_time =
h.t;
159 for(
auto const&
h : hitb) {
160 if( (
h.t + time_diff) > max_time ) max_time =
h.t +
time_diff;
161 if( (
h.t + time_diff) < min_time ) min_time =
h.t +
time_diff;
164 TH1D histo_a(
"ha",
"", 200, min_time-1, max_time+1);
165 TH1D histo_b(
"hb",
"", 200, min_time-1, max_time+1);
166 TH1D histo_inta(
"hinta",
"", 200, min_time-1, max_time+1);
167 TH1D histo_intb(
"hintb",
"", 200, min_time-1, max_time+1);
171 for(
auto const& ha : hita){
174 double charge = ha.charge;
176 int bin = histo_a.FindBin(time);
177 histo_a.SetBinContent(bin,histo_a.GetBinContent(bin)+charge);
178 for (
int j = bin; j<=histo_a.GetNbinsX(); ++j){
179 histo_inta.SetBinContent(j,histo_inta.GetBinContent(j)+charge);
182 if (histo_inta.Integral()) histo_inta.Scale(1./histo_inta.GetBinContent(histo_inta.GetNbinsX()));
183 for(
auto const& hb : hitb){
186 double charge = hb.charge;
187 int bin = histo_b.FindBin(time);
188 histo_b.SetBinContent(bin,histo_b.GetBinContent(bin)+charge);
189 for (
int j = bin; j<=histo_b.GetNbinsX(); ++j){
190 histo_intb.SetBinContent(j,histo_intb.GetBinContent(j)+charge);
203 if (histo_intb.Integral()) histo_intb.Scale(1./histo_intb.GetBinContent(histo_intb.GetNbinsX()));
204 ks = histo_inta.KolmogorovTest(&histo_intb);
Double_t TimeToCm() const
double time_diff(rusage const &a, rusage const &b)
virtual unsigned int NumberTimeSamples() const =0
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
QTextStream & bin(QTextStream &s)
Class def header for a class CFAlgoTimeProf.
QTextStream & endl(QTextStream &s)
h
training ###############################
virtual double GetXTicksOffset(int p, int t, int c) const =0