Main Page
Namespaces
Classes
Package Documentation
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Pages
DQMOffline
EGamma
plugins
ElectronOfflineClient.cc
Go to the documentation of this file.
1
2
#include "
DQMOffline/EGamma/plugins/ElectronOfflineClient.h
"
3
#include "
DQMServices/Core/interface/MonitorElement.h
"
4
#include "
FWCore/ParameterSet/interface/ParameterSet.h
"
5
#include "
FWCore/MessageLogger/interface/MessageLogger.h
"
6
7
#include "
CondCore/CondDB/interface/Serialization.h
"
8
9
#include <string>
10
11
ElectronOfflineClient::ElectronOfflineClient
(
const
edm::ParameterSet
&
conf
)
12
:
ElectronDqmHarvesterBase
(conf)
13
{
14
effHistoTitle_
= conf.
getParameter
<
std::string
>(
"EffHistoTitle"
) ;
15
}
16
17
ElectronOfflineClient::~ElectronOfflineClient
()
18
{}
19
20
void
ElectronOfflineClient::finalize
(
DQMStore::IBooker
& iBooker,
DQMStore::IGetter
& iGetter )
21
{
22
// MonitorElement * h1_matchedEle_eta = get("matchedEle_eta");
23
// MonitorElement * h1_matchedEle_eta_golden = get("matchedEle_eta_golden");
24
// MonitorElement * h1_matchedEle_eta_shower = get("matchedEle_eta_shower");
25
// //MonitorElement * h1_matchedEle_eta_bbrem = get("matchedEle_eta_bbrem");
26
// //MonitorElement * h1_matchedEle_eta_narrow = get("matchedEle_eta_narrow");
27
// MonitorElement * h1_matchedEle_eta_goldenFrac = cloneH1("matchedEle_eta_goldenFrac","matchedEle_eta","fraction of golden electrons") ;
28
// MonitorElement * h1_matchedEle_eta_showerFrac = cloneH1("matchedEle_eta_showerFrac","matchedEle_eta","fraction of showering electrons") ;
29
// //MonitorElement * h1_matchedEle_eta_bbremFrac = cloneH1("matchedEle_eta_bbremFrac","matchedEle_eta","fraction of bbrem electrons") ;
30
// //MonitorElement * h1_matchedEle_eta_narrowFrac = cloneH1("matchedEle_eta_narrowFrac","matchedEle_eta","fraction of narrow electrons") ;
31
// int nb, nbins=h_matchedEle_eta->getNbinsX() ;
32
// for ( nb=0 ; nb<nbins ; ++nb )
33
// {
34
// float content = h1_matchedEle_eta->getBinContent(nb) ;
35
// if (content==0.) continue ;
36
// float contgold =( h1_matchedEle_eta_golden->getBinContent(nb))/content ;
37
// float contshower =( h1_matchedEle_eta_shower->getBinContent(nb))/content ;
38
// //float contbbrem =( h1_matchedEle_eta_bbrem->getBinContent(nb))/content ;
39
// //float contnarrow =( h1_matchedEle_eta_narrow->getBinContent(nb))/content ;
40
// h1_matchedEle_eta_goldenFrac ->setBinContent(nb,contgold) ;
41
// h1_matchedEle_eta_showerFrac ->setBinContent(nb,contshower) ;
42
// //h1_matchedEle_eta_bbremFrac ->setBinContent(nb,contbbrem) ;
43
// //h1_matchedEle_eta_narrowFrac ->setBinContent(nb,contnarrow) ;
44
// }
45
// remove(iBooker,iGetter, "matchedEle_eta") ;
46
// remove(iBooker,iGetter, "matchedEle_eta_golden") ;
47
// remove(iBooker,iGetter, "matchedEle_eta_shower") ;
48
// //remove(iBooker,iGetter, "matchedEle_eta_bbrem") ;
49
// //remove(iBooker,iGetter, "matchedEle_eta_narrow") ;
50
51
setBookIndex
(100) ;
52
if
(
effHistoTitle_
==
""
)
53
{
54
bookH1andDivide
(iBooker,iGetter,
"ptEff"
,
"matchedObject_Pt"
,
"matchingObject_Pt"
,
"p_{T} (GeV/c)"
,
"Efficiency"
,
"efficiency vs p_{T}"
) ;
55
bookH1andDivide
(iBooker,iGetter,
"etaEff"
,
"matchedObject_Eta"
,
"matchingObject_Eta"
,
"#eta"
,
"Efficiency"
,
"efficiency vs #eta"
) ;
56
// bookH1andDivide(iBooker,iGetter, "absEtaEff","matchedObject_AbsEta","matchingObject_AbsEta","|#eta|","Efficiency","efficiency vs |#eta|") ;
57
bookH1andDivide
(iBooker,iGetter,
"phiEff"
,
"matchedObject_Phi"
,
"matchingObject_Phi"
,
"#phi (rad)"
,
"Efficiency"
,
"efficiency vs #phi"
) ;
58
// bookH1andDivide(iBooker,iGetter, "zEff","matchedObject_Z","matchingObject_Z","z (cm)","Efficiency","efficiency vs z") ;
59
}
60
else
61
{
62
bookH1andDivide
(iBooker,iGetter,
"ptEff"
,
"matchedObject_Pt"
,
"matchingObject_Pt"
,
"p_{T} (GeV/c)"
,
"Efficiency"
,
effHistoTitle_
) ;
63
bookH1andDivide
(iBooker,iGetter,
"etaEff"
,
"matchedObject_Eta"
,
"matchingObject_Eta"
,
"#eta"
,
"Efficiency"
,
effHistoTitle_
) ;
64
// bookH1andDivide(iBooker,iGetter, "absEtaEff","matchedObject_AbsEta","matchingObject_AbsEta","|#eta|","Efficiency",effHistoTitle_) ;
65
bookH1andDivide
(iBooker,iGetter,
"phiEff"
,
"matchedObject_Phi"
,
"matchingObject_Phi"
,
"#phi (rad)"
,
"Efficiency"
,
effHistoTitle_
) ;
66
// bookH1andDivide(iBooker,iGetter, "zEff","matchedObject_Z","matchingObject_Z","z (cm)","Efficiency",effHistoTitle_) ;
67
}
68
69
remove
(iBooker,iGetter,
"matchedObject_Pt"
) ;
// A.C.
70
remove
(iBooker,iGetter,
"matchedObject_Eta"
) ;
71
// remove(iBooker,iGetter, "matchedObject_AbsEta") ;
72
remove
(iBooker,iGetter,
"matchedObject_Phi"
) ;
73
// remove(iBooker,iGetter, "matchedObject_Z") ;
74
75
remove
(iBooker,iGetter,
"matchingObject_Pt"
) ;
76
remove
(iBooker,iGetter,
"matchingObject_Eta"
) ;
77
// remove(iBooker,iGetter, "matchingObject_AbsEta") ;/**/ //A.C.
78
remove
(iBooker, iGetter,
"matchingObject_Phi"
) ;
79
// remove(iBooker,iGetter, "matchingObject_Z") ;
80
}
81
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
MessageLogger.h
ElectronOfflineClient::finalize
virtual void finalize(DQMStore::IBooker &iBooker, DQMStore::IGetter &iGetter)
Definition:
ElectronOfflineClient.cc:20
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:255
Serialization.h
ElectronDqmHarvesterBase
Definition:
ElectronDqmHarvesterBase.h:19
ParameterSet.h
ElectronOfflineClient::~ElectronOfflineClient
virtual ~ElectronOfflineClient()
Definition:
ElectronOfflineClient.cc:17
DQMStore::IGetter
Definition:
DQMStore.h:190
ElectronOfflineClient.h
dbtoconf.conf
tuple conf
Definition:
dbtoconf.py:185
ElectronDqmHarvesterBase::setBookIndex
void setBookIndex(short)
Definition:
ElectronDqmHarvesterBase.cc:37
MonitorElement.h
ElectronDqmHarvesterBase::bookH1andDivide
MonitorElement * bookH1andDivide(DQMStore::IBooker &iBooker, DQMStore::IGetter &, const std::string &name, MonitorElement *num, MonitorElement *denom, const std::string &titleX, const std::string &titleY, const std::string &title="")
Definition:
ElectronDqmHarvesterBase.cc:272
ElectronOfflineClient::ElectronOfflineClient
ElectronOfflineClient(const edm::ParameterSet &)
Definition:
ElectronOfflineClient.cc:11
ElectronOfflineClient::effHistoTitle_
std::string effHistoTitle_
Definition:
ElectronOfflineClient.h:17
edm::ParameterSet
Definition:
ParameterSet.h:36
DQMStore::IBooker
Definition:
DQMStore.h:90
Generated for CMSSW Reference Manual by
1.8.5