24 const double BeamWindowMinMicroSec = 217;
25 const double BeamWindowMaxMicroSec = 229;
26 const double PeakShiftMicroSec = 64;
27 const int LastBadTimingRun = 17945;
32 <<
"the mean time is " <<
time 33 <<
"\ncurrent Run " <<
fCurrentRun <<
"/" << LastBadTimingRun
34 <<
"\nbeam window min " << 1000 * BeamWindowMinMicroSec
35 <<
"\nbeam window max " << 1000 * BeamWindowMaxMicroSec
36 <<
"\nbeam offset " << 1000 * PeakShiftMicroSec;
39 time > 1000 * (BeamWindowMinMicroSec + PeakShiftMicroSec) &&
40 time < 1000 * (BeamWindowMaxMicroSec + PeakShiftMicroSec))
return true;
42 if(
time > 1000 * BeamWindowMinMicroSec &&
43 time < 1000 * BeamWindowMaxMicroSec)
return true;
52 std::bitset<14> binary,
56 int testDB = (plane / 64);
57 int minblock = testDB;
58 int maxblock = testDB;
60 for (
int i=testDB-1;
i>=0; --
i){
61 if (binary[
i]) minblock=
i;
64 for (
int i=testDB+1;
i<14; ++
i){
65 if (binary[
i]) maxblock=
i;
68 return std::pair<int, int>(64*(minblock), 64*(maxblock+1)-1);
79 std::bitset<14> binary(dibmask);
86 <<
" " << planesA.first <<
" " << planesA.second
87 <<
" " << planesB.first <<
" " << planesB.second
88 <<
" " << (planesA.second - planesA.first + 1)/64 <<
" > 3";
90 if ((planesA.first != planesB.first) || (planesA.second != planesB.second))
94 return ((planesA.second - planesA.first + 1) * 0.015625 > 3);
#define LOG_DEBUG(stream)
novadaq::cnv::DetId fDetId
the id of the detector we are looking at
std::pair< int, int > calcFirstLastLivePlane(int plane, std::bitset< 14 > binary, novadaq::cnv::DetId det)
A collection of associated CellHits.
bool CheckTiming(rb::Cluster const &slice)
Far Detector at Ash River, MN.
unsigned int MinPlane(geo::View_t view=geo::kXorY) const
double MeanTNS(rb::AveragingScheme scheme=kDefaultScheme) const
unsigned int MaxPlane(geo::View_t view=geo::kXorY) const
int fCurrentRun
the current run number
int GoodDiBlockMask(int subrun=-1, bool reload=false)
bool CheckSliceQuality(rb::Cluster const &slice)