162 axis_titles[13] =
"#Sigma p_{T} / N_{Tracks} (GeV)";
163 axis_titles[14] =
"(1.5) X #Sigma E_{T}^{EM} + #Sigma E_{T}^{Had}";
176 names[4] =
"nTracks";
178 names[6] =
"trackerVetoPt";
179 names[7] =
"emVetoEt";
180 names[8] =
"hadVetoEt";
181 names[9] =
"hoVetoEt";
182 names[10] =
"muonPt";
183 names[11] =
"muonEta";
184 names[12] =
"muonPhi";
186 names[14] =
"weightedEt";
187 names[15] =
"PFsumChargedHadronPt";
188 names[16] =
"PFsumChargedTotalPt";
189 names[17] =
"PFsumEMuPt";
190 names[18] =
"PFsumNeutralHadronEt";
191 names[19] =
"PFsumPhotonEt";
192 names[20] =
"PFsumPUPt";
205 param[1][0] = (int)(20.0 / S_BIN_WIDTH);
208 param[2][0] = (int)(20.0 / S_BIN_WIDTH);
220 param[6][0] = (int)(40.0 / S_BIN_WIDTH);
226 param[8][0] = (int)(20.0 / S_BIN_WIDTH);
232 param[10][0] = (int)(40.0 / S_BIN_WIDTH);
241 param[13][0] = (int)(15.0 / S_BIN_WIDTH);
244 param[14][0] = (int)(20.0 / S_BIN_WIDTH);
247 param[15][0] = (int)(20.0 / S_BIN_WIDTH);
250 param[16][0] = (int)(20.0 / S_BIN_WIDTH);
253 param[17][0] = (int)(20.0 / S_BIN_WIDTH) + 1;
256 param[18][0] = (int)(20.0 / S_BIN_WIDTH);
259 param[19][0] = (int)(20.0 / S_BIN_WIDTH);
262 param[20][0] = (int)(20.0 / S_BIN_WIDTH);
324 edm::LogInfo(
"Tutorial") <<
"Number of Muons: " << muonsHandle->size();
333 if (
muon->combinedMuon().isNull())
343 theData[0] = muon->isolationR03().sumPt;
344 theData[1] = muon->isolationR03().emEt;
345 theData[2] = muon->isolationR03().hadEt;
346 theData[3] = muon->isolationR03().hoEt;
348 theData[4] = muon->isolationR03().nTracks;
349 theData[5] = muon->isolationR03().nJets;
350 theData[6] = muon->isolationR03().trackerVetoPt;
351 theData[7] = muon->isolationR03().emVetoEt;
352 theData[8] = muon->isolationR03().hadVetoEt;
353 theData[9] = muon->isolationR03().hoVetoEt;
374 if (muon->isPFMuon() && muon->isPFIsolationValid()) {
375 theData[15] = muon->pfIsolationR03().sumChargedHadronPt;
376 theData[16] = muon->pfIsolationR03().sumChargedParticlePt;
377 theData[17] = muon->pfIsolationR03().sumChargedParticlePt - muon->pfIsolationR03().sumChargedHadronPt;
378 theData[18] = muon->pfIsolationR03().sumNeutralHadronEt;
379 theData[19] = muon->pfIsolationR03().sumPhotonEt;
380 theData[20] = muon->pfIsolationR03().sumPUPt;
398 [](TH1* th1) { th1->Sumw2(); });
408 [](TH1* th1) { th1->Sumw2(); });
415 for (
int var1 = 0; var1 <
NUM_VARS; var1++) {
416 for (
int var2 = 0; var2 <
NUM_VARS; var2++) {
431 [&](TProfile* tprof) {
451 p_2D[4][9]->setAxisRange(0.5, 15.5,
XAXIS);
458 const double first_bin_width = (r > 1.0) ?
459 (max -
min) * (1 - r) / (1 -
pow(r, nbins))
460 : (max - min) /
nbins;
463 bin_edges[1] = min + first_bin_width;
465 bin_edges[
n] = bin_edges[
n - 1] + (bin_edges[
n - 1] - bin_edges[
n - 2]) * r;
479 for (
int var1 = 0; var1 <
NUM_VARS; ++var1) {
480 for (
int var2 = 0; var2 <
NUM_VARS; ++var2) {
void RecordData(MuonIterator muon)
T getUntrackedParameter(std::string const &, T const &) const
void analyze(const edm::Event &, const edm::EventSetup &) override
std::vector< int > isContinuous
virtual void setCurrentFolder(std::string const &fullpath)
std::vector< std::string > names
bool getByToken(EDGetToken token, Handle< PROD > &result) const
#define DEFINE_FWK_MODULE(type)
edm::View< reco::Muon >::const_iterator MuonIterator
std::vector< std::string > main_titles
MuIsoValidation(const edm::ParameterSet &)
std::vector< std::vector< MonitorElement * > > p_2D
std::vector< MonitorElement * > h_1D
edm::EDGetTokenT< edm::View< reco::Muon > > Muon_Token
MonitorElement * h_nMuons
edm::ParameterSet iConfig
MonitorElement * bookProfile(TString const &name, TString const &title, int nchX, double lowX, double highX, int, double lowY, double highY, char const *option="s", FUNC onbooking=NOOP())
std::vector< MonitorElement * > cd_plots
list var
if using global norm cols_to_minmax = ['t_delta', 't_hmaxNearP','t_emaxNearP', 't_hAnnular', 't_eAnnular','t_pt','t_nVtx','t_ieta','t_eHcal10', 't_eHcal30','t_rhoh','t_eHcal'] df[cols_to_minmax] = df[cols_to_minmax].apply(lambda x: (x - x.min()) / (x.max() - x.min()) if (x.max() - x.min() > 0) else 1.0/200.0)
static const int NUM_VARS
~MuIsoValidation() override
Log< level::Info, false > LogInfo
std::vector< std::vector< double > > param
void MakeLogBinsForProfile(Double_t *bin_edges, const double min, const double max)
std::vector< std::string > axis_titles
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
Power< A, B >::type pow(const A &a, const B &b)
std::string subsystemname_
std::vector< int > cdCompNeeded
virtual void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)