DAS  3.0
Das Analysis System
BF.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <vector>
4 #include <list>
5 #include <optional>
6 
7 #include <TUnfoldBinning.h>
8 #include <TTreeReaderArray.h>
9 #include <TH1.h>
10 #include <TH2.h>
11 
12 #if !defined(__CLING__) || defined(__ROOTCLING__)
18 #endif
19 
21 
22 #if !defined(__CLING__) || defined(__ROOTCLING__)
23 struct BF : public Observable {
26  BF ();
27 
30  std::unique_ptr<Filler> getFiller (TTreeReader& reader) const override;
31 
34  void setLmatrix (const std::unique_ptr<TH1>&, std::unique_ptr<TH2>&) override {}
35 
36  std::optional<int> process;
37 };
38 
39 template<int PROCESS> struct BFprocessT : public BF {
40  BFprocessT () { process = PROCESS; }
41 };
42 
47 using WW = BFprocessT<5>;
48 using WZ = BFprocessT<6>;
49 using ZZ = BFprocessT<7>;
50 static const std::vector<const char *> processes {"Z#to#mu#mu", "Z#to#tau#tau", "t#bar{t}#to2l2#nu", "QCD", "WW", "WZ", "ZZ"};
51 static const std::vector<const char *> channels {"#mu#mu", "#mu#mu#gamma"};
52 
53 struct BFFiller final : public Filler {
54  BF obs;
55 
56  std::optional<TTreeReaderArray<GenMuon>> genMuons;
57  std::optional<TTreeReaderArray<GenPhoton>> genPhotons;
58  TTreeReaderArray<RecMuon> recMuons;
59  TTreeReaderArray<RecPhoton> recPhotons;
60  std::optional<TTreeReaderValue<GenEvent>> gEv;
61  TTreeReaderValue<RecEvent> rEv;
62 
65  BFFiller (const BF& obs, TTreeReader& reader);
66 
69  std::list<int> fillRec (DistVariation&) override;
70 
73  void match () override {}
74 
77  void fillMC (DistVariation&) override;
78 
79 private:
80  std::optional<int> irecbin;
81  std::optional<float> recZW;
82 };
83 #endif
84 
85 } // end of DAS::Unfolding::ZmmY namespace
DAS::Unfolding::ZmmY::channels
static const std::vector< const char * > channels
Definition: BF.h:51
DAS::Unfolding::ZmmY::BF::getFiller
std::unique_ptr< Filler > getFiller(TTreeReader &reader) const override
Constructs a filler for the observable.
Definition: BF.cc:187
DAS::Unfolding::ZmmY::BFFiller
Definition: BF.h:53
DAS::Unfolding::ZmmY::BFFiller::recPhotons
TTreeReaderArray< RecPhoton > recPhotons
Definition: BF.h:59
DAS::Unfolding::ZmmY::BFFiller::irecbin
std::optional< int > irecbin
Definition: BF.h:80
Event.h
DAS::Unfolding::ZmmY::BFprocessT::BFprocessT
BFprocessT()
Definition: BF.h:40
DAS::Unfolding::DistVariation
Definition: DistVariation.h:25
DAS::Unfolding::Filler
Definition: Observable.h:56
DAS::Unfolding::ZmmY::BFFiller::rEv
TTreeReaderValue< RecEvent > rEv
Definition: BF.h:61
DAS::Unfolding::ZmmY::BFprocessT
Definition: BF.h:39
DAS::Unfolding::ZmmY::BFFiller::obs
BF obs
Backreference to the observable.
Definition: BF.h:54
DAS::Unfolding::ZmmY::BFFiller::recMuons
TTreeReaderArray< RecMuon > recMuons
Definition: BF.h:58
DAS::Unfolding::ZmmY::BFFiller::recZW
std::optional< float > recZW
Definition: BF.h:81
DAS::Unfolding::ZmmY::BFFiller::fillRec
std::list< int > fillRec(DistVariation &) override
See Filler::fillRec
Definition: BF.cc:51
DAS::Unfolding::ZmmY::BF::setLmatrix
void setLmatrix(const std::unique_ptr< TH1 > &, std::unique_ptr< TH2 > &) override
See Observable::setLmatrix
Definition: BF.h:34
DAS::Unfolding::ZmmY
Definition: BF.h:20
DAS::Unfolding::ZmmY::BF
Definition: BF.h:23
Observable.h
DAS::Unfolding::ZmmY::BF::process
std::optional< int > process
Definition: BF.h:36
Di.h
Photon.h
DAS::Unfolding::ZmmY::BF::BF
BF()
Constructor.
Definition: BF.cc:176
DAS::Unfolding::ZmmY::processes
static const std::vector< const char * > processes
Definition: BF.h:50
DAS::Unfolding::ZmmY::BFFiller::genPhotons
std::optional< TTreeReaderArray< GenPhoton > > genPhotons
Definition: BF.h:57
DAS::Unfolding::ZmmY::BFFiller::BFFiller
BFFiller(const BF &obs, TTreeReader &reader)
Constructor.
Definition: BF.cc:40
DAS::Unfolding::ZmmY::BFFiller::match
void match() override
Definition: BF.h:73
Lepton.h
DAS::Unfolding::Observable
Definition: Observable.h:142
DAS::Unfolding::ZmmY::BFFiller::fillMC
void fillMC(DistVariation &) override
See Filler::fillMC
Definition: BF.cc:115
DAS::Unfolding::ZmmY::BFFiller::genMuons
std::optional< TTreeReaderArray< GenMuon > > genMuons
Definition: BF.h:56
DAS::Unfolding::ZmmY::BFFiller::gEv
std::optional< TTreeReaderValue< GenEvent > > gEv
Definition: BF.h:60