17#ifdef HAS_RNTUPLE_SUPPORT
18#include "ROOT/RNTupleModel.hxx"
19#include "ROOT/RNTupleWriter.hxx"
20#include "ROOT/RField.hxx"
27#ifdef __USE_DATABASE__
28#include "QwParitySchema.h"
117 for(
size_t i=0;i<this->
fWord.size();i++)
119 this->
fWord[i].fWordName=source.
fWord[i].fWordName;
121 this->
fWord[i].fWordType=source.
fWord[i].fWordType;
156 (
"helicity.seed", po::value<int>(),
157 "Number of bits in random seed");
159 (
"helicity.bitpattern", po::value<std::string>(),
160 "Helicity bit pattern: 0x1 (pair), 0x9 (quartet), 0x69 (octet), 0x666999 (hexo-quad), 0x66669999 (octo-quad)");
162 (
"helicity.patternoffset", po::value<int>(),
163 "Set 1 when pattern starts with 1 or 0 when starts with 0");
165 (
"helicity.patternphase", po::value<int>(),
166 "Maximum pattern phase");
168 (
"helicity.delay", po::value<int>(),
169 "Default delay is 2 patterns, set at the helicity map file.");
171 (
"helicity.toggle-mode", po::value<bool>()->default_bool_value(
false),
172 "Activates helicity toggle-mode, overriding the 'delay', 'patternphase', 'bitpattern', and 'seed' options.");
181 if (options.
HasValue(
"helicity.patternoffset")) {
182 if (options.
GetValue<
int>(
"helicity.patternoffset") == 1
183 || options.
GetValue<
int>(
"helicity.patternoffset") == 0) {
189 if (options.
HasValue(
"helicity.patternphase")) {
190 if (options.
GetValue<
int>(
"helicity.patternphase") % 2 == 0) {
196 if (options.
HasValue(
"helicity.seed")) {
197 if (options.
GetValue<
int>(
"helicity.seed") == 24
198 || options.
GetValue<
int>(
"helicity.seed") == 30) {
204 if (options.
HasValue(
"helicity.delay")) {
209 if (options.
HasValue(
"helicity.bitpattern")) {
211 << options.
GetValue<std::string>(
"helicity.bitpattern")
213 std::string hex = options.
GetValue<std::string>(
"helicity.bitpattern");
220 if (options.
GetValue<
bool>(
"helicity.toggle-mode")) {
245 Bool_t results=kFALSE;
284 QwWarning <<
"QwHelicityBase::IsGoodEventNumber: \n this is not a good event number indeed:" <<
QwLog::endl;
308 QwWarning <<
"QwHelicityBase::IsGoodPhaseNumber: not a good phase number \t"
333 QwError <<
"QwHelicityBase::IsGoodHelicity : The helicity reported in event "
335 <<
" is not what we expect from the randomseed. Not a good event nor pattern"
338 QwError <<
"QwHelicityBase::IsGoodHelicity - The helicity reported in event "
340 <<
" is not what we expect according to pattern structure. Not a good event nor pattern"
359 for (
size_t i=0;i<
fWord.size();i++)
420 QwMessage <<
"\n*********QwHelicityBase Error Summary****************"
422 QwMessage <<
"First helicity gate counter: "
424 <<
"; last helicity gate counter: "
429 <<
"; last pattern counter: "
435 QwMessage <<
"Number of multiplet-sync-bit errors: "
438 QwMessage <<
"Number of helicity prediction errors: "
441 QwMessage <<
"---------------------------------------------------\n"
451 QwOut <<
"===========================\n"
452 <<
"This event: Event#, Pattern#, PatternPhase#="
456 QwOut <<
"Previous event: Event#, Pattern#, PatternPhase#="
460 QwOut <<
"delta = \n(fEventNumberOld)-(fMaxPatternPhase)x(fPatternNumberOld)-(fPatternPhaseNumberOld)= "
462 QwOut <<
"Helicity Reported, Delayed, Actual ="
473 Bool_t ldebug=kFALSE;
496 if (mapstr.
PopValue(
"patternphase",value)) {
501 if (mapstr.
PopValue(
"patternbits",valuestr)) {
527 if (mapstr.
PopValue(
"numberpatternsdelayed",value)) {
530 if (mapstr.
PopValue(
"randseedbits",value)) {
531 if (value==24 || value==30)
534 if (mapstr.
PopValue(
"patternphaseoffset",value)) {
537 if (mapstr.
PopValue(
"helpluseventtype",value)) {
540 if (mapstr.
PopValue(
"helminuseventtype",value)) {
545 if ((bankindex+1)>0){
546 UInt_t numbanks = UInt_t(bankindex+1);
549 std::pair<Int_t, Int_t>(
fWord.size(),
fWord.size()));
570 if (modnum<=0) wordsofar+=1;
571 else wordsofar+=modnum;
572 }
else if(modtype!=
"WORD"|| dettype!=
"helicitydata") {
573 QwError <<
"QwHelicityBase::LoadChannelMap: Unknown detector type: "
574 << dettype <<
", the detector " << namech <<
" will not be decoded "
587 fWord.push_back(localword);
593 std::cout <<
"Done with Load map channel \n";
594 for(
size_t i=0;i<
fWord.size();i++)
596 std::cout <<
" kUserbit=" <<
kUserbit <<
"\n";
611 Bool_t lkDEBUG = kFALSE;
618 if (index >= 0 && num_words > 0) {
621 QwDebug <<
"QwHelicityBase::ProcessEvBuffer: "
622 <<
"Begin processing ROC" << roc_id
623 <<
" and subbank " << bank_id
624 <<
" number of words=" << num_words <<
QwLog::endl;
627 if(
fWord[i].fWordInSubbank+1<= (Int_t) num_words) {
628 fWord[i].fValue=buffer[
fWord[i].fWordInSubbank];
630 QwWarning <<
"QwHelicityBase::ProcessEvBuffer: There is not enough word in the buffer to read data for "
632 QwWarning <<
"QwHelicityBase::ProcessEvBuffer: Words in this buffer:" << num_words
633 <<
" trying to read word number =" <<
fWord[i].fWordInSubbank <<
QwLog::endl;
637 QwDebug <<
"QwHelicityBase::ProcessEvBuffer: Done with Processing this event" <<
QwLog::endl;
638 for(
size_t i=0;i<
fWord.size();i++) {
639 std::cout <<
"QwHelicityBase::ProcessEvBuffer: word number = " << i <<
" ";
689 UShort_t firstbits[nbits];
690 for (
unsigned int i = 0; i < nbits; i++) firstbits[i] = (seed >> i) & 0x1;
701 if (TRegexp(
"diff_").Index(prefix,&len) == 0
702 || TRegexp(
"asym[1-9]*_").Index(prefix,&len) == 0)
704 else if (TRegexp(
"yield_").Index(prefix,&len) == 0)
713 if (folder != NULL) folder->cd();
724 basename=
"pattern_polarity";
727 for (
size_t i=0; i<
fWord.size(); i++){
728 basename=
"hel_"+
fWord[i].fWordName;
736 basename=prefix+
"delta_event_number";
739 basename=prefix+
"delta_pattern_number";
742 basename=prefix+
"pattern_phase";
745 basename=prefix+
"helicity";
748 for (
size_t i=0; i<
fWord.size(); i++){
749 basename=prefix+
fWord[i].fWordName;
755 QwError <<
"QwHelicityBase::ConstructHistograms this prefix--" << prefix <<
"-- is not unknown:: no histo created" <<
QwLog::endl;
777 for (
size_t i=0; i<
fWord.size(); i++){
799 for (
size_t i=0; i<
fWord.size(); i++){
825 basename =
"delayed_helicity";
827 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
829 basename =
"reported_helicity";
831 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
833 basename =
"pattern_phase";
835 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
837 basename =
"pattern_number";
839 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
841 basename =
"pattern_seed";
843 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
845 basename =
"event_number";
847 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
849 for (
size_t i=0; i<
fWord.size(); i++)
851 basename =
fWord[i].fWordName;
853 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
858 basename =
"actual_helicity";
860 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
862 basename =
"actual_pattern_polarity";
864 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
866 basename =
"actual_previous_pattern_polarity";
868 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
870 basename =
"delayed_pattern_polarity";
872 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
874 basename =
"pattern_number";
876 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
878 basename =
"pattern_seed";
880 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
882 for (
size_t i=0; i<
fWord.size(); i++)
884 basename =
fWord[i].fWordName;
886 tree->Branch(basename, &(values.
back<Double_t>()), basename+
"/I");
907 basename =
"delayed_helicity";
910 basename =
"reported_helicity";
913 basename =
"pattern_phase";
916 basename =
"pattern_number";
919 basename =
"pattern_seed";
922 basename =
"event_number";
927 basename =
"actual_helicity";
930 basename =
"actual_pattern_polarity";
933 basename =
"actual_previous_pattern_polarity";
936 basename =
"delayed_pattern_polarity";
939 basename =
"pattern_number";
942 basename =
"pattern_seed";
945 for (
size_t i=0; i<
fWord.size(); i++)
947 basename =
fWord[i].fWordName;
948 tree->Branch(basename, &
fWord[i].fValue, basename+
"/I");
969 basename =
"delayed_helicity";
972 basename =
"reported_helicity";
975 basename =
"pattern_phase";
978 basename =
"pattern_number";
981 basename =
"pattern_seed";
984 basename =
"event_number";
989 basename =
"actual_helicity";
992 basename =
"actual_pattern_polarity";
995 basename =
"actual_previous_pattern_polarity";
998 basename =
"delayed_pattern_polarity";
1001 basename =
"pattern_number";
1004 basename =
"pattern_seed";
1007 for (
size_t i=0; i<
fWord.size(); i++)
1009 basename =
fWord[i].fWordName;
1010 tree->Branch(basename,&
fWord[i].fValue, basename+
"/I");
1032 for (
size_t i=0; i<
fWord.size(); i++)
1043 for (
size_t i=0; i<
fWord.size(); i++){
1052#ifdef __USE_DATABASE__
1055 if (type==
"yield" || type==
"asymmetry")
1074 Bool_t status =
false;
1112 const UInt_t IB1 = 1;
1113 const UInt_t IB3 = 4;
1114 const UInt_t IB4 = 8;
1115 const UInt_t IB24 = 8388608;
1116 const UInt_t MASK = IB1+IB3+IB4+IB24;
1128 ranseed = (((ranseed^MASK) << 1)|IB1);
1145 UInt_t bit7 = (ranseed & 0x00000040) != 0;
1146 UInt_t bit28 = (ranseed & 0x08000000) != 0;
1147 UInt_t bit29 = (ranseed & 0x10000000) != 0;
1148 UInt_t bit30 = (ranseed & 0x20000000) != 0;
1150 UInt_t result = (bit30 ^ bit29 ^ bit28 ^ bit7) & 0x1;
1156 ranseed = ( (ranseed << 1) | result ) & 0x3FFFFFFF;
1165 QwDebug <<
" Entering QwHelicityBase::GetRandomSeed \n";
1182 for(
size_t i=0;i<25;i++)
1183 std::cout << i <<
" : " << first24randbits[i] <<
"\n";
1186 for(
size_t i=24;i>=5;i--) b[i]= first24randbits[24-i+1];
1189 b[4] = first24randbits[21]^b[24];
1190 b[3] = first24randbits[22]^b[24]^b[23];
1191 b[2] = first24randbits[23]^b[23]^b[22];
1192 b[1] = first24randbits[24]^b[21]^b[22]^b[24];
1195 for(
size_t i=24;i>=1;i--) ranseed = (ranseed << 1) | (b[i]&1);
1197 ranseed = ranseed&0xFFFFFF;
1200 QwDebug <<
" Exiting QwHelicityBase::GetRandomSeed \n";
1210 Int_t ldebug = kFALSE;
1212 if(ldebug) std::cout <<
"Entering QwHelicityBase::RunPredictor for fEventNumber, " <<
fEventNumber
1244 Int_t indexnum,shiftnum;
1245 indexnum = TMath::FloorNint(localphase/32.);
1246 shiftnum = localphase - indexnum*32;
1263 std::cout <<
"Predicted Polarity ::: Delayed ="
1266 std::cout <<
"Predicted Helicity ::: Delayed Helicity=" <<
fHelicityDelayed
1278 Bool_t status =
false;
1293 Bool_t ldebug = kFALSE;
1294 const UInt_t ranbit_goal = 24;
1299 if (
n_ranbits==ranbit_goal)
return kTRUE;
1308 static UShort_t first24bits[25];
1319 std::cout <<
" event number" <<
fEventNumber <<
", fPatternNumber"
1328 std::cout <<
"Collected 24 random bits. Get the random seed for the predictor." <<
"\n";
1329 for(UInt_t i=0;i<ranbit_goal;i++) std::cout <<
" i:bit =" << i <<
":" << first24bits[i] <<
"\n";
1354 QwError <<
"QwHelicityBase::CollectRandBits We cannot handle negative delay(prediction) in the reported helicity. Exiting." <<
QwLog::endl;
1365 QwError <<
"QwHelicityBase::CollectRandBits, while collecting the seed, we encountered non continuous events: need to reset the seed collecting " <<
QwLog::endl
1366 <<
" event number=" <<
fEventNumber <<
", fPatternNumber="
1372 QwDebug <<
"QwHelicityBase::CollectRandBits24 => Done collecting ..." <<
QwLog::endl;
1387 const UInt_t ranbit_goal = 30;
1391 if (
n_ranbits == ranbit_goal)
return kTRUE;
1397 QwMessage <<
"Collecting information (";
1418 QwDebug <<
"QwHelicityBase:: CollectRandBits30: done Collecting 30 randbits" <<
QwLog::endl;
1438 QwError <<
"QwHelicityBase::CollectRandBits30: We cannot handle negative delay(prediction) in the reported helicity. Exiting." <<
QwLog::endl;
1448 QwWarning <<
"QwHelicityBase::CollectRandBits30: While collecting the seed, we encountered non continuous events: Need to reset the seed collecting " <<
QwLog::endl;
1457 Bool_t ldebug=kFALSE;
1459 if(ldebug) std::cout <<
"Entering QwHelicityBase::PredictHelicity \n";
1472 if(ldebug) std::cout <<
"QwHelicityBase::PredictHelicity=>Predicting the helicity \n";
1480 if(ldebug) std::cout <<
"n_ranbit exiting the function = " <<
n_ranbits <<
"\n";
1495 QwWarning <<
"QwHelicityBase : SetHelicityDelay :: helicity delay is set to 0."
1496 <<
" Disabling helicity predictor and using reported helicity information."
1504 QwError <<
"QwHelicityBase::SetHelicityDelay We cannot handle negative delay in the prediction of delayed helicity. Exiting.." <<
QwLog::endl;
1542 Bool_t ldebug = kFALSE;
1547 for(
size_t i=0;i<input->
fWord.size();i++)
1548 this->
fWord[i].fValue=input->
fWord[i].fValue;
1575 std::cout <<
"QwHelicityBase::operator = this->fPatternNumber=" << this->
fPatternNumber << std::endl;
1576 std::cout <<
"input->fPatternNumber=" << input->
fPatternNumber <<
"\n";
1625 for (
size_t i=0; i<
fWord.size(); i++) {
1627 std::min(
fWord[i].fValue, input->
fWord[i].fValue);
1658 if(
typeid(*value)!=
typeid(*
this)) {
1670 UInt_t bitpattern = 0;
1680 }
else if (patternsize%2==0 && patternsize>0 && patternsize < 129){
1681 int num_int = TMath::CeilNint(patternsize/32.);
1684 bitpattern = 0x69969669;
1686 for (
int i = 1; i<num_int; i++){
1697 QwError <<
"QwHelicityBase::BuildHelicityBitPattern: "
1698 <<
"Unable to build standard bit pattern for pattern size of "
1699 << patternsize <<
". Try a pattern of 0x69."
1709 QwMessage <<
"QwHelicityBase::BuildHelicityBitPattern: "
1710 <<
"Built pattern 0x";
1714 QwMessage << std::dec <<
"for pattern size "
1721#ifdef HAS_RNTUPLE_SUPPORT
1722void QwHelicityBase::ConstructNTupleAndVector(std::unique_ptr<ROOT::RNTupleModel>& model, TString &prefix, std::vector<Double_t>& values, std::vector<std::shared_ptr<Double_t>>& fieldPtrs)
1734 basename =
"delayed_helicity";
1735 values.push_back(0.0);
1736 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1738 basename =
"reported_helicity";
1739 values.push_back(0.0);
1740 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1742 basename =
"pattern_phase";
1743 values.push_back(0.0);
1744 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1746 basename =
"pattern_number";
1747 values.push_back(0.0);
1748 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1750 basename =
"pattern_seed";
1751 values.push_back(0.0);
1752 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1754 basename =
"event_number";
1755 values.push_back(0.0);
1756 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1758 for (
size_t i=0; i<
fWord.size(); i++)
1760 basename =
fWord[i].fWordName;
1761 values.push_back(0.0);
1762 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1767 basename =
"actual_helicity";
1768 values.push_back(0.0);
1769 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1771 basename =
"actual_pattern_polarity";
1772 values.push_back(0.0);
1773 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1775 basename =
"actual_previous_pattern_polarity";
1776 values.push_back(0.0);
1777 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1779 basename =
"delayed_pattern_polarity";
1780 values.push_back(0.0);
1781 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1783 basename =
"pattern_number";
1784 values.push_back(0.0);
1785 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1787 basename =
"pattern_seed";
1788 values.push_back(0.0);
1789 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1791 for (
size_t i=0; i<
fWord.size(); i++){
1792 basename =
fWord[i].fWordName;
1793 values.push_back(0.0);
1794 fieldPtrs.push_back(model->MakeField<Double_t>(basename.Data()));
1801void QwHelicityBase::FillNTupleVector(std::vector<Double_t>& values)
const
1813 for (
size_t i=0; i<
fWord.size(); i++)
1814 values[index++] =
fWord[i].fValue;
1824 for (
size_t i=0; i<
fWord.size(); i++){
1825 values[index++] =
fWord[i].fValue;
A logfile class, based on an identical class in the Hermes analyzer.
#define QwOut
Predefined log drain for explicit output.
#define QwError
Predefined log drain for errors.
#define QwWarning
Predefined log drain for warnings.
#define QwMessage
Predefined log drain for regular messages.
#define QwDebug
Predefined log drain for debugging output.
Helper functions and utilities for ROOT histogram management.
QwHistogramHelper gQwHists
Globally defined instance of the QwHistogramHelper class.
ROOT file and tree management wrapper classes.
static const UInt_t kErrorFlag_Helicity
static const UInt_t kGlobalCut
static const UInt_t kEventCutMode3
Helicity state management and pattern recognition.
std::vector< TH1_ptr > fHistograms
Histograms associated with this data element.
Utility class for histogram creation and management.
static std::ostream & endl(std::ostream &)
End of the line.
Command-line and configuration file options processor.
T GetValue(const std::string &key)
Get a templated value.
bool HasValue(const std::string &key)
Has this key been defined.
po::options_description_easy_init AddOptions(const std::string &blockname="Specialized options")
Add an option to a named block or create new block.
Configuration file parser with flexible tokenization and search capabilities.
T GetTypedNextToken()
Get next token into specific type.
Bool_t PopValue(const std::string keyname, T &retvalue)
void TrimWhitespace(TString::EStripType head_tail=TString::kBoth)
void SetCommentChars(const std::string value)
Set various sets of special characters.
const std::pair< TString, TString > GetParamFileNameContents()
A helper class to manage a vector of branch entries for ROOT trees.
size_type size() const noexcept
void push_back(const std::string &name, const char type='D')
void SetValue(size_type index, Double_t val)
Word-level data manipulation and bit operations.
BankID_t fCurrentBank_ID
Bank ID (and Marker word) that is currently being processed;.
Int_t GetSubbankIndex() const
UInt_t GetEventTypeMask() const
Get event type mask.
virtual VQwSubsystem & operator=(VQwSubsystem *value)
Assignment Note: Must be called at the beginning of all subsystems routine call to operator=(VQwSubsy...
void RegisterRocBankMarker(QwParameterFile &mapstr)
static void DefineOptions()
Define options function (note: no virtual static functions in C++)
std::map< TString, TString > fDetectorMaps
Map of file name to full path or content.
VQwSubsystem(const TString &name)
Constructor with name.
void SetDataLoaded(Bool_t flag)
ROCID_t fCurrentROC_ID
ROC ID that is currently being processed.
void FillTreeVector(QwRootTreeBranchVector &values) const override
Fill the tree vector.
void SetHelicityBitPattern(TString hex)
void SetHelicityDelay(Int_t delay)
static const std::vector< UInt_t > kDefaultHelicityBitPattern
std::vector< std::pair< Int_t, Int_t > > fWordsPerSubbank
void CheckPatternNum(VQwSubsystem *value)
std::vector< QwWord > fWord
Bool_t CollectRandBits24()
UInt_t BuildHelicityBitPattern(Int_t patternsize)
VQwSubsystem & operator=(VQwSubsystem *value) override
Assignment Note: Must be called at the beginning of all subsystems routine call to operator=(VQwSubsy...
Int_t ProcessConfigurationBuffer(const ROCID_t roc_id, const BankID_t bank_id, UInt_t *buffer, UInt_t num_words) override
Int_t fActualPatternPolarity
True polarity of the current pattern.
UInt_t GetRandomSeed(UShort_t *first24randbits)
QwHelicityBase()
Private default constructor (not implemented, will throw linker error on use)
Bool_t IsGoodPatternNumber()
Bool_t fSuppressMPSErrorMsgs
Int_t fPatternPhaseOffset
UInt_t GetEventcutErrorFlag() override
Return the error flag to the top level routines related to stability checks and ErrorFlag updates.
Int_t GetHelicityActual()
UInt_t GetRandbit24(UInt_t &ranseed)
virtual void ConstructHistograms()
Construct the histograms for this subsystem.
VQwSubsystem & operator+=(VQwSubsystem *value) override
Long_t GetPatternNumber()
virtual UInt_t GetRandbit(UInt_t &ranseed)
UInt_t kEventTypeHelMinus
Int_t fNumMissedEventBlocks
Int_t fPreviousPatternPolarity
True polarity of the previous pattern.
Int_t LoadInputParameters(TString pedestalfile) override
Mandatory parameter file definition.
void FillHistograms() override
Fill the histograms for this subsystem.
void IncrementErrorCounters() override
Increment the error counters.
virtual Bool_t CollectRandBits()
std::vector< UInt_t > fHelicityBitPattern
void PrintErrorCounters() const override
virtual void ClearEventData() override
Bool_t IsGoodPhaseNumber()
Int_t GetHelicityReported()
UInt_t GetRandbit30(UInt_t &ranseed)
void SetEventPatternPhase(Int_t event, Int_t pattern, Int_t phase)
Int_t fHelicityDecodingMode
virtual Bool_t IsGoodHelicity()
void ConstructBranchAndVector(TTree *tree, TString &prefix, QwRootTreeBranchVector &values) override
Construct the branch and tree vector.
size_t fTreeArrayNumEntries
Int_t LoadChannelMap(TString mapfile) override
Mandatory map file definition.
Int_t LoadEventCuts(TString filename) override
Optional event cut file.
static const Int_t kUndefinedHelicity
Int_t fDelayedPatternPolarity
Reported polarity of the current pattern.
Int_t fPatternPhaseNumberOld
Int_t fPatternPhaseNumber
void ConstructBranch(TTree *tree, TString &prefix) override
Construct the branch and tree vector.
Int_t fPatternNumberFirst
void SetFirstBits(UInt_t nbits, UInt_t firstbits)
void SetHistoTreeSave(const TString &prefix)
void ProcessOptions(QwOptions &options) override
Process the command line options.
Int_t ProcessEvBuffer(const ROCID_t roc_id, const BankID_t bank_id, UInt_t *buffer, UInt_t num_words)
TODO: The non-event-type-aware ProcessEvBuffer routine should be replaced with the event-type-aware v...
Bool_t Compare(VQwSubsystem *source)
void ClearErrorCounters()
Bool_t ApplySingleEventCuts() override
Apply the single event cuts.
Int_t GetHelicityDelayed()
void MergeCounters(VQwSubsystem *value)
Bool_t IsGoodEventNumber()
Bool_t CollectRandBits30()
void AccumulateRunningSum(VQwSubsystem *value, Int_t count=0, Int_t ErrorMask=0xFFFFFFF) override
Update the running sums for devices.
void Ratio(VQwSubsystem *numer, VQwSubsystem *denom) override
VQwSubsystemParity()
Private default constructor (not implemented, will throw linker error on use)
virtual void FillDB(QwParityDB *, TString)
Fill the database.
virtual void FillErrDB(QwParityDB *, TString)