1 #include "antiNumuCCMultiTrackSelection.hxx" 2 #include "antiNumuCCSelection.hxx" 3 #include "baseSelection.hxx" 4 #include "CutUtils.hxx" 5 #include "EventBoxUtils.hxx" 6 #include "SubDetId.hxx" 8 #include "VersioningUtils.hxx" 9 #include "SystematicUtils.hxx" 13 antiNumuCCMultiTrackSelection::antiNumuCCMultiTrackSelection(
bool forceBreak):
SelectionBase(forceBreak,
EventBoxId::kEventBoxTracker) {
23 CopySteps(_antiNumuCCSelection);
38 SetBranchAlias(0,
"CCQE",0);
39 SetBranchAlias(1,
"CCnQE",1);
42 SetPreSelectionAccumLevel(2);
50 SetDetectorFV(SubDetId::kFGD1);
54 bool antiNumuCCMultiTrackSelection::FillEventSummary(
AnaEventC& event, Int_t allCutsPassed[]){
59 static_cast<AnaEventSummaryB*
>(
event.Summary)->EventSample = SampleId::kFGD1AntiNuMuCC1Track;
62 else if (allCutsPassed[1]){
63 static_cast<AnaEventSummaryB*
>(
event.Summary)->EventSample = SampleId::kFGD1AntiNuMuCCNTracks;
67 return (static_cast<AnaEventSummaryB*>(event.
Summary)->EventSample != SampleId::kUnassigned);
81 static_cast<AnaEventSummaryB*>(event.
Summary)->LeptonCandidate[SampleId::kFGD1AntiNuMuCCNTracks] = box.
HMPtrack;
83 for(
int i = 0; i < 4; ++i){
102 EventBoxB* EventBox =
event.EventBoxes[EventBoxId::kEventBoxTracker];
114 EventBoxB* EventBox =
event.EventBoxes[EventBoxId::kEventBoxTracker];
122 return _antiNumuCCSelection.IsRelevantRecObjectForSystematic(event,track,systId,branch);
129 return _antiNumuCCSelection.IsRelevantTrueObjectForSystematic(event,trueTrack,systId,branch);
141 if (_antiNumuCCSelection.IsRelevantSystematic(event, box, systId, branch))
152 _antiNumuCCSelection.InitializeEvent(event);
160 if( _antiNumuCCSelection.CheckRedoSelection(event,PreviousToyBox,redoFromStep))
return true;
void DefineDetectorFV()
Define the detector Fiducial Volume in which this selection is applied.
AnaTrueVertexB * TrueVertex
Pointer to the AnaTrueVertexB of the interaction that created this AnaTrueParticleB.
Float_t PositionStart[4]
The reconstructed start position of the particle.
bool CheckRedoSelection(const AnaEventC &event, const ToyBoxB &PreviousToyBox, Int_t &redoFromStep)
void DefineSteps()
Define all steps in the selection.
bool Apply(AnaEventC &event, ToyBoxB &box) const
AnaTrackB * MainTrack
For storing the Main Track (The lepton candidate in geranal: HMN or HMP track)
AnaTrackB * HMPtrack
For storing the highest momentum positive track.
bool Apply(AnaEventC &event, ToyBoxB &box) const
Int_t nRecObjectsInGroup[NMAXRECOBJECTGROUPS]
----—— RecObjects and TrueRecObjects used in the selection and systematics ------------—— ...
bool IsRelevantRecObjectForSystematic(const AnaEventC &event, AnaRecObjectC *recObj, SystId_h systId, Int_t branch) const
Is this track relevant for a given systematic (prior to selection, call when initializing the event...
bool Apply(AnaEventC &event, ToyBoxB &box) const
void InitializeEvent(AnaEventC &event)
Fill the EventBox with the objects needed by this selection.
AnaEventSummaryC * Summary
A summary of the event with high level quantities.
bool IsRelevantTrueObjectForSystematic(const AnaEventC &event, AnaTrueObjectC *trueObj, SystId_h systId, Int_t branch) const
Is this true track relevant for a given systematic (prior to selection, call when initializing the ev...
AnaTrueParticleB * GetTrueParticle() const
Return a casted version of the AnaTrueObject associated.
bool IsRelevantSystematic(const AnaEventC &event, const ToyBoxB &box, SystId_h systId, Int_t branch) const
Is this systematic relevant for this selection.