Analysis.hh
Go to the documentation of this file.
1 #pragma once
2 
7 
13 namespace higgscpv
14 {
15 
16 using namespace boca;
17 
25 template <typename Tagger_>
26 class Analysis : public boca::Analysis<Tagger_>
27 {
28 
29 public:
30 
32  {
33  Settings::SetCollider(Collider::lhc);
34 // this->PreCuts().PtLowerCut().Set(Id::higgs,200);
35  // this->PreCuts().MassLowerCut().Set(Id::higgs,105);
36 // this->PreCuts().MassUpperCut().Set(Id::higgs,145);
37  this->PreCuts().MassLowerCut().Set(Id::higgs, 50_GeV);
38  this->PreCuts().MassUpperCut().Set(Id::higgs, 150_GeV);
39  this->PreCuts().SetSemiLeptonic(false);
40 // NoHiggs(-1);
41 // SingleHiggs(-1);
42  }
43 
44 protected:
45 
46 private:
47 
48  std::string Name() const override
49  {
50  return "CPV-after-tahoe";
51  }
52 
53  void SetFiles(Phase const &phase) override
54  {
55  switch (phase.Tag()) {
56  case Tag::signal :
57  // this->AddSignal("gg-tth", 0.0098);
58  this->AddSignal("pp-tth", "tth", 0.02267_pb);
59  // this->AddSignal("pp-ttx0-bbbbllnunu-1", 0.02071);
60  // this->AddSignal("pp-ttx0-bbbbllnunu-1", 0.008937);
61  // this->AddSignal("pp-ttx0-bbbbllnunu-0.5", 0.01193);
62  break;
63  case Tag::background :
64  this->AddBackground("pp-ttbb", "ttbb", 0.1266_pb);
65  // this->AddBackground("pp-ttbb-bbbbllnunu", 3.457);
66  break;
67  }
68  }
69 
74  long TrainNumberMax() const override
75  {
76  return 1000;
77  return 5000;
78  return 10000;
79  return 100;
80  return 10;
81  }
82 
83  bool PassPreCut(boca::Event const &event) const override
84  {
85  // if(this->template TaggerIs<tagger::WLeptonic>()) return false;
86  // if(this->template TaggerIs<TopLeptonicTagger>()) static_cast<TopLeptonicTagger&>(this->()).semi_leptonic = false;
87  std::vector<Lepton> leptons = SortedByPt(event.Leptons());
88  if (leptons.size() < 2) return false;
89 // if (leptons.at(1).Pt() < 40) return false;
90 // std::vector<Jet> jets = event.Jets();
91 // std::vector<Jet>gen_particles = event.GenParticles();
92 // std::vector<Jet> higgs = CopyIfParticles(gen_particles, Id::CP_violating_higgs, Id::higgs);
93 // if (higgs.empty()) {
94 // ERROR(NoHiggs(), higgs.size());
95 // return true;
96 // }
97 // if(higgs.front().Pt() < 200) return false;
98 // static int pre_cut=0;
99 // ++pre_cut;
100 // ERROR(pre_cut);
101 // Particle particle = higgs.front().Info().constituents().front().family().Particle();
102 // Particle mother1 = higgs.front().Info().constituents().front().family().Mother();
103 // Particle mother2 = higgs.front().Info().constituents().front().family().mother_2();
104 // Particle grand_mother = higgs.front().Info().constituents().front().family().GrandMother();
105 // // ERROR(particle.Id(),mother1.Id(),mother2.Id(),grand_mother.Id());
106 // higgs = RemoveIfSingleMother(higgs);
107 // ERROR(SingleHiggs(), higgs.size());
108 // return higgs.size();
109  return true;
110  }
111 
112 
113 // std::string FilePath() const override {
114 // return this->WorkingPath();
115 // return "~/Projects/HiggsCpv/Analysis/";
116 // return "/Users/jingren/HEP/Research/JanH/tth-analysis/";
117 // }
118 
119 
120 // static int NoHiggs(int zero = -10) {
121 // static int i = -1;
122 // if (zero != -10) i = zero;
123 // ++i;
124 // return i;
125 // }
126 //
127 // static int SingleHiggs(int zero = -10) {
128 // static int j = -1;
129 // if (zero != -10) j = zero;
130 // ++j;
131 // return j;
132 // }
133 
134 };
135 
136 }
137 
PreCut< Mass > & MassLowerCut()
Definition: PreCuts.cpp:31
void AddSignal(std::string const &file_name, latex::String const &latex_name="", boca::Crosssection const &crosssection=0_b, boca::Mass const &mass=0_eV, std::string const &path="")
Definition: Base.cpp:97
virtual std::string Name() const
Definition: Base.cpp:264
static void SetCollider(boca::Collider collider)
Definition: Settings.cpp:40
virtual void SetFiles(Phase const &phase)=0
void Set(Id id, Value value)
Definition: PreCut.hh:18
virtual bool PassPreCut(Event const &) const
Definition: Base.cpp:253
CP-violating Higgs couplings.
Definition: Analysis.hh:13
boca::PreCuts PreCuts() const
Definition: Base.cpp:130
Base class for the event Topology.
Definition: Event.hh:53
Analysis()
Definition: Analysis.hh:31
provides main analysis loops and logic.
Definition: Analysis.hh:29
Boosted Collider Analysis.
Definition: Analysis.hh:15
void SetSemiLeptonic(bool semi_leptonic)
Definition: PreCuts.cpp:15
std::vector< Lepton > Leptons() const
Electrons and muons.
Definition: Event.cpp:82
void AddBackground(std::string const &file_name, latex::String const &latex_name="", boca::Crosssection const &crosssection=0_b, boca::Mass const &mass=0_eV, std::string const &path="")
Definition: Base.cpp:105
virtual long TrainNumberMax() const
Definition: Base.cpp:85
std::vector< Multiplet > SortedByPt(std::vector< Multiplet > multiplets)
Definition: Sort.hh:53
The phases of the multivariant tagging process.
Definition: Phase.hh:16
boca::Tag Tag() const
The Tag of the multivariant tagging process.
Definition: Phase.cpp:18
PreCut< Mass > & MassUpperCut()
Definition: PreCuts.cpp:35