HighLAND
nueCCFGD2Selection.hxx
1 #ifndef nueCCFGD2Selection_h
2 #define nueCCFGD2Selection_h
3 
4 #include "SelectionBase.hxx"
5 #include "Parameters.hxx"
6 #include "ToyBoxTracker.hxx"
7 #include "SystId.hxx"
8 #include "SubDetId.hxx"
9 
10 #include "nueCCSelection.hxx"
11 
13  public:
14  nueCCFGD2Selection(bool forceBreak=true);
15  virtual ~nueCCFGD2Selection(){}
16 
17  //---- These are mandatory functions
18  void DefineSteps();
19  void DefineDetectorFV();
20  ToyBoxB* MakeToyBox(){return new ToyBoxNueCC();}
21 
22  void InitializeEvent(AnaEventC& event);
23  bool FillEventSummary(AnaEventC& event, Int_t allCutsPassed[]);
24  SampleId::SampleEnum GetSampleEnum(){return SampleId::kFGD2NuECC;}
25 
26  bool CheckRedoSelection(const AnaEventC& eventC, const ToyBoxB& PreviousToyBox, Int_t& redoFromStep);
27  bool IsRelevantRecObjectForSystematic(const AnaEventC& event, AnaRecObjectC* track, SystId_h systId, Int_t branch) const;
28  bool IsRelevantTrueObjectForSystematic(const AnaEventC& event, AnaTrueObjectC* trueTrack, SystId_h systId, Int_t branch) const;
29  bool IsRelevantRecObjectForSystematicInToy(const AnaEventC&, const ToyBoxB&, AnaRecObjectC*, SystId_h systId, Int_t branch=0) const;
30  bool IsRelevantTrueObjectForSystematicInToy(const AnaEventC&, const ToyBoxB&, AnaTrueObjectC*, SystId_h systId, Int_t branch=0) const;
31  bool IsRelevantSystematic(const AnaEventC& event, const ToyBoxB& box,SystId_h systId , Int_t branch) const;
32 
33 protected:
34  nueCCSelection _nueCCSelection;
35 };
36 
37 
39 public:
40  using StepBase::Apply;
41  bool Apply(AnaEventC& event, ToyBoxB& box) const;
43 };
44 
45 class EOverPCut: public StepBase{
46 public:
47  EOverPCut(){
48  _eoverp_threshold = (Float_t)ND::params().GetParameterD("psycheSelections.nueCCAnalysis.Cuts.PID.EOverPThreshold");
49  _eoverp_minmom = (Float_t)ND::params().GetParameterD("psycheSelections.nueCCAnalysis.Cuts.PID.EOverPMinMomentum");
50  };
51  using StepBase::Apply;
52  bool Apply(AnaEventC& event, ToyBoxB& boxB) const;
53  StepBase* MakeClone(){return new EOverPCut();}
54 protected:
55  Float_t _eoverp_threshold;
56  Float_t _eoverp_minmom;
57 };
58 
59 class P0DFGD1VetoCut: public StepBase{
60 public:
61  using StepBase::Apply;
62  bool Apply(AnaEventC& event, ToyBoxB& boxB) const;
63  StepBase* MakeClone(){return new P0DFGD1VetoCut();}
64 };
65 
66 class TPCVetoCut_FGD2: public StepBase{
67 public:
69  _delta_z_min = (Float_t)ND::params().GetParameterD("psycheSelections.nueCCAnalysis.Cuts.TPCVeto.DeltaZMin.FGD2");
70  };
71  using StepBase::Apply;
72  bool Apply(AnaEventC& event, ToyBoxB& boxB) const;
74 protected:
75  Float_t _delta_z_min;
76 };
77 
79  public:
80  using StepBase::Apply;
81  bool Apply(AnaEventC& event, ToyBoxB& box) const;
83 };
84 
85 #endif
void DefineDetectorFV()
Define the detector Fiducial Volume in which this selection is applied.
bool IsRelevantTrueObjectForSystematic(const AnaEventC &event, AnaTrueObjectC *trueTrack, SystId_h systId, Int_t branch) const
Is this true track relevant for a given systematic (prior to selection, call when initializing the ev...
void DefineSteps()
Define all steps in the selection.
bool IsRelevantRecObjectForSystematicInToy(const AnaEventC &, const ToyBoxB &, AnaRecObjectC *, SystId_h systId, Int_t branch=0) const
Is this track relevant for a given systematic (after selection, called for each toy) ...
StepBase * MakeClone()
MANDATORY FUNCTIONS !!!
bool IsRelevantRecObjectForSystematic(const AnaEventC &event, AnaRecObjectC *track, SystId_h systId, Int_t branch) const
Is this track relevant for a given systematic (prior to selection, call when initializing the event...
bool IsRelevantSystematic(const AnaEventC &event, const ToyBoxB &box, SystId_h systId, Int_t branch) const
Is this systematic relevant for this selection.
virtual bool Apply(AnaEventC &event, ToyBoxB &box) const
Definition: StepBase.hxx:46
StepBase * MakeClone()
MANDATORY FUNCTIONS !!!
bool IsRelevantTrueObjectForSystematicInToy(const AnaEventC &, const ToyBoxB &, AnaTrueObjectC *, SystId_h systId, Int_t branch=0) const
Is this true track relevant for a given systematic (after selection, called for each toy) ...
bool Apply(AnaEventC &event, bool &redo)
Apply all steps in the selection.
double GetParameterD(std::string)
Get parameter. Value is returned as double.
Definition: Parameters.cxx:229
void InitializeEvent(AnaEventC &event)
Fill the EventBox with the objects needed by this selection.
ToyBoxB * MakeToyBox()
Create the appropriate type of box.
StepBase * MakeClone()
MANDATORY FUNCTIONS !!!
ToyBoxB ** PreviousToyBox
Array of pointers to the PreviousToyBox (for each event)
bool CheckRedoSelection(const AnaEventC &eventC, const ToyBoxB &PreviousToyBox, Int_t &redoFromStep)
StepBase * MakeClone()
MANDATORY FUNCTIONS !!!
StepBase * MakeClone()
MANDATORY FUNCTIONS !!!