CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Member Functions | Private Attributes
HLTExoticaSubAnalysis Class Reference

#include <HLTExoticaSubAnalysis.h>

Public Types

typedef dqm::legacy::DQMStore DQMStore
 
enum  Level { Level::GEN = 98, Level::RECO = 99 }
 
typedef dqm::legacy::MonitorElement MonitorElement
 

Public Member Functions

void analyze (const edm::Event &iEvent, const edm::EventSetup &iEventSetup, EVTColContainer *cols)
 
void beginJob ()
 
void beginRun (const edm::Run &iRun, const edm::EventSetup &iEventSetup)
 
void endRun ()
 
 HLTExoticaSubAnalysis (const edm::ParameterSet &pset, const std::string &analysisname, edm::ConsumesCollector &&consCollector)
 Constructor. More...
 
void subAnalysisBookHistos (DQMStore::IBooker &iBooker, const edm::Run &iRun, const edm::EventSetup &iSetup)
 
 ~HLTExoticaSubAnalysis ()
 End Constructor. More...
 

Private Member Functions

void bookHist (DQMStore::IBooker &iBooker, const std::string &source, const std::string &objType, const std::string &variable)
 The internal functions to book and fill histograms. More...
 
void fillHist (const std::string &source, const std::string &objType, const std::string &variable, const float &value)
 
void getHandlesToObjects (const edm::Event &iEvent, EVTColContainer *col)
 Gets the collections themselves. More...
 
void getNamesOfObjects (const edm::ParameterSet &anpset)
 Creates the maps that map which collection should come from which label. More...
 
const std::vector< unsigned int > getObjectsType (const std::string &hltpath) const
 closes analyze method More...
 
void initSelector (const unsigned int &objtype)
 Initializes the selectors of the objects based on which object it is. More...
 
void insertCandidates (const unsigned int &objtype, const EVTColContainer *col, std::vector< reco::LeafCandidate > *matches, std::map< int, double > &theSumEt, std::map< int, std::vector< const reco::Track * >> &trkObjs)
 
void registerConsumes (edm::ConsumesCollector &consCollector)
 Registers consumption of objects. More...
 

Private Attributes

std::string _analysisname
 The name of this sub-analysis. More...
 
edm::InputTag _beamSpotLabel
 
edm::EDGetTokenT< reco::BeamSpot_bsToken
 
bool _drop_pt2
 
bool _drop_pt3
 
std::map< std::string, MonitorElement * > _elements
 Structure of the MonitorElements. More...
 
std::map< unsigned int, std::string > _genCut
 gen/rec objects cuts More...
 
std::map< unsigned int, std::string > _genCut_leading
 gen/rec pt-leading objects cuts More...
 
StringCutObjectSelector< reco::GenMET > * _genMETSelector
 
edm::InputTag _genParticleLabel
 
edm::EDGetTokenT< reco::GenParticleCollection_genParticleToken
 And also the tokens to get the object collections. More...
 
std::map< unsigned int, StringCutObjectSelector< reco::GenParticle > * > _genSelectorMap
 
HLTConfigProvider _hltConfig
 Interface to the HLT information. More...
 
std::set< std::string > _hltPaths
 The hlt paths found in the hltConfig. More...
 
std::vector< std::string > _hltPathsToCheck
 The hlt paths to check for. More...
 
std::string _hltProcessName
 The labels of the object collections to be used in this analysis. More...
 
StringCutObjectSelector< l1extra::L1EtMissParticle > * _l1METSelector
 
unsigned int _minCandidates
 The minimum number of reco/gen candidates needed by the analysis. More...
 
std::vector< double > _parametersDxy
 
std::vector< double > _parametersEta
 Some kinematical parameters. More...
 
std::vector< double > _parametersPhi
 
std::vector< double > _parametersTurnOn
 
std::vector< double > _parametersTurnOnSumEt
 
std::vector< HLTExoticaPlotter_plotters
 The plotters: managers of each hlt path where the plots are done. More...
 
edm::ParameterSet _pset
 Internal, working copy of the PSet passed from above. More...
 
StringCutObjectSelector< reco::CaloJet > * _recCaloJetSelector
 
StringCutObjectSelector< reco::CaloMET > * _recCaloMETSelector
 
StringCutObjectSelector< reco::CaloMET > * _recCaloMHTSelector
 
std::map< unsigned int, std::string > _recCut
 
std::map< unsigned int, std::string > _recCut_leading
 
StringCutObjectSelector< reco::GsfElectron > * _recElecSelector
 
std::map< unsigned int, edm::InputTag_recLabels
 
StringCutObjectSelector< reco::MET > * _recMETSelector
 
StringCutObjectSelector< reco::Muon > * _recMuonSelector
 
StringCutObjectSelector< reco::Track > * _recMuonTrkSelector
 
StringCutObjectSelector< reco::PFJet > * _recPFJetSelector
 
StringCutObjectSelector< reco::PFMET > * _recPFMETSelector
 
StringCutObjectSelector< reco::PFMET > * _recPFMHTSelector
 
StringCutObjectSelector< reco::PFTau > * _recPFTauSelector
 
StringCutObjectSelector< reco::Photon > * _recPhotonSelector
 
StringCutObjectSelector< reco::Track > * _recTrackSelector
 
std::map< std::string, std::string > _shortpath2long
 Relation between the short and long versions of the path. More...
 
std::map< unsigned int, edm::EDGetToken_tokens
 
std::map< std::string, int > _triggerCounter
 counting HLT passed events More...
 
edm::InputTag _trigResultsLabel
 
edm::EDGetTokenT< edm::TriggerResults_trigResultsToken
 

Detailed Description

This class is the main workhorse of the package. It makes the histograms for one given analysis, taking care of all HLT paths related to that analysis.

Generate histograms for trigger efficiencies Exotica related Documentation available on the CMS TWiki: https://twiki.cern.ch/twiki/bin/view/CMS/EXOTICATriggerValidation

Author
Thiago R. Fernandez Perez Tomei Based and adapted from: J. Duarte Campderros code from HLTriggerOffline/Higgs J. Klukas, M. Vander Donckt and J. Alcaraz code from the HLTriggerOffline/Muon package.

Definition at line 65 of file HLTExoticaSubAnalysis.h.

Member Typedef Documentation

◆ DQMStore

Definition at line 67 of file HLTExoticaSubAnalysis.h.

◆ MonitorElement

Definition at line 68 of file HLTExoticaSubAnalysis.h.

Member Enumeration Documentation

◆ Level

Enumerator
GEN 
RECO 

Definition at line 70 of file HLTExoticaSubAnalysis.h.

70 { GEN = 98, RECO = 99 };

Constructor & Destructor Documentation

◆ HLTExoticaSubAnalysis()

HLTExoticaSubAnalysis::HLTExoticaSubAnalysis ( const edm::ParameterSet pset,
const std::string &  analysisname,
edm::ConsumesCollector &&  consCollector 
)

Constructor.

Get the vector of paths to check, for this particular analysis.

Get the minimum candidates, for this particular analysis.

Definition at line 28 of file HLTExoticaSubAnalysis.cc.

31  : _pset(pset),
32  _analysisname(analysisname),
33  _minCandidates(0),
34  _hltProcessName(pset.getParameter<std::string>("hltProcessName")),
35  _genParticleLabel(pset.getParameter<std::string>("genParticleLabel")),
36  _trigResultsLabel("TriggerResults", "", _hltProcessName),
37  _beamSpotLabel(pset.getParameter<std::string>("beamSpotLabel")),
38  _parametersEta(pset.getParameter<std::vector<double>>("parametersEta")),
39  _parametersPhi(pset.getParameter<std::vector<double>>("parametersPhi")),
40  _parametersTurnOn(pset.getParameter<std::vector<double>>("parametersTurnOn")),
41  _parametersTurnOnSumEt(pset.getParameter<std::vector<double>>("parametersTurnOnSumEt")),
42  _parametersDxy(pset.getParameter<std::vector<double>>("parametersDxy")),
43  _drop_pt2(false),
44  _drop_pt3(false),
45  _recMuonSelector(nullptr),
46  _recMuonTrkSelector(nullptr),
47  _recTrackSelector(nullptr),
48  _recElecSelector(nullptr),
49  _recMETSelector(nullptr),
50  _recPFMETSelector(nullptr),
51  _recPFMHTSelector(nullptr),
52  _genMETSelector(nullptr),
53  _recCaloMETSelector(nullptr),
54  _recCaloMHTSelector(nullptr),
55  _l1METSelector(nullptr),
56  _recPFTauSelector(nullptr),
57  _recPhotonSelector(nullptr),
58  _recPFJetSelector(nullptr),
59  _recCaloJetSelector(nullptr) {
60  LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::constructor()";
61 
62  // Specific parameters for this analysis
63  edm::ParameterSet anpset = pset.getParameter<edm::ParameterSet>(analysisname);
64 
65  // If this analysis has a particular set of binnings, use it.
66  // (Taken from the analysis-specific parameter set, of course)
67  // The "true" in the beginning of _pset.insert() means
68  // "overwrite the parameter if need be".
69  if (anpset.exists("parametersTurnOn")) {
70  _parametersTurnOn = anpset.getParameter<std::vector<double>>("parametersTurnOn");
71  _pset.insert(true, "parametersTurnOn", anpset.retrieve("parametersTurnOn"));
72  }
73  if (anpset.exists("parametersEta")) {
74  _parametersEta = anpset.getParameter<std::vector<double>>("parametersEta");
75  _pset.insert(true, "parametersEta", anpset.retrieve("parametersEta"));
76  }
77  if (anpset.exists("parametersPhi")) {
78  _parametersPhi = anpset.getParameter<std::vector<double>>("parametersPhi");
79  _pset.insert(true, "parametersPhi", anpset.retrieve("parametersPhi"));
80  }
81  if (anpset.exists("parametersDxy")) {
82  _parametersDxy = anpset.getParameter<std::vector<double>>("parametersDxy");
83  _pset.insert(true, "parametersDxy", anpset.retrieve("parametersDxy"));
84  }
85  if (anpset.exists("parametersTurnOnSumEt")) {
86  _parametersTurnOnSumEt = anpset.getParameter<std::vector<double>>("parametersTurnOnSumEt");
87  _pset.insert(true, "parametersTurnOnSumEt", anpset.retrieve("parametersTurnOnSumEt"));
88  }
89  if (anpset.exists("dropPt2")) {
90  _drop_pt2 = anpset.getParameter<bool>("dropPt2");
91  _pset.insert(true, "dropPt2", anpset.retrieve("dropPt2"));
92  }
93  if (anpset.exists("dropPt3")) {
94  _drop_pt3 = anpset.getParameter<bool>("dropPt3");
95  _pset.insert(true, "dropPt3", anpset.retrieve("dropPt3"));
96  }
97 
98  // Get names of objects that we may want to get from the event.
99  // Notice that genParticles are dealt with separately.
100  this->getNamesOfObjects(anpset);
101 
102  // Since now we have the names, we should register the consumption
103  // of objects.
104  this->registerConsumes(consCollector);
105 
106  // Generic objects: Initialization of basic phase space cuts.
107  for (std::map<unsigned int, edm::InputTag>::const_iterator it = _recLabels.begin(); it != _recLabels.end(); ++it) {
108  const std::string objStr = EVTColContainer::getTypeString(it->first);
109  _genCut[it->first] = pset.getParameter<std::string>(objStr + "_genCut");
110  _recCut[it->first] = pset.getParameter<std::string>(objStr + "_recCut");
111  auto const genCutParam = objStr + "_genCut_leading";
112  if (pset.exists(genCutParam)) {
113  _genCut_leading[it->first] = pset.getParameter<std::string>(genCutParam);
114  } else {
115  _genCut_leading[it->first] = "pt>0"; // no cut
116  }
117  auto const recCutParam = objStr + "_recCut_leading";
118  if (pset.exists(recCutParam)) {
119  _recCut_leading[it->first] = pset.getParameter<std::string>(recCutParam);
120  } else {
121  _recCut_leading[it->first] = "pt>0"; // no cut
122  }
123  }
124 
125  //--- Updating parameters if has to be modified for this particular specific
126  // analysis
127  for (std::map<unsigned int, edm::InputTag>::const_iterator it = _recLabels.begin(); it != _recLabels.end(); ++it) {
128  const std::string objStr = EVTColContainer::getTypeString(it->first);
129 
130  auto const genCutParam = objStr + "_genCut";
131  if (anpset.existsAs<std::string>(genCutParam, false)) {
132  _genCut[it->first] = anpset.getUntrackedParameter<std::string>(genCutParam);
133  }
134 
135  auto const recCutParam = objStr + "_recCut";
136  if (anpset.existsAs<std::string>(recCutParam, false)) {
137  _recCut[it->first] = anpset.getUntrackedParameter<std::string>(recCutParam);
138  }
139  }
140 
142  _hltPathsToCheck = anpset.getParameter<std::vector<std::string>>("hltPathsToCheck");
144  _minCandidates = anpset.getParameter<unsigned int>("minCandidates");
145 
146 }

References _drop_pt2, _drop_pt3, _genCut, _genCut_leading, _hltPathsToCheck, _minCandidates, _parametersDxy, _parametersEta, _parametersPhi, _parametersTurnOn, _parametersTurnOnSumEt, _pset, _recCut, _recCut_leading, _recLabels, edm::ParameterSet::exists(), edm::ParameterSet::existsAs(), getNamesOfObjects(), edm::ParameterSet::getParameter(), EVTColContainer::getTypeString(), edm::ParameterSet::getUntrackedParameter(), edm::ParameterSet::insert(), LogDebug, muonDTDigis_cfi::pset, registerConsumes(), edm::ParameterSet::retrieve(), and AlCaHLTBitMon_QueryRunRegistry::string.

◆ ~HLTExoticaSubAnalysis()

HLTExoticaSubAnalysis::~HLTExoticaSubAnalysis ( )

End Constructor.

Definition at line 148 of file HLTExoticaSubAnalysis.cc.

148  {
149  for (std::map<unsigned int, StringCutObjectSelector<reco::GenParticle> *>::iterator it = _genSelectorMap.begin();
150  it != _genSelectorMap.end();
151  ++it) {
152  delete it->second;
153  it->second = nullptr;
154  }
155  delete _recMuonSelector;
156  _recMuonSelector = nullptr;
157  delete _recMuonTrkSelector;
158  _recMuonTrkSelector = nullptr;
159  delete _recTrackSelector;
160  _recTrackSelector = nullptr;
161  delete _recElecSelector;
162  _recElecSelector = nullptr;
163  delete _recPhotonSelector;
164  _recPhotonSelector = nullptr;
165  delete _recMETSelector;
166  _recMETSelector = nullptr;
167  delete _recPFMETSelector;
168  _recPFMETSelector = nullptr;
169  delete _recPFMHTSelector;
170  _recPFMHTSelector = nullptr;
171  delete _genMETSelector;
172  _genMETSelector = nullptr;
173  delete _recCaloMETSelector;
174  _recCaloMETSelector = nullptr;
175  delete _recCaloMHTSelector;
176  _recCaloMHTSelector = nullptr;
177  delete _l1METSelector;
178  _l1METSelector = nullptr;
179  delete _recPFTauSelector;
180  _recPFTauSelector = nullptr;
181  delete _recPFJetSelector;
182  _recPFJetSelector = nullptr;
183  delete _recCaloJetSelector;
184  _recCaloJetSelector = nullptr;
185 }

References _genMETSelector, _genSelectorMap, _l1METSelector, _recCaloJetSelector, _recCaloMETSelector, _recCaloMHTSelector, _recElecSelector, _recMETSelector, _recMuonSelector, _recMuonTrkSelector, _recPFJetSelector, _recPFMETSelector, _recPFMHTSelector, _recPFTauSelector, _recPhotonSelector, _recTrackSelector, and genParticles_cff::map.

Member Function Documentation

◆ analyze()

void HLTExoticaSubAnalysis::analyze ( const edm::Event iEvent,
const edm::EventSetup iEventSetup,
EVTColContainer cols 
)

Method to fill all relevant histograms. Notice that we update the EVTColContaner to point to the collections we want.

We are going to make a fake reco::LeafCandidate, with our particleType as the pdgId. This is an alternative to the older implementation with MatchStruct.

Filling the histograms if pass the minimum amount of candidates needed by the analysis:

GEN CASE ///

Close GEN case

RECO CASE ///

Debugging.

Close RECO case

Definition at line 370 of file HLTExoticaSubAnalysis.cc.

370  {
371  LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::analyze()";
372 
373  // Loop over _recLabels to make sure everything is alright.
374  /*
375  std::cout << "Now printing the _recLabels" << std::endl;
376  for (std::map<unsigned int, edm::InputTag>::iterator it = _recLabels.begin();
377  it != _recLabels.end(); ++it) {
378  std::cout << "Number: " << it->first << "\t" << "Label: " <<
379  it->second.label() << std::endl;
380  }
381  */
382 
383  // Initialize the collection (the ones which have not been initialiazed yet)
384  // std::cout << "Setting handles to objects..." << std::endl;
385  this->getHandlesToObjects(iEvent, cols);
386 
387  // Utility map, mapping kinds of objects (GEN, RECO) to strings ("gen","rec")
388  // std::map<Level, std::string> u2str;
389  // u2str[Level::GEN] = "gen";
390  // u2str[Level::RECO] = "rec";
391 
392  // Extract the match structure containing the gen/reco candidates (electron,
393  // muons,...). This part is common to all the SubAnalyses
394  std::vector<reco::LeafCandidate> matchesGen;
395  matchesGen.clear();
396  std::vector<reco::LeafCandidate> matchesReco;
397  matchesReco.clear();
398  std::map<int, double> theSumEt; // map< pdgId ; SumEt > in order to keep track of the MET type
399  std::map<int, std::vector<const reco::Track *>> trkObjs;
400 
401  // --- deal with GEN objects first.
402  // Make each good GEN object into the base cand for a MatchStruct
403  // Our definition of "good" is "passes the selector" defined in the config.py
404  // Save all the MatchStructs in the "matchesGen" vector.
405 
406  for (std::map<unsigned int, edm::InputTag>::iterator it = _recLabels.begin(); it != _recLabels.end(); ++it) {
407  // Here we are filling the vector of
408  // StringCutObjectSelector<reco::GenParticle> with objects constructed from
409  // the strings saved in _genCut. Initialize selectors when first event
410 
411  // std::cout << "Loop over the kinds of objects: objects of kind " <<
412  // it->first << std::endl;
413 
414  if (!_genSelectorMap[it->first]) {
416  }
417 
418  const std::string objTypeStr = EVTColContainer::getTypeString(it->first);
419  // genAnyMET doesn't make sense. No need their matchesGens
420  if (TString(objTypeStr).Contains("MET") || TString(objTypeStr).Contains("MHT") ||
421  TString(objTypeStr).Contains("Jet"))
422  continue;
423 
424  // Now loop over the genParticles, and apply the operator() over each of
425  // them. Fancy syntax: for objects X and Y, X.operator()(Y) is the same as
426  // X(Y).
427  for (size_t i = 0; i < cols->genParticles->size(); ++i) {
428  // std::cout << "Now matchesGen.size() is " << matchesGen.size() <<
429  // std::endl;
430  if (_genSelectorMap[it->first]->operator()(cols->genParticles->at(i))) {
431  const reco::Candidate *cand = &(cols->genParticles->at(i));
432  // std::cout << "Found good cand: cand->pt() = " << cand->pt() <<
433  // std::endl; matchesGen.push_back(MatchStruct(cand, it->first));
437  reco::LeafCandidate v(0, cand->p4(), cand->vertex(), it->first, 0, true);
438 
439  matchesGen.push_back(v);
440  }
441  }
442  }
443 
444  // Sort the matches by pT for later filling of turn-on curve
445  // std::cout << "Before sorting: matchesGen.size() = " << matchesGen.size() <<
446  // std::endl;
447 
448  // GreaterByPt<reco::LeafCandidate> comparator;
449  // std::sort(matchesGen.begin(),
450  // matchesGen.end(),
451  // comparator);
452 
453  // --- same for RECO objects
454  // Extraction of the objects candidates
455  if (verbose > 0)
456  LogDebug("ExoticaValidation") << "-- enter loop over recLabels";
457  for (std::map<unsigned int, edm::InputTag>::iterator it = _recLabels.begin(); it != _recLabels.end(); ++it) {
458  // std::cout << "Filling RECO \"matchesReco\" vector for particle kind
459  // it->first = "
460  // << it->first << ", which means " << it->second.label() << std::endl;
461  // Reco selectors (the function takes into account if it was instantiated
462  // before or not) ### Thiago ---> Then why don't we put it in the
463  // beginRun???
464  this->initSelector(it->first);
465  // -- Storing the matchesReco
466  this->insertCandidates(it->first, cols, &matchesReco, theSumEt, trkObjs);
467  if (verbose > 0)
468  LogDebug("ExoticaValidation") << "--- " << EVTColContainer::getTypeString(it->first)
469  << " sumEt=" << theSumEt[it->first];
470  }
471 
472  // std::sort(matchesReco.begin(),
473  // matchesReco.end(),
474  // comparator);
475 
476  // -- Trigger Results
477  const edm::TriggerNames &trigNames = iEvent.triggerNames(*(cols->triggerResults));
478 
479  // counting HLT passed events for debugging
480  for (std::vector<HLTExoticaPlotter>::iterator an = _plotters.begin(); an != _plotters.end(); ++an) {
481  const std::string hltPath = _shortpath2long[an->gethltpath()];
482  const bool ispassTrigger = cols->triggerResults->accept(trigNames.triggerIndex(hltPath));
483  if (ispassTrigger)
484  _triggerCounter.find(an->gethltpath())->second++;
485  }
486 
489 
490  // for (std::map<unsigned int, std::vector<MatchStruct> >::iterator it =
491  // sourceMatchMap.begin(); it != sourceMatchMap.end(); ++it) {
492  // it->first: gen/reco it->second: HLT matches (std::vector<MatchStruct>)
493 
494  // if (it->second.size() < _minCandidates) { // FIXME: A bug is potentially
495  // here: what about the mixed channels? continue;
496  //}
497 
501  if (matchesGen.size() >= _minCandidates) { // FIXME: A bug is potentially here: what about the
502  // mixed channels?
503  // Okay, there are enough candidates. Move on!
504 
505  // Filling the gen/reco objects (eff-denominators):
506  // Just the first two different ones, if there are more
507  // The countobjects maps uints (object types, really) --> integers.
508  // Example:
509  // | uint | int |
510  // | 0 | 1 | --> 1 muon used
511  // | 1 | 2 | --> 2 electrons used
512 
513  // Initializing the count of the used objects.
514  std::map<unsigned int, int> countobjects;
515  for (std::map<unsigned int, edm::InputTag>::iterator co = _recLabels.begin(); co != _recLabels.end(); ++co) {
516  // countobjects->insert(std::pair<unsigned int, int>(co->first, 0));
517  countobjects.insert(std::pair<unsigned int, int>(co->first, 0));
518  }
519 
520  int counttotal = 0;
521 
522  // 3 : pt1, pt2, pt3
523  int totalobjectssize = 1;
524  if (!_drop_pt2)
525  totalobjectssize++;
526  if (!_drop_pt3)
527  totalobjectssize++;
528  totalobjectssize *= countobjects.size();
529 
530  bool isPassedLeadingCut = true;
531  // We will proceed only when cuts for the pt-leading are satisified.
532  for (size_t j = 0; j != matchesGen.size(); ++j) {
533  const unsigned int objType = matchesGen[j].pdgId();
534  // Cut for the pt-leading object
536  if (!select(matchesGen[j])) { // No interest case
537  isPassedLeadingCut = false; // Will skip the following matchesGen loop
538  matchesGen.clear();
539  break;
540  }
541  }
542 
543  std::vector<float> dxys;
544  dxys.clear();
545 
546  for (size_t j = 0; (j != matchesGen.size()) && isPassedLeadingCut; ++j) {
547  const unsigned int objType = matchesGen[j].pdgId();
548  // std::cout << "(4) Gonna call with " << objType << std::endl;
550 
551  float pt = matchesGen[j].pt();
552 
553  if (countobjects[objType] == 0) {
554  this->fillHist("gen", objTypeStr, "MaxPt1", pt);
555  ++(countobjects[objType]);
556  ++counttotal;
557  } else if (countobjects[objType] == 1 && !_drop_pt2) {
558  this->fillHist("gen", objTypeStr, "MaxPt2", pt);
559  ++(countobjects[objType]);
560  ++counttotal;
561  } else if (countobjects[objType] == 2 && !_drop_pt3) {
562  this->fillHist("gen", objTypeStr, "MaxPt3", pt);
563  ++(countobjects[objType]);
564  ++counttotal;
565  } else {
566  // Already the minimum three objects has been filled, get out...
567  if (counttotal == totalobjectssize) {
568  size_t max_size = matchesGen.size();
569  for (size_t jj = j; jj < max_size; jj++) {
570  matchesGen.erase(matchesGen.end());
571  }
572  break;
573  }
574  }
575 
576  float eta = matchesGen[j].eta();
577  float phi = matchesGen[j].phi();
578 
579  this->fillHist("gen", objTypeStr, "Eta", eta);
580  this->fillHist("gen", objTypeStr, "Phi", phi);
581 
582  // If the target is electron or muon,
583 
585  const math::XYZPoint &vtx = matchesGen[j].vertex();
586  float momphi = matchesGen[j].momentum().phi();
587  float dxyGen = (-(vtx.x() - cols->bs->x0()) * sin(momphi) + (vtx.y() - cols->bs->y0()) * cos(momphi));
588  dxys.push_back(dxyGen);
589  this->fillHist("gen", objTypeStr, "Dxy", dxyGen);
590  }
591 
592  } // Closes loop in gen
593 
594  // Calling to the plotters analysis (where the evaluation of the different
595  // trigger paths are done)
596  // const std::string source = "gen";
597  for (std::vector<HLTExoticaPlotter>::iterator an = _plotters.begin(); an != _plotters.end(); ++an) {
598  const std::string hltPath = _shortpath2long[an->gethltpath()];
599  const bool ispassTrigger = cols->triggerResults->accept(trigNames.triggerIndex(hltPath));
600  LogDebug("ExoticaValidation") << " preparing to call the plotters analysis";
601  an->analyze(ispassTrigger, "gen", matchesGen, theSumEt, dxys);
602  LogDebug("ExoticaValidation") << " called the plotter";
603  }
604  }
605 
609 
610  {
611  if (matchesReco.size() < _minCandidates)
612  return; // FIXME: A bug is potentially here: what about the mixed
613  // channels?
614 
615  // Okay, there are enough candidates. Move on!
616 
617  // Filling the gen/reco objects (eff-denominators):
618  // Just the first two different ones, if there are more
619  // The countobjects maps uints (object types, really) --> integers.
620  // Example:
621  // | uint | int |
622  // | 0 | 1 | --> 1 muon used
623  // | 1 | 2 | --> 2 electrons used
624  // Initializing the count of the used objects.
625  // std::map<unsigned int, int> * countobjects = new std::map<unsigned int,
626  // int>;
627  std::map<unsigned int, int> countobjects;
628  for (std::map<unsigned int, edm::InputTag>::iterator co = _recLabels.begin(); co != _recLabels.end(); ++co) {
629  countobjects.insert(std::pair<unsigned int, int>(co->first, 0));
630  }
631 
632  int counttotal = 0;
633 
634  // 3 : pt1, pt2, pt3
635  int totalobjectssize = 1;
636  if (!_drop_pt2)
637  totalobjectssize++;
638  if (!_drop_pt3)
639  totalobjectssize++;
640  totalobjectssize *= countobjects.size();
641 
643  // std::cout << "Our RECO vector has matchesReco.size() = " <<
644  // matchesReco.size() << std::endl;
645 
646  std::vector<float> dxys;
647  dxys.clear();
648 
649  bool isPassedLeadingCut = true;
650  // We will proceed only when cuts for the pt-leading are satisified.
651  for (size_t j = 0; j != matchesReco.size(); ++j) {
652  const unsigned int objType = matchesReco[j].pdgId();
653  // Cut for the pt-leading object
655  if (!select(matchesReco[j])) { // No interest case
656  isPassedLeadingCut = false; // Will skip the following matchesReco loop
657  matchesReco.clear();
658  break;
659  }
660  }
661 
662  for (size_t j = 0; (j != matchesReco.size()) && isPassedLeadingCut; ++j) {
663  const unsigned int objType = matchesReco[j].pdgId();
664  // std::cout << "(4) Gonna call with " << objType << std::endl;
666 
667  float pt = matchesReco[j].pt();
668 
669  if (countobjects[objType] == 0) {
670  this->fillHist("rec", objTypeStr, "MaxPt1", pt);
671  ++(countobjects[objType]);
672  ++counttotal;
673  } else if (countobjects[objType] == 1 && !_drop_pt2) {
674  if (!(TString(objTypeStr).Contains("MET") || TString(objTypeStr).Contains("MHT"))) {
675  this->fillHist("rec", objTypeStr, "MaxPt2", pt);
676  }
677  ++(countobjects[objType]);
678  ++counttotal;
679  } else if (countobjects[objType] == 2 && !_drop_pt3) {
680  if (!(TString(objTypeStr).Contains("MET") || TString(objTypeStr).Contains("MHT"))) {
681  this->fillHist("rec", objTypeStr, "MaxPt3", pt);
682  }
683  ++(countobjects[objType]);
684  ++counttotal;
685  } else {
686  // Already the minimum three objects has been filled, get out...
687  if (counttotal == totalobjectssize) {
688  size_t max_size = matchesReco.size();
689  for (size_t jj = j; jj < max_size; jj++) {
690  matchesReco.erase(matchesReco.end());
691  }
692  break;
693  }
694  }
695 
696  float eta = matchesReco[j].eta();
697  float phi = matchesReco[j].phi();
698 
699  if (!(TString(objTypeStr).Contains("MET") || TString(objTypeStr).Contains("MHT"))) {
700  this->fillHist("rec", objTypeStr, "Eta", eta);
701  this->fillHist("rec", objTypeStr, "Phi", phi);
702  } else {
703  this->fillHist("rec", objTypeStr, "SumEt", theSumEt[objType]);
704  }
705 
706  if (trkObjs[objType].size() >= j + 1) {
707  float dxyRec = trkObjs[objType].at(j)->dxy(cols->bs->position());
708  this->fillHist("rec", objTypeStr, "Dxy", dxyRec);
709  dxys.push_back(dxyRec);
710  }
711 
712  } // Closes loop in reco
713 
714  // LogDebug("ExoticaValidation") << " deleting
715  // countobjects"; delete countobjects;
716 
717  // Calling to the plotters analysis (where the evaluation of the different
718  // trigger paths are done)
719  // const std::string source = "reco";
720  for (std::vector<HLTExoticaPlotter>::iterator an = _plotters.begin(); an != _plotters.end(); ++an) {
721  const std::string hltPath = _shortpath2long[an->gethltpath()];
722  const bool ispassTrigger = cols->triggerResults->accept(trigNames.triggerIndex(hltPath));
723  LogDebug("ExoticaValidation") << " preparing to call the plotters analysis";
724  an->analyze(ispassTrigger, "rec", matchesReco, theSumEt, dxys);
725  LogDebug("ExoticaValidation") << " called the plotter";
726  }
727  }
728 
729 }

References _drop_pt2, _drop_pt3, _genCut, _genCut_leading, _genSelectorMap, _minCandidates, _plotters, _recCut_leading, _recLabels, _shortpath2long, _triggerCounter, edm::HLTGlobalStatus::accept(), EVTColContainer::bs, cms::cuda::co, funct::cos(), EVTColContainer::ELEC, PVValHelper::eta, fillHist(), EVTColContainer::genParticles, getHandlesToObjects(), EVTColContainer::getTypeString(), zMuMuMuonUserData::hltPath, mps_fire::i, iEvent, initSelector(), insertCandidates(), dqmiolumiharvest::j, findQualityFiles::jj, LogDebug, EVTColContainer::MUON, EVTColContainer::MUTRK, electrons_cff::objType, phi, reco::BeamSpot::position(), DiDispStaMuonMonitor_cfi::pt, edm::second(), singleTopDQM_cfi::select, funct::sin(), findQualityFiles::size, AlCaHLTBitMon_QueryRunRegistry::string, EVTColContainer::triggerResults, trigNames, findQualityFiles::v, verbose, extraflags_cff::vtx, reco::BeamSpot::x0(), and reco::BeamSpot::y0().

◆ beginJob()

void HLTExoticaSubAnalysis::beginJob ( void  )

Definition at line 187 of file HLTExoticaSubAnalysis.cc.

187 {}

◆ beginRun()

void HLTExoticaSubAnalysis::beginRun ( const edm::Run iRun,
const edm::EventSetup iEventSetup 
)

Construct the plotters right here. For that we need to create the _hltPaths vector.

Definition at line 265 of file HLTExoticaSubAnalysis.cc.

265  {
266  LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::beginRun()";
267 
270 
271  // Initialize the HLT config.
272  bool changedConfig(true);
273  if (!_hltConfig.init(iRun, iSetup, _hltProcessName, changedConfig)) {
274  edm::LogError("ExoticaValidation") << "HLTExoticaSubAnalysis::constructor(): "
275  << "Initialization of HLTConfigProvider failed!";
276  }
277 
278  // Parse the input paths to get them if they are in the table and associate
279  // them to the last filter of the path (in order to extract the objects).
280  _hltPaths.clear();
281  for (size_t i = 0; i < _hltPathsToCheck.size(); ++i) {
282  bool found = false;
283  TPRegexp pattern(_hltPathsToCheck[i]);
284 
285  // Loop over triggerNames from _hltConfig
286  for (size_t j = 0; j < _hltConfig.triggerNames().size(); ++j) {
287  std::string thetriggername = _hltConfig.triggerNames()[j];
288  if (TString(thetriggername).Contains(pattern)) {
289  _hltPaths.insert(thetriggername);
290  found = true;
291  }
292  if (verbose > 2 && i == 0)
293  LogDebug("ExoticaValidation") << "--- TRIGGER PATH : " << thetriggername;
294  }
295 
296  // Oh dear, the path we wanted seems to not be available
297  if (!found && verbose > 2) {
298  edm::LogWarning("ExoticaValidation") << "HLTExoticaSubAnalysis::constructor(): In " << _analysisname
299  << " subfolder NOT found the path: '" << _hltPathsToCheck[i] << "*'";
300  }
301  } // Close loop over paths to check.
302 
303  // At this point, _hltpaths contains the names of the paths to check
304  // that were found. Let's log it at trace level.
305  LogTrace("ExoticaValidation") << "SubAnalysis: " << _analysisname << "\nHLT Trigger Paths found >>>";
306  for (std::set<std::string>::const_iterator iter = _hltPaths.begin(); iter != _hltPaths.end(); ++iter) {
307  LogTrace("ExoticaValidation") << (*iter) << "\n";
308  }
309 
310  // Initialize the plotters (analysers for each trigger path)
311  _plotters.clear();
312  for (std::set<std::string>::iterator iPath = _hltPaths.begin(); iPath != _hltPaths.end(); ++iPath) {
313  // Avoiding the dependence of the version number for the trigger paths
314  std::string path = *iPath;
315  std::string shortpath = path;
316  if (path.rfind("_v") < path.length()) {
317  shortpath = path.substr(0, path.rfind("_v"));
318  }
319  _shortpath2long[shortpath] = path;
320 
321  // Objects needed by the HLT path
322  // Thiago: instead of trying to decode the objects from the path,
323  // put the burden on the user to tell us which objects are needed.
324  // const std::vector<unsigned int> objsNeedHLT =
325  // this->getObjectsType(shortpath);
326  std::vector<unsigned int> objsNeedHLT;
327  for (std::map<unsigned int, edm::InputTag>::iterator it = _recLabels.begin(); it != _recLabels.end(); ++it) {
328  objsNeedHLT.push_back(it->first);
329  }
330 
331  /*std::vector<unsigned int> userInstantiate;
332  // Sanity check: the object needed by a trigger path should be
333  // introduced by the user via config python (_recLabels datamember)
334  for (std::map<unsigned int, edm::InputTag>::iterator it = _recLabels.begin()
335  ; it != _recLabels.end(); ++it) { userInstantiate.push_back(it->first);
336  }
337  for (std::vector<unsigned int>::const_iterator it = objsNeedHLT.begin(); it
338  != objsNeedHLT.end();
339  ++it) {
340  if (std::find(userInstantiate.begin(), userInstantiate.end(), *it) ==
341  userInstantiate.end()) {
342  edm::LogError("ExoticaValidation") << "In
343  HLTExoticaSubAnalysis::beginRun, "
344  << "Incoherence found in the
345  python configuration file!!\nThe SubAnalysis '"
346  << _analysisname << "' has been
347  asked to evaluate the trigger path '"
348  << shortpath << "' (found it in
349  'hltPathsToCheck') BUT this path"
350  << " needs a '" <<
351  EVTColContainer::getTypeString(*it)
352  << "' which has not been
353  instantiated ('recVariableLabels'"
354  << ")" ;
355  exit(-1); // This should probably throw an exception...
356  }
357  }
358  */
359  LogTrace("ExoticaValidation") << " --- " << shortpath;
360 
361  // The hlt path, the objects (electrons, muons, photons, ...)
362  // needed to evaluate the path are the argumens of the plotter
363  HLTExoticaPlotter analyzer(_pset, shortpath, objsNeedHLT);
364  _plotters.push_back(analyzer);
365  // counting HLT passed events for debug
367  } // Okay, at this point we have prepared all the plotters.
368 }

References _analysisname, _hltConfig, _hltPaths, _hltPathsToCheck, _hltProcessName, _plotters, _pset, _recLabels, _shortpath2long, _triggerCounter, ramdisk_dqm_sourceclient-live_cfg::analyzer, newFWLiteAna::found, mps_fire::i, HLTConfigProvider::init(), dqmiolumiharvest::j, LogDebug, LogTrace, castor_dqm_sourceclient_file_cfg::path, topSingleLeptonDQM_PU_cfi::pattern, AlCaHLTBitMon_QueryRunRegistry::string, HLTConfigProvider::triggerNames(), and verbose.

◆ bookHist()

void HLTExoticaSubAnalysis::bookHist ( DQMStore::IBooker iBooker,
const std::string &  source,
const std::string &  objType,
const std::string &  variable 
)
private

The internal functions to book and fill histograms.

Definition at line 1047 of file HLTExoticaSubAnalysis.cc.

1050  {
1051  LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::bookHist()";
1052  std::string sourceUpper = source;
1053  sourceUpper[0] = std::toupper(sourceUpper[0]);
1055  TH1F *h = nullptr;
1056 
1057  if (variable.find("SumEt") != std::string::npos) {
1058  std::string title = "Sum ET of " + sourceUpper + " " + objType;
1059  const size_t nBins = _parametersTurnOnSumEt.size() - 1;
1060  float *edges = new float[nBins + 1];
1061  for (size_t i = 0; i < nBins + 1; i++) {
1063  }
1064  h = new TH1F(name.c_str(), title.c_str(), nBins, edges);
1065  delete[] edges;
1066  }
1067 
1068  else if (variable.find("Dxy") != std::string::npos) {
1069  std::string title = "Dxy " + sourceUpper + " " + objType;
1070  int nBins = _parametersDxy[0];
1071  double min = _parametersDxy[1];
1072  double max = _parametersDxy[2];
1073  h = new TH1F(name.c_str(), title.c_str(), nBins, min, max);
1074  }
1075 
1076  else if (variable.find("MaxPt") != std::string::npos) {
1077  std::string desc = (variable == "MaxPt1") ? "Leading" : "Next-to-Leading";
1078  std::string title = "pT of " + desc + " " + sourceUpper + " " + objType;
1079  const size_t nBins = _parametersTurnOn.size() - 1;
1080  float *edges = new float[nBins + 1];
1081  for (size_t i = 0; i < nBins + 1; i++) {
1082  edges[i] = _parametersTurnOn[i];
1083  }
1084  h = new TH1F(name.c_str(), title.c_str(), nBins, edges);
1085  delete[] edges;
1086  }
1087 
1088  else {
1089  std::string symbol = (variable == "Eta") ? "#eta" : "#phi";
1090  std::string title = symbol + " of " + sourceUpper + " " + objType;
1091  std::vector<double> params = (variable == "Eta") ? _parametersEta : _parametersPhi;
1092  int nBins = (int)params[0];
1093  double min = params[1];
1094  double max = params[2];
1095  h = new TH1F(name.c_str(), title.c_str(), nBins, min, max);
1096  }
1097 
1098  h->Sumw2();
1099  // This is the trick, that takes a normal TH1F and puts it in in the DQM
1100  // machinery. Seems to be easy!
1101  // Updated to use the new iBooker machinery.
1102  _elements[name] = iBooker.book1D(name, h);
1103  delete h;
1104 }

References _elements, _parametersDxy, _parametersEta, _parametersPhi, _parametersTurnOn, _parametersTurnOnSumEt, dqm::implementation::IBooker::book1D(), submitPVResolutionJobs::desc, SelectiveReadoutTask_cfi::edges, h, mps_fire::i, createfilelist::int, LogDebug, SiStripPI::max, min(), Skims_PA_cff::name, seedmultiplicitymonitor_newtracking_cfi::nBins, electrons_cff::objType, CalibrationSummaryClient_cfi::params, source, AlCaHLTBitMon_QueryRunRegistry::string, runGCPTkAlMap::title, and taus_updatedMVAIds_cff::variable.

Referenced by subAnalysisBookHistos().

◆ endRun()

void HLTExoticaSubAnalysis::endRun ( )

Definition at line 1321 of file HLTExoticaSubAnalysis.cc.

1321  {
1322  // Dump trigger results
1323  std::stringstream log;
1324  log << std::endl;
1325  log << "====================================================================="
1326  "======"
1327  << std::endl;
1328  log << " Trigger Results ( " << _analysisname << " ) " << std::endl;
1329  log << "====================================================================="
1330  "======"
1331  << std::endl;
1332  log << std::setw(18) << "# of passed events : HLT path names" << std::endl;
1333  log << "-------------------:-------------------------------------------------"
1334  "------"
1335  << std::endl;
1336  for (std::map<std::string, int>::iterator it = _triggerCounter.begin(); it != _triggerCounter.end(); ++it) {
1337  log << std::setw(18) << it->second << " : " << it->first << std::endl;
1338  }
1339  log << "====================================================================="
1340  "======"
1341  << std::endl;
1342  LogDebug("ExoticaValidation") << log.str().data();
1343 }

References _analysisname, _triggerCounter, dqm-mbProfile::log, and LogDebug.

◆ fillHist()

void HLTExoticaSubAnalysis::fillHist ( const std::string &  source,
const std::string &  objType,
const std::string &  variable,
const float &  value 
)
private

Definition at line 1107 of file HLTExoticaSubAnalysis.cc.

1110  {
1111  std::string sourceUpper = source;
1112  sourceUpper[0] = toupper(sourceUpper[0]);
1114 
1115  LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::fillHist() " << name << " " << value;
1116  _elements[name]->Fill(value);
1117  LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::fillHist() " << name << " worked";
1118 }

References _elements, LogDebug, Skims_PA_cff::name, electrons_cff::objType, source, AlCaHLTBitMon_QueryRunRegistry::string, relativeConstraints::value, and taus_updatedMVAIds_cff::variable.

Referenced by analyze().

◆ getHandlesToObjects()

void HLTExoticaSubAnalysis::getHandlesToObjects ( const edm::Event iEvent,
EVTColContainer col 
)
private

Gets the collections themselves.

Definition at line 933 of file HLTExoticaSubAnalysis.cc.

933  {
934  LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::getHandlesToObjects()";
935 
936  if (!col->isCommonInit()) {
937  // Extract the trigger results (path info, pass,...)
939  iEvent.getByToken(_trigResultsToken, trigResults);
940  if (trigResults.isValid()) {
941  col->triggerResults = trigResults.product();
942  LogDebug("ExoticaValidation") << "Added handle to triggerResults";
943  }
944 
945  // Extract the genParticles
947  iEvent.getByToken(_genParticleToken, genPart);
948  if (genPart.isValid()) {
949  col->genParticles = genPart.product();
950  LogDebug("ExoticaValidation") << "Added handle to genParticles";
951  }
952 
953  // BeamSpot for dxy
955  iEvent.getByToken(_bsToken, bsHandle);
956  if (bsHandle.isValid()) {
957  col->bs = bsHandle.product();
958  }
959  }
960 
961  // Loop over the tokens and extract all other objects
962  LogDebug("ExoticaValidation") << "We have got " << _tokens.size() << "tokens";
963  for (std::map<unsigned int, edm::EDGetToken>::iterator it = _tokens.begin(); it != _tokens.end(); ++it) {
964  if (it->first == EVTColContainer::MUON) {
966  iEvent.getByToken(it->second, theHandle);
967  if (theHandle.isValid())
968  col->set(theHandle.product());
969  } else if (it->first == EVTColContainer::MUTRK) {
971  iEvent.getByToken(it->second, theHandle);
972  if (theHandle.isValid())
973  col->set(theHandle.product());
974  } else if (it->first == EVTColContainer::TRACK) {
976  iEvent.getByToken(it->second, theHandle);
977  if (theHandle.isValid())
978  col->set(theHandle.product());
979  } else if (it->first == EVTColContainer::ELEC) {
981  iEvent.getByToken(it->second, theHandle);
982  if (theHandle.isValid())
983  col->set(theHandle.product());
984  } else if (it->first == EVTColContainer::PHOTON) {
986  iEvent.getByToken(it->second, theHandle);
987  if (theHandle.isValid())
988  col->set(theHandle.product());
989  } else if (it->first == EVTColContainer::MET) {
991  iEvent.getByToken(it->second, theHandle);
992  if (theHandle.isValid())
993  col->set(theHandle.product());
994  } else if (it->first == EVTColContainer::PFMET) {
996  iEvent.getByToken(it->second, theHandle);
997  if (theHandle.isValid())
998  col->set(theHandle.product());
999  } else if (it->first == EVTColContainer::PFMHT) {
1001  iEvent.getByToken(it->second, theHandle);
1002  if (theHandle.isValid())
1003  col->setPFMHT(theHandle.product());
1004  } else if (it->first == EVTColContainer::GENMET) {
1006  iEvent.getByToken(it->second, theHandle);
1007  if (theHandle.isValid())
1008  col->set(theHandle.product());
1009  } else if (it->first == EVTColContainer::CALOMET) {
1011  iEvent.getByToken(it->second, theHandle);
1012  if (theHandle.isValid())
1013  col->set(theHandle.product());
1014  } else if (it->first == EVTColContainer::CALOMHT) {
1016  iEvent.getByToken(it->second, theHandle);
1017  if (theHandle.isValid())
1018  col->setCaloMHT(theHandle.product());
1019  } else if (it->first == EVTColContainer::L1MET) {
1021  iEvent.getByToken(it->second, theHandle);
1022  if (theHandle.isValid())
1023  col->set(theHandle.product());
1024  } else if (it->first == EVTColContainer::PFTAU) {
1026  iEvent.getByToken(it->second, theHandle);
1027  if (theHandle.isValid())
1028  col->set(theHandle.product());
1029  } else if (it->first == EVTColContainer::PFJET) {
1031  iEvent.getByToken(it->second, theHandle);
1032  if (theHandle.isValid())
1033  col->set(theHandle.product());
1034  } else if (it->first == EVTColContainer::CALOJET) {
1036  iEvent.getByToken(it->second, theHandle);
1037  if (theHandle.isValid())
1038  col->set(theHandle.product());
1039  } else {
1040  edm::LogError("ExoticaValidation") << "HLTExoticaSubAnalysis::getHandlesToObjects "
1041  << " NOT IMPLEMENTED (yet) ERROR: '" << it->first << "'";
1042  }
1043  }
1044 }

References _bsToken, _genParticleToken, _tokens, _trigResultsToken, EVTColContainer::CALOJET, EVTColContainer::CALOMET, EVTColContainer::CALOMHT, cuy::col, EVTColContainer::ELEC, EVTColContainer::GENMET, iEvent, edm::HandleBase::isValid(), EVTColContainer::L1MET, LogDebug, EVTColContainer::MET, EVTColContainer::MUON, EVTColContainer::MUTRK, EVTColContainer::PFJET, EVTColContainer::PFMET, EVTColContainer::PFMHT, EVTColContainer::PFTAU, EVTColContainer::PHOTON, edm::Handle< T >::product(), and EVTColContainer::TRACK.

Referenced by analyze().

◆ getNamesOfObjects()

void HLTExoticaSubAnalysis::getNamesOfObjects ( const edm::ParameterSet anpset)
private

Creates the maps that map which collection should come from which label.

Definition at line 769 of file HLTExoticaSubAnalysis.cc.

769  {
770  LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::getNamesOfObjects()";
771 
772  if (anpset.exists("recMuonLabel")) {
773  _recLabels[EVTColContainer::MUON] = anpset.getParameter<edm::InputTag>("recMuonLabel");
775  }
776  if (anpset.exists("recMuonTrkLabel")) {
777  _recLabels[EVTColContainer::MUTRK] = anpset.getParameter<edm::InputTag>("recMuonTrkLabel");
779  }
780  if (anpset.exists("recTrackLabel")) {
781  _recLabels[EVTColContainer::TRACK] = anpset.getParameter<edm::InputTag>("recTrackLabel");
783  }
784  if (anpset.exists("recElecLabel")) {
785  _recLabels[EVTColContainer::ELEC] = anpset.getParameter<edm::InputTag>("recElecLabel");
787  }
788  if (anpset.exists("recPhotonLabel")) {
789  _recLabels[EVTColContainer::PHOTON] = anpset.getParameter<edm::InputTag>("recPhotonLabel");
791  }
792  if (anpset.exists("recMETLabel")) {
793  _recLabels[EVTColContainer::MET] = anpset.getParameter<edm::InputTag>("recMETLabel");
795  }
796  if (anpset.exists("recPFMETLabel")) {
797  _recLabels[EVTColContainer::PFMET] = anpset.getParameter<edm::InputTag>("recPFMETLabel");
799  }
800  if (anpset.exists("recPFMHTLabel")) {
801  _recLabels[EVTColContainer::PFMHT] = anpset.getParameter<edm::InputTag>("recPFMHTLabel");
803  }
804  if (anpset.exists("genMETLabel")) {
807  }
808  if (anpset.exists("recCaloMETLabel")) {
809  _recLabels[EVTColContainer::CALOMET] = anpset.getParameter<edm::InputTag>("recCaloMETLabel");
811  }
812  if (anpset.exists("recCaloMHTLabel")) {
813  _recLabels[EVTColContainer::CALOMHT] = anpset.getParameter<edm::InputTag>("recCaloMHTLabel");
815  }
816  if (anpset.exists("hltMETLabel")) {
819  }
820  if (anpset.exists("l1METLabel")) {
823  }
824  if (anpset.exists("recPFTauLabel")) {
825  _recLabels[EVTColContainer::PFTAU] = anpset.getParameter<edm::InputTag>("recPFTauLabel");
827  }
828  if (anpset.exists("recPFJetLabel")) {
829  _recLabels[EVTColContainer::PFJET] = anpset.getParameter<edm::InputTag>("recPFJetLabel");
831  }
832  if (anpset.exists("recCaloJetLabel")) {
833  _recLabels[EVTColContainer::CALOJET] = anpset.getParameter<edm::InputTag>("recCaloJetLabel");
835  }
836 
837  if (_recLabels.empty()) {
838  edm::LogError("ExoticaValidation") << "HLTExoticaSubAnalysis::getNamesOfObjects, "
839  << "Not included any object (recMuonLabel, recElecLabel, ...) "
840  << "in the analysis " << _analysisname;
841  return;
842  }
843 }

References _analysisname, _genSelectorMap, _recLabels, EVTColContainer::CALOJET, EVTColContainer::CALOMET, EVTColContainer::CALOMHT, EVTColContainer::ELEC, edm::ParameterSet::exists(), EVTColContainer::GENMET, edm::ParameterSet::getParameter(), EVTColContainer::L1MET, LogDebug, EVTColContainer::MET, EVTColContainer::MUON, EVTColContainer::MUTRK, EVTColContainer::PFJET, EVTColContainer::PFMET, EVTColContainer::PFMHT, EVTColContainer::PFTAU, EVTColContainer::PHOTON, and EVTColContainer::TRACK.

Referenced by HLTExoticaSubAnalysis().

◆ getObjectsType()

const std::vector< unsigned int > HLTExoticaSubAnalysis::getObjectsType ( const std::string &  hltpath) const
private

closes analyze method

Return the objects (muons,electrons,photons,...) needed by a HLT path. Will in general return: 0 for muon, 1 for electron, 2 for photon, 3 for PFMET, 4 for PFTau, 5 for Jet. Notice that this function is really based on a parsing of the name of the path; any incongruences there may lead to problems.

Definition at line 732 of file HLTExoticaSubAnalysis.cc.

732  {
733  LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::getObjectsType()";
734 
735  static const unsigned int objSize = 15;
736  static const unsigned int objtriggernames[] = {EVTColContainer::MUON,
751 
752  std::set<unsigned int> objsType;
753  // The object to deal has to be entered via the config .py
754  for (unsigned int i = 0; i < objSize; ++i) {
755  // std::cout << "(5) Gonna call with " << objtriggernames[i] << std::endl;
756  std::string objTypeStr = EVTColContainer::getTypeString(objtriggernames[i]);
757  // Check if it is needed this object for this trigger
758  if (!TString(hltPath).Contains(objTypeStr)) {
759  continue;
760  }
761 
762  objsType.insert(objtriggernames[i]);
763  }
764 
765  return std::vector<unsigned int>(objsType.begin(), objsType.end());
766 }

References EVTColContainer::CALOJET, EVTColContainer::CALOMET, EVTColContainer::CALOMHT, EVTColContainer::ELEC, EVTColContainer::GENMET, EVTColContainer::getTypeString(), zMuMuMuonUserData::hltPath, mps_fire::i, EVTColContainer::L1MET, LogDebug, EVTColContainer::MET, EVTColContainer::MUON, EVTColContainer::MUTRK, EVTColContainer::PFJET, EVTColContainer::PFMET, EVTColContainer::PFMHT, EVTColContainer::PFTAU, EVTColContainer::PHOTON, AlCaHLTBitMon_QueryRunRegistry::string, and EVTColContainer::TRACK.

◆ initSelector()

void HLTExoticaSubAnalysis::initSelector ( const unsigned int &  objtype)
private

Initializes the selectors of the objects based on which object it is.

Definition at line 1121 of file HLTExoticaSubAnalysis.cc.

1121  {
1122  LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::initSelector()";
1123 
1124  if (objtype == EVTColContainer::MUON && _recMuonSelector == nullptr) {
1126  } else if (objtype == EVTColContainer::MUTRK && _recMuonTrkSelector == nullptr) {
1128  } else if (objtype == EVTColContainer::TRACK && _recTrackSelector == nullptr) {
1130  } else if (objtype == EVTColContainer::ELEC && _recElecSelector == nullptr) {
1132  } else if (objtype == EVTColContainer::PHOTON && _recPhotonSelector == nullptr) {
1134  } else if (objtype == EVTColContainer::MET && _recMETSelector == nullptr) {
1136  } else if (objtype == EVTColContainer::PFMET && _recPFMETSelector == nullptr) {
1138  } else if (objtype == EVTColContainer::PFMHT && _recPFMHTSelector == nullptr) {
1140  } else if (objtype == EVTColContainer::GENMET && _genMETSelector == nullptr) {
1142  } else if (objtype == EVTColContainer::CALOMET && _recCaloMETSelector == nullptr) {
1144  } else if (objtype == EVTColContainer::CALOMHT && _recCaloMHTSelector == nullptr) {
1146  } else if (objtype == EVTColContainer::L1MET && _l1METSelector == nullptr) {
1148  } else if (objtype == EVTColContainer::PFTAU && _recPFTauSelector == nullptr) {
1150  } else if (objtype == EVTColContainer::PFJET && _recPFJetSelector == nullptr) {
1152  } else if (objtype == EVTColContainer::CALOJET && _recCaloJetSelector == nullptr) {
1154  }
1155  /* else
1156  {
1157  FIXME: ERROR NOT IMPLEMENTED
1158  }*/
1159 }

References _genMETSelector, _l1METSelector, _recCaloJetSelector, _recCaloMETSelector, _recCaloMHTSelector, _recCut, _recElecSelector, _recMETSelector, _recMuonSelector, _recMuonTrkSelector, _recPFJetSelector, _recPFMETSelector, _recPFMHTSelector, _recPFTauSelector, _recPhotonSelector, _recTrackSelector, EVTColContainer::CALOJET, EVTColContainer::CALOMET, EVTColContainer::CALOMHT, EVTColContainer::ELEC, EVTColContainer::GENMET, EVTColContainer::L1MET, LogDebug, EVTColContainer::MET, EVTColContainer::MUON, EVTColContainer::MUTRK, EVTColContainer::PFJET, EVTColContainer::PFMET, EVTColContainer::PFMHT, EVTColContainer::PFTAU, EVTColContainer::PHOTON, and EVTColContainer::TRACK.

Referenced by analyze().

◆ insertCandidates()

void HLTExoticaSubAnalysis::insertCandidates ( const unsigned int &  objtype,
const EVTColContainer col,
std::vector< reco::LeafCandidate > *  matches,
std::map< int, double > &  theSumEt,
std::map< int, std::vector< const reco::Track * >> &  trkObjs 
)
private

This function applies the selectors initialized previously to the objects, and matches the passing objects to HLT objects.

This is a special case. Passing a PFMET* to the constructor of MatchStruct will trigger the usage of the special constructor which also sets the sumEt member.

Definition at line 1162 of file HLTExoticaSubAnalysis.cc.

1166  {
1167  LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::insertCandidates()";
1168 
1169  theSumEt[objType] = -1;
1170 
1171  if (objType == EVTColContainer::MUON) {
1172  for (size_t i = 0; i < cols->muons->size(); i++) {
1173  LogDebug("ExoticaValidation") << "Inserting muon " << i;
1174  if (_recMuonSelector->operator()(cols->muons->at(i))) {
1175  reco::LeafCandidate m(0, cols->muons->at(i).p4(), cols->muons->at(i).vertex(), objType, 0, true);
1176  matches->push_back(m);
1177 
1178  // for making dxy plots
1179  trkObjs[objType].push_back(cols->muons->at(i).bestTrack());
1180  }
1181  }
1182  } else if (objType == EVTColContainer::MUTRK) {
1183  for (size_t i = 0; i < cols->tracks->size(); i++) {
1184  LogDebug("ExoticaValidation") << "Inserting muonTrack " << i;
1185  if (_recMuonTrkSelector->operator()(cols->tracks->at(i))) {
1186  ROOT::Math::LorentzVector<ROOT::Math::PxPyPzE4D<double>> mom4;
1187  ROOT::Math::XYZVector mom3 = cols->tracks->at(i).momentum();
1188  mom4.SetXYZT(mom3.x(), mom3.y(), mom3.z(), mom3.r());
1189  reco::LeafCandidate m(0, mom4, cols->tracks->at(i).vertex(), objType, 0, true);
1190  matches->push_back(m);
1191 
1192  // for making dxy plots
1193  trkObjs[objType].push_back(&cols->tracks->at(i));
1194  }
1195  }
1196  } else if (objType == EVTColContainer::TRACK) {
1197  for (size_t i = 0; i < cols->tracks->size(); i++) {
1198  LogDebug("ExoticaValidation") << "Inserting Track " << i;
1199  if (_recTrackSelector->operator()(cols->tracks->at(i))) {
1200  ROOT::Math::LorentzVector<ROOT::Math::PxPyPzE4D<double>> mom4;
1201  ROOT::Math::XYZVector mom3 = cols->tracks->at(i).momentum();
1202  mom4.SetXYZT(mom3.x(), mom3.y(), mom3.z(), mom3.r());
1203  reco::LeafCandidate m(0, mom4, cols->tracks->at(i).vertex(), objType, 0, true);
1204  matches->push_back(m);
1205  }
1206  }
1207  } else if (objType == EVTColContainer::ELEC) {
1208  for (size_t i = 0; i < cols->electrons->size(); i++) {
1209  LogDebug("ExoticaValidation") << "Inserting electron " << i;
1210  if (_recElecSelector->operator()(cols->electrons->at(i))) {
1211  reco::LeafCandidate m(0, cols->electrons->at(i).p4(), cols->electrons->at(i).vertex(), objType, 0, true);
1212  matches->push_back(m);
1213 
1214  // for making dxy plots
1215  trkObjs[objType].push_back(cols->electrons->at(i).bestTrack());
1216  }
1217  }
1218  } else if (objType == EVTColContainer::PHOTON) {
1219  for (size_t i = 0; i < cols->photons->size(); i++) {
1220  LogDebug("ExoticaValidation") << "Inserting photon " << i;
1221  if (_recPhotonSelector->operator()(cols->photons->at(i))) {
1222  reco::LeafCandidate m(0, cols->photons->at(i).p4(), cols->photons->at(i).vertex(), objType, 0, true);
1223  matches->push_back(m);
1224  }
1225  }
1226  } else if (objType == EVTColContainer::PFMET) {
1230  for (size_t i = 0; i < cols->pfMETs->size(); i++) {
1231  LogDebug("ExoticaValidation") << "Inserting PFMET " << i;
1232  if (_recPFMETSelector->operator()(cols->pfMETs->at(i))) {
1233  reco::LeafCandidate m(0, cols->pfMETs->at(i).p4(), cols->pfMETs->at(i).vertex(), objType, 0, true);
1234  matches->push_back(m);
1235  if (i == 0)
1236  theSumEt[objType] = cols->pfMETs->at(i).sumEt();
1237  }
1238  }
1239  } else if (objType == EVTColContainer::PFMHT) {
1240  for (size_t i = 0; i < cols->pfMHTs->size(); i++) {
1241  LogDebug("ExoticaValidation") << "Inserting PFMHT " << i;
1242  if (_recPFMHTSelector->operator()(cols->pfMHTs->at(i))) {
1243  reco::LeafCandidate m(0, cols->pfMHTs->at(i).p4(), cols->pfMHTs->at(i).vertex(), objType, 0, true);
1244  matches->push_back(m);
1245  if (i == 0)
1246  theSumEt[objType] = cols->pfMHTs->at(i).sumEt();
1247  }
1248  }
1249  } else if (objType == EVTColContainer::GENMET) {
1250  for (size_t i = 0; i < cols->genMETs->size(); i++) {
1251  LogDebug("ExoticaValidation") << "Inserting GENMET " << i;
1252  if (_genMETSelector->operator()(cols->genMETs->at(i))) {
1253  reco::LeafCandidate m(0, cols->genMETs->at(i).p4(), cols->genMETs->at(i).vertex(), objType, 0, true);
1254  matches->push_back(m);
1255  if (i == 0)
1256  theSumEt[objType] = cols->genMETs->at(i).sumEt();
1257  }
1258  }
1259  } else if (objType == EVTColContainer::CALOMET) {
1260  for (size_t i = 0; i < cols->caloMETs->size(); i++) {
1261  LogDebug("ExoticaValidation") << "Inserting CALOMET " << i;
1262  if (_recCaloMETSelector->operator()(cols->caloMETs->at(i))) {
1263  reco::LeafCandidate m(0, cols->caloMETs->at(i).p4(), cols->caloMETs->at(i).vertex(), objType, 0, true);
1264  matches->push_back(m);
1265  if (i == 0)
1266  theSumEt[objType] = cols->caloMETs->at(i).sumEt();
1267  }
1268  }
1269  } else if (objType == EVTColContainer::CALOMHT) {
1270  for (size_t i = 0; i < cols->caloMHTs->size(); i++) {
1271  LogDebug("ExoticaValidation") << "Inserting CaloMHT " << i;
1272  if (_recCaloMHTSelector->operator()(cols->caloMHTs->at(i))) {
1273  reco::LeafCandidate m(0, cols->caloMHTs->at(i).p4(), cols->caloMHTs->at(i).vertex(), objType, 0, true);
1274  matches->push_back(m);
1275  if (i == 0)
1276  theSumEt[objType] = cols->caloMHTs->at(i).sumEt();
1277  }
1278  }
1279  } else if (objType == EVTColContainer::L1MET) {
1280  for (size_t i = 0; i < cols->l1METs->size(); i++) {
1281  LogDebug("ExoticaValidation") << "Inserting L1MET " << i;
1282  if (_l1METSelector->operator()(cols->l1METs->at(i))) {
1283  reco::LeafCandidate m(0, cols->l1METs->at(i).p4(), cols->l1METs->at(i).vertex(), objType, 0, true);
1284  matches->push_back(m);
1285  if (i == 0)
1286  theSumEt[objType] = cols->l1METs->at(i).etTotal();
1287  }
1288  }
1289  } else if (objType == EVTColContainer::PFTAU) {
1290  for (size_t i = 0; i < cols->pfTaus->size(); i++) {
1291  LogDebug("ExoticaValidation") << "Inserting PFtau " << i;
1292  if (_recPFTauSelector->operator()(cols->pfTaus->at(i))) {
1293  reco::LeafCandidate m(0, cols->pfTaus->at(i).p4(), cols->pfTaus->at(i).vertex(), objType, 0, true);
1294  matches->push_back(m);
1295  }
1296  }
1297  } else if (objType == EVTColContainer::PFJET) {
1298  for (size_t i = 0; i < cols->pfJets->size(); i++) {
1299  LogDebug("ExoticaValidation") << "Inserting jet " << i;
1300  if (_recPFJetSelector->operator()(cols->pfJets->at(i))) {
1301  reco::LeafCandidate m(0, cols->pfJets->at(i).p4(), cols->pfJets->at(i).vertex(), objType, 0, true);
1302  matches->push_back(m);
1303  }
1304  }
1305  } else if (objType == EVTColContainer::CALOJET) {
1306  for (size_t i = 0; i < cols->caloJets->size(); i++) {
1307  LogDebug("ExoticaValidation") << "Inserting jet " << i;
1308  if (_recCaloJetSelector->operator()(cols->caloJets->at(i))) {
1309  reco::LeafCandidate m(0, cols->caloJets->at(i).p4(), cols->caloJets->at(i).vertex(), objType, 0, true);
1310  matches->push_back(m);
1311  }
1312  }
1313  }
1314 
1315  /* else
1316  {
1317  FIXME: ERROR NOT IMPLEMENTED
1318  }*/
1319 }

References _genMETSelector, _l1METSelector, _recCaloJetSelector, _recCaloMETSelector, _recCaloMHTSelector, _recElecSelector, _recMuonSelector, _recMuonTrkSelector, _recPFJetSelector, _recPFMETSelector, _recPFMHTSelector, _recPFTauSelector, _recPhotonSelector, _recTrackSelector, EVTColContainer::CALOJET, EVTColContainer::caloJets, EVTColContainer::CALOMET, EVTColContainer::caloMETs, EVTColContainer::CALOMHT, EVTColContainer::caloMHTs, EVTColContainer::ELEC, EVTColContainer::electrons, EVTColContainer::GENMET, EVTColContainer::genMETs, mps_fire::i, EVTColContainer::L1MET, EVTColContainer::l1METs, LogDebug, visualization-live-secondInstance_cfg::m, patCandidatesForDimuonsSequences_cff::matches, EVTColContainer::MUON, EVTColContainer::muons, EVTColContainer::MUTRK, electrons_cff::objType, EVTColContainer::PFJET, EVTColContainer::pfJets, EVTColContainer::PFMET, EVTColContainer::pfMETs, EVTColContainer::PFMHT, EVTColContainer::pfMHTs, EVTColContainer::PFTAU, EVTColContainer::pfTaus, EVTColContainer::PHOTON, EVTColContainer::photons, EVTColContainer::TRACK, and EVTColContainer::tracks.

Referenced by analyze().

◆ registerConsumes()

void HLTExoticaSubAnalysis::registerConsumes ( edm::ConsumesCollector consCollector)
private

Registers consumption of objects.

Definition at line 847 of file HLTExoticaSubAnalysis.cc.

847  {
848  // Register that we are getting genParticles
850 
851  // Register that we are getting the trigger results
853 
854  // Register beamspot
855  _bsToken = iC.consumes<reco::BeamSpot>(_beamSpotLabel);
856 
857  // Loop over _recLabels, see what we need, and register.
858  // Then save the registered token in _tokens.
859  // Remember: _recLabels is a map<uint, edm::InputTag>
860  // Remember: _tokens is a map<uint, edm::EDGetToken>
861  LogDebug("ExoticaValidation") << "We have got " << _recLabels.size() << "recLabels";
862  for (std::map<unsigned int, edm::InputTag>::iterator it = _recLabels.begin(); it != _recLabels.end(); ++it) {
863  if (it->first == EVTColContainer::MUON) {
864  edm::EDGetTokenT<reco::MuonCollection> particularToken = iC.consumes<reco::MuonCollection>(it->second);
865  edm::EDGetToken token(particularToken);
866  _tokens[it->first] = token;
867  } else if (it->first == EVTColContainer::MUTRK) {
868  edm::EDGetTokenT<reco::TrackCollection> particularToken = iC.consumes<reco::TrackCollection>(it->second);
869  edm::EDGetToken token(particularToken);
870  _tokens[it->first] = token;
871  } else if (it->first == EVTColContainer::TRACK) {
872  edm::EDGetTokenT<reco::TrackCollection> particularToken = iC.consumes<reco::TrackCollection>(it->second);
873  edm::EDGetToken token(particularToken);
874  _tokens[it->first] = token;
875  } else if (it->first == EVTColContainer::ELEC) {
877  iC.consumes<reco::GsfElectronCollection>(it->second);
878  edm::EDGetToken token(particularToken);
879  _tokens[it->first] = token;
880  } else if (it->first == EVTColContainer::PHOTON) {
881  edm::EDGetTokenT<reco::PhotonCollection> particularToken = iC.consumes<reco::PhotonCollection>(it->second);
882  edm::EDGetToken token(particularToken);
883  _tokens[it->first] = token;
884  } else if (it->first == EVTColContainer::MET) {
885  edm::EDGetTokenT<reco::METCollection> particularToken = iC.consumes<reco::METCollection>(it->second);
886  edm::EDGetToken token(particularToken);
887  _tokens[it->first] = token;
888  } else if (it->first == EVTColContainer::PFMET) {
889  edm::EDGetTokenT<reco::PFMETCollection> particularToken = iC.consumes<reco::PFMETCollection>(it->second);
890  edm::EDGetToken token(particularToken);
891  _tokens[it->first] = token;
892  } else if (it->first == EVTColContainer::PFMHT) {
893  edm::EDGetTokenT<reco::PFMETCollection> particularToken = iC.consumes<reco::PFMETCollection>(it->second);
894  edm::EDGetToken token(particularToken);
895  _tokens[it->first] = token;
896  } else if (it->first == EVTColContainer::GENMET) {
897  edm::EDGetTokenT<reco::GenMETCollection> particularToken = iC.consumes<reco::GenMETCollection>(it->second);
898  edm::EDGetToken token(particularToken);
899  _tokens[it->first] = token;
900  } else if (it->first == EVTColContainer::CALOMET) {
901  edm::EDGetTokenT<reco::CaloMETCollection> particularToken = iC.consumes<reco::CaloMETCollection>(it->second);
902  edm::EDGetToken token(particularToken);
903  _tokens[it->first] = token;
904  } else if (it->first == EVTColContainer::CALOMHT) {
905  edm::EDGetTokenT<reco::CaloMETCollection> particularToken = iC.consumes<reco::CaloMETCollection>(it->second);
906  edm::EDGetToken token(particularToken);
907  _tokens[it->first] = token;
908  } else if (it->first == EVTColContainer::L1MET) {
910  iC.consumes<l1extra::L1EtMissParticleCollection>(it->second);
911  edm::EDGetToken token(particularToken);
912  _tokens[it->first] = token;
913  } else if (it->first == EVTColContainer::PFTAU) {
914  edm::EDGetTokenT<reco::PFTauCollection> particularToken = iC.consumes<reco::PFTauCollection>(it->second);
915  edm::EDGetToken token(particularToken);
916  _tokens[it->first] = token;
917  } else if (it->first == EVTColContainer::PFJET) {
918  edm::EDGetTokenT<reco::PFJetCollection> particularToken = iC.consumes<reco::PFJetCollection>(it->second);
919  edm::EDGetToken token(particularToken);
920  _tokens[it->first] = token;
921  } else if (it->first == EVTColContainer::CALOJET) {
922  edm::EDGetTokenT<reco::CaloJetCollection> particularToken = iC.consumes<reco::CaloJetCollection>(it->second);
923  edm::EDGetToken token(particularToken);
924  _tokens[it->first] = token;
925  } else {
926  edm::LogError("ExoticaValidation") << "HLTExoticaSubAnalysis::registerConsumes"
927  << " NOT IMPLEMENTED (yet) ERROR: '" << it->second.label() << "'";
928  }
929  }
930 }

References _beamSpotLabel, _bsToken, _genParticleLabel, _genParticleToken, _recLabels, _tokens, _trigResultsLabel, _trigResultsToken, EVTColContainer::CALOJET, EVTColContainer::CALOMET, EVTColContainer::CALOMHT, edm::ConsumesCollector::consumes(), EVTColContainer::ELEC, EVTColContainer::GENMET, EVTColContainer::L1MET, LogDebug, EVTColContainer::MET, EVTColContainer::MUON, EVTColContainer::MUTRK, EVTColContainer::PFJET, EVTColContainer::PFMET, EVTColContainer::PFMHT, EVTColContainer::PFTAU, EVTColContainer::PHOTON, unpackBuffers-CaloStage2::token, and EVTColContainer::TRACK.

Referenced by HLTExoticaSubAnalysis().

◆ subAnalysisBookHistos()

void HLTExoticaSubAnalysis::subAnalysisBookHistos ( DQMStore::IBooker iBooker,
const edm::Run iRun,
const edm::EventSetup iSetup 
)

Method to book all relevant histograms in the DQMStore. Uses the IBooker interface for thread safety. Intended to be called from master object.

Definition at line 195 of file HLTExoticaSubAnalysis.cc.

197  {
198  LogDebug("ExoticaValidation") << "In HLTExoticaSubAnalysis::subAnalysisBookHistos()";
199 
200  // Create the folder structure inside HLT/Exotica
201  std::string baseDir = "HLT/Exotica/" + _analysisname + "/";
202  iBooker.setCurrentFolder(baseDir);
203 
204  // Book the gen/reco analysis-dependent histograms (denominators)
205  for (std::map<unsigned int, edm::InputTag>::const_iterator it = _recLabels.begin(); it != _recLabels.end(); ++it) {
206  const std::string objStr = EVTColContainer::getTypeString(it->first);
207  std::vector<std::string> sources(2);
208  sources[0] = "gen";
209  sources[1] = "rec";
210 
211  for (size_t i = 0; i < sources.size(); i++) {
213 
214  if (source == "gen") {
215  if (TString(objStr).Contains("MET") || TString(objStr).Contains("MHT") || TString(objStr).Contains("Jet")) {
216  continue;
217  } else {
218  bookHist(iBooker, source, objStr, "MaxPt1");
219  if (!_drop_pt2)
220  bookHist(iBooker, source, objStr, "MaxPt2");
221  if (!_drop_pt3)
222  bookHist(iBooker, source, objStr, "MaxPt3");
223  bookHist(iBooker, source, objStr, "Eta");
224  bookHist(iBooker, source, objStr, "Phi");
225 
226  // If the target is electron or muon,
227  // we will add Dxy plots.
228  if (it->first == EVTColContainer::ELEC || it->first == EVTColContainer::MUON ||
229  it->first == EVTColContainer::MUTRK) {
230  bookHist(iBooker, source, objStr, "Dxy");
231  }
232  }
233  } else { // reco
234  if (TString(objStr).Contains("MET") || TString(objStr).Contains("MHT")) {
235  bookHist(iBooker, source, objStr, "MaxPt1");
236  bookHist(iBooker, source, objStr, "SumEt");
237  } else {
238  bookHist(iBooker, source, objStr, "MaxPt1");
239  if (!_drop_pt2)
240  bookHist(iBooker, source, objStr, "MaxPt2");
241  if (!_drop_pt3)
242  bookHist(iBooker, source, objStr, "MaxPt3");
243  bookHist(iBooker, source, objStr, "Eta");
244  bookHist(iBooker, source, objStr, "Phi");
245 
246  // If the target is electron or muon,
247  // we will add Dxy plots.
248  if (it->first == EVTColContainer::ELEC || it->first == EVTColContainer::MUON ||
249  it->first == EVTColContainer::MUTRK) {
250  bookHist(iBooker, source, objStr, "Dxy");
251  }
252  }
253  }
254  }
255  } // closes loop in _recLabels
256 
257  // Call the plotterBookHistos() (which books all the path dependent
258  // histograms)
259  LogDebug("ExoticaValidation") << " number of plotters = " << _plotters.size();
260  for (std::vector<HLTExoticaPlotter>::iterator it = _plotters.begin(); it != _plotters.end(); ++it) {
261  it->plotterBookHistos(iBooker, iRun, iSetup);
262  }
263 }

References _analysisname, _drop_pt2, _drop_pt3, _plotters, _recLabels, ALCARECODTCalibSynchDQM_cff::baseDir, bookHist(), EVTColContainer::ELEC, EVTColContainer::getTypeString(), mps_fire::i, LogDebug, EVTColContainer::MUON, EVTColContainer::MUTRK, dqm::implementation::NavigatorBase::setCurrentFolder(), source, CalibrationSummaryClient_cfi::sources, and AlCaHLTBitMon_QueryRunRegistry::string.

Member Data Documentation

◆ _analysisname

std::string HLTExoticaSubAnalysis::_analysisname
private

The name of this sub-analysis.

Definition at line 125 of file HLTExoticaSubAnalysis.h.

Referenced by beginRun(), endRun(), getNamesOfObjects(), and subAnalysisBookHistos().

◆ _beamSpotLabel

edm::InputTag HLTExoticaSubAnalysis::_beamSpotLabel
private

Definition at line 141 of file HLTExoticaSubAnalysis.h.

Referenced by registerConsumes().

◆ _bsToken

edm::EDGetTokenT<reco::BeamSpot> HLTExoticaSubAnalysis::_bsToken
private

Definition at line 146 of file HLTExoticaSubAnalysis.h.

Referenced by getHandlesToObjects(), and registerConsumes().

◆ _drop_pt2

bool HLTExoticaSubAnalysis::_drop_pt2
private

Definition at line 157 of file HLTExoticaSubAnalysis.h.

Referenced by analyze(), HLTExoticaSubAnalysis(), and subAnalysisBookHistos().

◆ _drop_pt3

bool HLTExoticaSubAnalysis::_drop_pt3
private

Definition at line 158 of file HLTExoticaSubAnalysis.h.

Referenced by analyze(), HLTExoticaSubAnalysis(), and subAnalysisBookHistos().

◆ _elements

std::map<std::string, MonitorElement *> HLTExoticaSubAnalysis::_elements
private

Structure of the MonitorElements.

Definition at line 196 of file HLTExoticaSubAnalysis.h.

Referenced by bookHist(), and fillHist().

◆ _genCut

std::map<unsigned int, std::string> HLTExoticaSubAnalysis::_genCut
private

gen/rec objects cuts

Definition at line 161 of file HLTExoticaSubAnalysis.h.

Referenced by analyze(), and HLTExoticaSubAnalysis().

◆ _genCut_leading

std::map<unsigned int, std::string> HLTExoticaSubAnalysis::_genCut_leading
private

gen/rec pt-leading objects cuts

Definition at line 164 of file HLTExoticaSubAnalysis.h.

Referenced by analyze(), and HLTExoticaSubAnalysis().

◆ _genMETSelector

StringCutObjectSelector<reco::GenMET>* HLTExoticaSubAnalysis::_genMETSelector
private

Definition at line 177 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _genParticleLabel

edm::InputTag HLTExoticaSubAnalysis::_genParticleLabel
private

Definition at line 139 of file HLTExoticaSubAnalysis.h.

Referenced by registerConsumes().

◆ _genParticleToken

edm::EDGetTokenT<reco::GenParticleCollection> HLTExoticaSubAnalysis::_genParticleToken
private

And also the tokens to get the object collections.

Definition at line 144 of file HLTExoticaSubAnalysis.h.

Referenced by getHandlesToObjects(), and registerConsumes().

◆ _genSelectorMap

std::map<unsigned int, StringCutObjectSelector<reco::GenParticle> *> HLTExoticaSubAnalysis::_genSelectorMap
private

The concrete String selectors (use the string cuts introduced via the config python)

Definition at line 169 of file HLTExoticaSubAnalysis.h.

Referenced by analyze(), getNamesOfObjects(), and ~HLTExoticaSubAnalysis().

◆ _hltConfig

HLTConfigProvider HLTExoticaSubAnalysis::_hltConfig
private

Interface to the HLT information.

Definition at line 193 of file HLTExoticaSubAnalysis.h.

Referenced by beginRun().

◆ _hltPaths

std::set<std::string> HLTExoticaSubAnalysis::_hltPaths
private

The hlt paths found in the hltConfig.

Definition at line 133 of file HLTExoticaSubAnalysis.h.

Referenced by beginRun().

◆ _hltPathsToCheck

std::vector<std::string> HLTExoticaSubAnalysis::_hltPathsToCheck
private

The hlt paths to check for.

Definition at line 131 of file HLTExoticaSubAnalysis.h.

Referenced by beginRun(), and HLTExoticaSubAnalysis().

◆ _hltProcessName

std::string HLTExoticaSubAnalysis::_hltProcessName
private

The labels of the object collections to be used in this analysis.

Definition at line 138 of file HLTExoticaSubAnalysis.h.

Referenced by beginRun().

◆ _l1METSelector

StringCutObjectSelector<l1extra::L1EtMissParticle>* HLTExoticaSubAnalysis::_l1METSelector
private

Definition at line 180 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _minCandidates

unsigned int HLTExoticaSubAnalysis::_minCandidates
private

The minimum number of reco/gen candidates needed by the analysis.

Definition at line 128 of file HLTExoticaSubAnalysis.h.

Referenced by analyze(), and HLTExoticaSubAnalysis().

◆ _parametersDxy

std::vector<double> HLTExoticaSubAnalysis::_parametersDxy
private

Definition at line 154 of file HLTExoticaSubAnalysis.h.

Referenced by bookHist(), and HLTExoticaSubAnalysis().

◆ _parametersEta

std::vector<double> HLTExoticaSubAnalysis::_parametersEta
private

Some kinematical parameters.

Definition at line 150 of file HLTExoticaSubAnalysis.h.

Referenced by bookHist(), and HLTExoticaSubAnalysis().

◆ _parametersPhi

std::vector<double> HLTExoticaSubAnalysis::_parametersPhi
private

Definition at line 151 of file HLTExoticaSubAnalysis.h.

Referenced by bookHist(), and HLTExoticaSubAnalysis().

◆ _parametersTurnOn

std::vector<double> HLTExoticaSubAnalysis::_parametersTurnOn
private

Definition at line 152 of file HLTExoticaSubAnalysis.h.

Referenced by bookHist(), and HLTExoticaSubAnalysis().

◆ _parametersTurnOnSumEt

std::vector<double> HLTExoticaSubAnalysis::_parametersTurnOnSumEt
private

Definition at line 153 of file HLTExoticaSubAnalysis.h.

Referenced by bookHist(), and HLTExoticaSubAnalysis().

◆ _plotters

std::vector<HLTExoticaPlotter> HLTExoticaSubAnalysis::_plotters
private

The plotters: managers of each hlt path where the plots are done.

Definition at line 187 of file HLTExoticaSubAnalysis.h.

Referenced by analyze(), beginRun(), and subAnalysisBookHistos().

◆ _pset

edm::ParameterSet HLTExoticaSubAnalysis::_pset
private

Internal, working copy of the PSet passed from above.

Definition at line 122 of file HLTExoticaSubAnalysis.h.

Referenced by beginRun(), and HLTExoticaSubAnalysis().

◆ _recCaloJetSelector

StringCutObjectSelector<reco::CaloJet>* HLTExoticaSubAnalysis::_recCaloJetSelector
private

Definition at line 184 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _recCaloMETSelector

StringCutObjectSelector<reco::CaloMET>* HLTExoticaSubAnalysis::_recCaloMETSelector
private

Definition at line 178 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _recCaloMHTSelector

StringCutObjectSelector<reco::CaloMET>* HLTExoticaSubAnalysis::_recCaloMHTSelector
private

Definition at line 179 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _recCut

std::map<unsigned int, std::string> HLTExoticaSubAnalysis::_recCut
private

Definition at line 162 of file HLTExoticaSubAnalysis.h.

Referenced by HLTExoticaSubAnalysis(), and initSelector().

◆ _recCut_leading

std::map<unsigned int, std::string> HLTExoticaSubAnalysis::_recCut_leading
private

Definition at line 165 of file HLTExoticaSubAnalysis.h.

Referenced by analyze(), and HLTExoticaSubAnalysis().

◆ _recElecSelector

StringCutObjectSelector<reco::GsfElectron>* HLTExoticaSubAnalysis::_recElecSelector
private

Definition at line 173 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _recLabels

std::map<unsigned int, edm::InputTag> HLTExoticaSubAnalysis::_recLabels
private

◆ _recMETSelector

StringCutObjectSelector<reco::MET>* HLTExoticaSubAnalysis::_recMETSelector
private

Definition at line 174 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), and ~HLTExoticaSubAnalysis().

◆ _recMuonSelector

StringCutObjectSelector<reco::Muon>* HLTExoticaSubAnalysis::_recMuonSelector
private

Definition at line 170 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _recMuonTrkSelector

StringCutObjectSelector<reco::Track>* HLTExoticaSubAnalysis::_recMuonTrkSelector
private

Definition at line 171 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _recPFJetSelector

StringCutObjectSelector<reco::PFJet>* HLTExoticaSubAnalysis::_recPFJetSelector
private

Definition at line 183 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _recPFMETSelector

StringCutObjectSelector<reco::PFMET>* HLTExoticaSubAnalysis::_recPFMETSelector
private

Definition at line 175 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _recPFMHTSelector

StringCutObjectSelector<reco::PFMET>* HLTExoticaSubAnalysis::_recPFMHTSelector
private

Definition at line 176 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _recPFTauSelector

StringCutObjectSelector<reco::PFTau>* HLTExoticaSubAnalysis::_recPFTauSelector
private

Definition at line 181 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _recPhotonSelector

StringCutObjectSelector<reco::Photon>* HLTExoticaSubAnalysis::_recPhotonSelector
private

Definition at line 182 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _recTrackSelector

StringCutObjectSelector<reco::Track>* HLTExoticaSubAnalysis::_recTrackSelector
private

Definition at line 172 of file HLTExoticaSubAnalysis.h.

Referenced by initSelector(), insertCandidates(), and ~HLTExoticaSubAnalysis().

◆ _shortpath2long

std::map<std::string, std::string> HLTExoticaSubAnalysis::_shortpath2long
private

Relation between the short and long versions of the path.

Definition at line 135 of file HLTExoticaSubAnalysis.h.

Referenced by analyze(), and beginRun().

◆ _tokens

std::map<unsigned int, edm::EDGetToken> HLTExoticaSubAnalysis::_tokens
private

Definition at line 147 of file HLTExoticaSubAnalysis.h.

Referenced by getHandlesToObjects(), and registerConsumes().

◆ _triggerCounter

std::map<std::string, int> HLTExoticaSubAnalysis::_triggerCounter
private

counting HLT passed events

Definition at line 190 of file HLTExoticaSubAnalysis.h.

Referenced by analyze(), beginRun(), and endRun().

◆ _trigResultsLabel

edm::InputTag HLTExoticaSubAnalysis::_trigResultsLabel
private

Definition at line 140 of file HLTExoticaSubAnalysis.h.

Referenced by registerConsumes().

◆ _trigResultsToken

edm::EDGetTokenT<edm::TriggerResults> HLTExoticaSubAnalysis::_trigResultsToken
private

Definition at line 145 of file HLTExoticaSubAnalysis.h.

Referenced by getHandlesToObjects(), and registerConsumes().

HLTExoticaSubAnalysis::_recCut_leading
std::map< unsigned int, std::string > _recCut_leading
Definition: HLTExoticaSubAnalysis.h:165
EVTColContainer::getTypeString
const static std::string getTypeString(const unsigned int &objtype)
Tranform types into strings.
Definition: EVTColContainer.cc:231
HLTExoticaSubAnalysis::_recCut
std::map< unsigned int, std::string > _recCut
Definition: HLTExoticaSubAnalysis.h:162
reco::PFMETCollection
std::vector< reco::PFMET > PFMETCollection
collection of PFMET objects
Definition: PFMETCollection.h:20
HLTExoticaSubAnalysis::_genParticleToken
edm::EDGetTokenT< reco::GenParticleCollection > _genParticleToken
And also the tokens to get the object collections.
Definition: HLTExoticaSubAnalysis.h:144
HLTExoticaSubAnalysis::_recCaloMETSelector
StringCutObjectSelector< reco::CaloMET > * _recCaloMETSelector
Definition: HLTExoticaSubAnalysis.h:178
runGCPTkAlMap.title
string title
Definition: runGCPTkAlMap.py:94
HLTExoticaSubAnalysis::_hltProcessName
std::string _hltProcessName
The labels of the object collections to be used in this analysis.
Definition: HLTExoticaSubAnalysis.h:138
mps_fire.i
i
Definition: mps_fire.py:428
edm::ParameterSet::retrieve
Entry const & retrieve(char const *) const
Definition: ParameterSet.cc:226
HLTExoticaSubAnalysis::initSelector
void initSelector(const unsigned int &objtype)
Initializes the selectors of the objects based on which object it is.
Definition: HLTExoticaSubAnalysis.cc:1121
edm::Handle::product
T const * product() const
Definition: Handle.h:70
HLTExoticaSubAnalysis::_hltPathsToCheck
std::vector< std::string > _hltPathsToCheck
The hlt paths to check for.
Definition: HLTExoticaSubAnalysis.h:131
trigNames
static const char *const trigNames[]
Definition: EcalDumpRaw.cc:57
HLTExoticaSubAnalysis::_parametersTurnOnSumEt
std::vector< double > _parametersTurnOnSumEt
Definition: HLTExoticaSubAnalysis.h:153
HLTExoticaSubAnalysis::_trigResultsToken
edm::EDGetTokenT< edm::TriggerResults > _trigResultsToken
Definition: HLTExoticaSubAnalysis.h:145
HLTExoticaSubAnalysis::_genCut_leading
std::map< unsigned int, std::string > _genCut_leading
gen/rec pt-leading objects cuts
Definition: HLTExoticaSubAnalysis.h:164
DiDispStaMuonMonitor_cfi.pt
pt
Definition: DiDispStaMuonMonitor_cfi.py:39
CalibrationSummaryClient_cfi.params
params
Definition: CalibrationSummaryClient_cfi.py:14
min
T min(T a, T b)
Definition: MathUtil.h:58
edm::EDGetTokenT< reco::MuonCollection >
h
FWCore Framework interface EventSetupRecordImplementation h
Helper function to determine trigger accepts.
Definition: L1TUtmAlgorithmRcd.h:4
cuy.col
col
Definition: cuy.py:1010
singleTopDQM_cfi.select
select
Definition: singleTopDQM_cfi.py:50
HLTExoticaSubAnalysis::_parametersDxy
std::vector< double > _parametersDxy
Definition: HLTExoticaSubAnalysis.h:154
reco::GenParticleCollection
std::vector< GenParticle > GenParticleCollection
collection of GenParticles
Definition: GenParticleFwd.h:13
EVTColContainer::MET
Definition: EVTColContainer.cc:55
dqm::implementation::NavigatorBase::setCurrentFolder
virtual void setCurrentFolder(std::string const &fullpath)
Definition: DQMStore.cc:32
HLTExoticaSubAnalysis::_recMuonTrkSelector
StringCutObjectSelector< reco::Track > * _recMuonTrkSelector
Definition: HLTExoticaSubAnalysis.h:171
edm::second
U second(std::pair< T, U > const &p)
Definition: ParameterSet.cc:222
EVTColContainer::PFJET
Definition: EVTColContainer.cc:60
CalibrationSummaryClient_cfi.sources
sources
Definition: CalibrationSummaryClient_cfi.py:23
HLTExoticaSubAnalysis::insertCandidates
void insertCandidates(const unsigned int &objtype, const EVTColContainer *col, std::vector< reco::LeafCandidate > *matches, std::map< int, double > &theSumEt, std::map< int, std::vector< const reco::Track * >> &trkObjs)
Definition: HLTExoticaSubAnalysis.cc:1162
EVTColContainer::PFMET
Definition: EVTColContainer.cc:53
ALCARECODTCalibSynchDQM_cff.baseDir
baseDir
Definition: ALCARECODTCalibSynchDQM_cff.py:14
reco::GsfElectronCollection
std::vector< GsfElectron > GsfElectronCollection
collection of GsfElectron objects
Definition: GsfElectronFwd.h:14
HLTExoticaSubAnalysis::_l1METSelector
StringCutObjectSelector< l1extra::L1EtMissParticle > * _l1METSelector
Definition: HLTExoticaSubAnalysis.h:180
edm::ParameterSet::getUntrackedParameter
T getUntrackedParameter(std::string const &, T const &) const
edm::ParameterSet::existsAs
bool existsAs(std::string const &parameterName, bool trackiness=true) const
checks if a parameter exists as a given type
Definition: ParameterSet.h:171
findQualityFiles.v
v
Definition: findQualityFiles.py:179
EVTColContainer::bs
const reco::BeamSpot * bs
Definition: EVTColContainer.cc:85
EVTColContainer::CALOMET
Definition: EVTColContainer.cc:57
ramdisk_dqm_sourceclient-live_cfg.analyzer
analyzer
Definition: ramdisk_dqm_sourceclient-live_cfg.py:22
newFWLiteAna.found
found
Definition: newFWLiteAna.py:118
edm::Handle< edm::TriggerResults >
HLTExoticaSubAnalysis::_genCut
std::map< unsigned int, std::string > _genCut
gen/rec objects cuts
Definition: HLTExoticaSubAnalysis.h:161
edm::LogWarning
Log< level::Warning, false > LogWarning
Definition: MessageLogger.h:122
HLTExoticaSubAnalysis::_drop_pt2
bool _drop_pt2
Definition: HLTExoticaSubAnalysis.h:157
funct::sin
Sin< T >::type sin(const T &t)
Definition: Sin.h:22
HLTExoticaSubAnalysis::_recElecSelector
StringCutObjectSelector< reco::GsfElectron > * _recElecSelector
Definition: HLTExoticaSubAnalysis.h:173
reco::METCollection
std::vector< reco::MET > METCollection
collection of MET objects
Definition: METCollection.h:22
EVTColContainer::TRACK
Definition: EVTColContainer.cc:52
EVTColContainer::triggerResults
const edm::TriggerResults * triggerResults
Definition: EVTColContainer.cc:84
EVTColContainer::CALOMHT
Definition: EVTColContainer.cc:62
funct::cos
Cos< T >::type cos(const T &t)
Definition: Cos.h:22
reco::GenMETCollection
std::vector< reco::GenMET > GenMETCollection
collection of GenMET objects
Definition: GenMETCollection.h:20
HLTExoticaSubAnalysis::_shortpath2long
std::map< std::string, std::string > _shortpath2long
Relation between the short and long versions of the path.
Definition: HLTExoticaSubAnalysis.h:135
HLTExoticaSubAnalysis::_recPFMHTSelector
StringCutObjectSelector< reco::PFMET > * _recPFMHTSelector
Definition: HLTExoticaSubAnalysis.h:176
HLTExoticaSubAnalysis::_parametersTurnOn
std::vector< double > _parametersTurnOn
Definition: HLTExoticaSubAnalysis.h:152
edm::ParameterSet::insert
void insert(bool ok_to_replace, char const *, Entry const &)
Definition: ParameterSet.cc:380
PVValHelper::eta
Definition: PVValidationHelpers.h:69
visualization-live-secondInstance_cfg.m
m
Definition: visualization-live-secondInstance_cfg.py:72
reco::MuonCollection
std::vector< Muon > MuonCollection
collection of Muon objects
Definition: MuonFwd.h:9
HLTExoticaSubAnalysis::_elements
std::map< std::string, MonitorElement * > _elements
Structure of the MonitorElements.
Definition: HLTExoticaSubAnalysis.h:196
reco::BeamSpot
Definition: BeamSpot.h:21
reco::PFTauCollection
std::vector< PFTau > PFTauCollection
collection of PFTau objects
Definition: PFTauFwd.h:9
source
static const std::string source
Definition: EdmProvDump.cc:47
HLTExoticaSubAnalysis::getHandlesToObjects
void getHandlesToObjects(const edm::Event &iEvent, EVTColContainer *col)
Gets the collections themselves.
Definition: HLTExoticaSubAnalysis.cc:933
verbose
static constexpr int verbose
Definition: HLTExoticaSubAnalysis.cc:25
HLTExoticaSubAnalysis::fillHist
void fillHist(const std::string &source, const std::string &objType, const std::string &variable, const float &value)
Definition: HLTExoticaSubAnalysis.cc:1107
EVTColContainer::genParticles
const reco::GenParticleCollection * genParticles
Definition: EVTColContainer.cc:69
seedmultiplicitymonitor_newtracking_cfi.nBins
nBins
Definition: seedmultiplicitymonitor_newtracking_cfi.py:8
h
EVTColContainer::MUON
Definition: EVTColContainer.cc:49
reco::BeamSpot::position
const Point & position() const
position
Definition: BeamSpot.h:59
HLTExoticaSubAnalysis::_recPhotonSelector
StringCutObjectSelector< reco::Photon > * _recPhotonSelector
Definition: HLTExoticaSubAnalysis.h:182
HLTExoticaSubAnalysis::_bsToken
edm::EDGetTokenT< reco::BeamSpot > _bsToken
Definition: HLTExoticaSubAnalysis.h:146
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
EVTColContainer::PFTAU
Definition: EVTColContainer.cc:51
HLTExoticaSubAnalysis::_hltConfig
HLTConfigProvider _hltConfig
Interface to the HLT information.
Definition: HLTExoticaSubAnalysis.h:193
HLTExoticaSubAnalysis::_tokens
std::map< unsigned int, edm::EDGetToken > _tokens
Definition: HLTExoticaSubAnalysis.h:147
edm::ParameterSet::exists
bool exists(std::string const &parameterName) const
checks if a parameter exists
Definition: ParameterSet.cc:681
EVTColContainer::CALOJET
Definition: EVTColContainer.cc:61
HLTExoticaSubAnalysis::_genParticleLabel
edm::InputTag _genParticleLabel
Definition: HLTExoticaSubAnalysis.h:139
electrons_cff.objType
objType
Definition: electrons_cff.py:514
LogDebug
#define LogDebug(id)
Definition: MessageLogger.h:223
edm::ParameterSet
Definition: ParameterSet.h:47
math::XYZPoint
XYZPointD XYZPoint
point in space with cartesian internal representation
Definition: Point3D.h:12
EVTColContainer::GENMET
Definition: EVTColContainer.cc:56
HLTExoticaSubAnalysis::_recPFJetSelector
StringCutObjectSelector< reco::PFJet > * _recPFJetSelector
Definition: HLTExoticaSubAnalysis.h:183
SiStripPI::max
Definition: SiStripPayloadInspectorHelper.h:169
HLTExoticaSubAnalysis::_parametersEta
std::vector< double > _parametersEta
Some kinematical parameters.
Definition: HLTExoticaSubAnalysis.h:150
EVTColContainer::L1MET
Definition: EVTColContainer.cc:59
HLTExoticaSubAnalysis::_triggerCounter
std::map< std::string, int > _triggerCounter
counting HLT passed events
Definition: HLTExoticaSubAnalysis.h:190
cand
Definition: decayParser.h:32
createfilelist.int
int
Definition: createfilelist.py:10
iEvent
int iEvent
Definition: GenABIO.cc:224
HLTExoticaSubAnalysis::_pset
edm::ParameterSet _pset
Internal, working copy of the PSet passed from above.
Definition: HLTExoticaSubAnalysis.h:122
reco::CaloJetCollection
std::vector< CaloJet > CaloJetCollection
collection of CaloJet objects
Definition: CaloJetCollection.h:15
l1extra::L1EtMissParticleCollection
std::vector< L1EtMissParticle > L1EtMissParticleCollection
Definition: L1EtMissParticleFwd.h:32
value
Definition: value.py:1
HLTExoticaSubAnalysis::_analysisname
std::string _analysisname
The name of this sub-analysis.
Definition: HLTExoticaSubAnalysis.h:125
topSingleLeptonDQM_PU_cfi.pattern
pattern
Definition: topSingleLeptonDQM_PU_cfi.py:39
HLTExoticaSubAnalysis::_genMETSelector
StringCutObjectSelector< reco::GenMET > * _genMETSelector
Definition: HLTExoticaSubAnalysis.h:177
HLTExoticaSubAnalysis::_recMETSelector
StringCutObjectSelector< reco::MET > * _recMETSelector
Definition: HLTExoticaSubAnalysis.h:174
reco::JetExtendedAssociation::value_type
Container::value_type value_type
Definition: JetExtendedAssociation.h:30
HLTExoticaSubAnalysis::_recCaloJetSelector
StringCutObjectSelector< reco::CaloJet > * _recCaloJetSelector
Definition: HLTExoticaSubAnalysis.h:184
edm::LogError
Log< level::Error, false > LogError
Definition: MessageLogger.h:123
edm::EDGetToken
Definition: EDGetToken.h:35
SelectiveReadoutTask_cfi.edges
edges
Definition: SelectiveReadoutTask_cfi.py:107
HLTExoticaSubAnalysis::_recCaloMHTSelector
StringCutObjectSelector< reco::CaloMET > * _recCaloMHTSelector
Definition: HLTExoticaSubAnalysis.h:179
reco::Candidate
Definition: Candidate.h:27
HLTExoticaSubAnalysis::_minCandidates
unsigned int _minCandidates
The minimum number of reco/gen candidates needed by the analysis.
Definition: HLTExoticaSubAnalysis.h:128
HLTExoticaSubAnalysis::_plotters
std::vector< HLTExoticaPlotter > _plotters
The plotters: managers of each hlt path where the plots are done.
Definition: HLTExoticaSubAnalysis.h:187
DDAxes::phi
reco::BeamSpot::x0
double x0() const
x coordinate
Definition: BeamSpot.h:61
submitPVResolutionJobs.desc
string desc
Definition: submitPVResolutionJobs.py:251
taus_updatedMVAIds_cff.variable
variable
Definition: taus_updatedMVAIds_cff.py:33
EVTColContainer::ELEC
Definition: EVTColContainer.cc:48
HLTExoticaSubAnalysis::_beamSpotLabel
edm::InputTag _beamSpotLabel
Definition: HLTExoticaSubAnalysis.h:141
EVTColContainer::MUTRK
Definition: EVTColContainer.cc:50
zMuMuMuonUserData.hltPath
hltPath
Definition: zMuMuMuonUserData.py:20
HLTConfigProvider::init
bool init(const edm::Run &iRun, const edm::EventSetup &iSetup, const std::string &processName, bool &changed)
d'tor
Definition: HLTConfigProvider.cc:36
analyzer
Definition: SiPixelLorentzAngle.h:82
HLTExoticaPlotter
Definition: HLTExoticaPlotter.h:43
reco::PFJetCollection
std::vector< PFJet > PFJetCollection
collection of PFJet objects
Definition: PFJetCollection.h:14
extraflags_cff.vtx
vtx
Definition: extraflags_cff.py:18
relativeConstraints.value
value
Definition: relativeConstraints.py:53
StringCutObjectSelector< reco::GenParticle >
HLTExoticaSubAnalysis::getNamesOfObjects
void getNamesOfObjects(const edm::ParameterSet &anpset)
Creates the maps that map which collection should come from which label.
Definition: HLTExoticaSubAnalysis.cc:769
findQualityFiles.jj
string jj
Definition: findQualityFiles.py:188
edm::TriggerNames
Definition: TriggerNames.h:55
Skims_PA_cff.name
name
Definition: Skims_PA_cff.py:17
HLTExoticaSubAnalysis::_recMuonSelector
StringCutObjectSelector< reco::Muon > * _recMuonSelector
Definition: HLTExoticaSubAnalysis.h:170
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
ROOT::Math::XYZVector
Transform3DPJ::Vector XYZVector
Definition: Transform3DPJ.cc:34
HLTExoticaSubAnalysis::_parametersPhi
std::vector< double > _parametersPhi
Definition: HLTExoticaSubAnalysis.h:151
dqm-mbProfile.log
log
Definition: dqm-mbProfile.py:17
HLTExoticaSubAnalysis::_hltPaths
std::set< std::string > _hltPaths
The hlt paths found in the hltConfig.
Definition: HLTExoticaSubAnalysis.h:133
edm::HLTGlobalStatus::accept
bool accept() const
Has at least one path accepted the event?
Definition: HLTGlobalStatus.h:49
patCandidatesForDimuonsSequences_cff.matches
matches
Definition: patCandidatesForDimuonsSequences_cff.py:131
reco::PhotonCollection
std::vector< Photon > PhotonCollection
collectin of Photon objects
Definition: PhotonFwd.h:9
cms::cuda::co
VT * co
Definition: prefixScan.h:46
reco::LeafCandidate
Definition: LeafCandidate.h:16
castor_dqm_sourceclient_file_cfg.path
path
Definition: castor_dqm_sourceclient_file_cfg.py:37
genParticles_cff.map
map
Definition: genParticles_cff.py:11
LogTrace
#define LogTrace(id)
Definition: MessageLogger.h:224
reco::CaloMETCollection
std::vector< reco::CaloMET > CaloMETCollection
collection of CaloMET objects
Definition: CaloMETCollection.h:20
HLTExoticaSubAnalysis::_recLabels
std::map< unsigned int, edm::InputTag > _recLabels
Definition: HLTExoticaSubAnalysis.h:142
HLTConfigProvider::triggerNames
const std::vector< std::string > & triggerNames() const
names of trigger paths
Definition: HLTConfigProvider.h:69
EVTColContainer::PFMHT
Definition: EVTColContainer.cc:54
HLTExoticaSubAnalysis::_recPFMETSelector
StringCutObjectSelector< reco::PFMET > * _recPFMETSelector
Definition: HLTExoticaSubAnalysis.h:175
dqmiolumiharvest.j
j
Definition: dqmiolumiharvest.py:66
edm::HandleBase::isValid
bool isValid() const
Definition: HandleBase.h:70
reco::BeamSpot::y0
double y0() const
y coordinate
Definition: BeamSpot.h:63
HLTExoticaSubAnalysis::_trigResultsLabel
edm::InputTag _trigResultsLabel
Definition: HLTExoticaSubAnalysis.h:140
HLTExoticaSubAnalysis::_recTrackSelector
StringCutObjectSelector< reco::Track > * _recTrackSelector
Definition: HLTExoticaSubAnalysis.h:172
HLTExoticaSubAnalysis::registerConsumes
void registerConsumes(edm::ConsumesCollector &consCollector)
Registers consumption of objects.
Definition: HLTExoticaSubAnalysis.cc:847
HLTExoticaSubAnalysis::bookHist
void bookHist(DQMStore::IBooker &iBooker, const std::string &source, const std::string &objType, const std::string &variable)
The internal functions to book and fill histograms.
Definition: HLTExoticaSubAnalysis.cc:1047
edm::InputTag
Definition: InputTag.h:15
reco::TrackCollection
std::vector< Track > TrackCollection
collection of Tracks
Definition: TrackFwd.h:14
HLTExoticaSubAnalysis::_drop_pt3
bool _drop_pt3
Definition: HLTExoticaSubAnalysis.h:158
edm::TriggerResults
Definition: TriggerResults.h:35
EVTColContainer::PHOTON
Definition: EVTColContainer.cc:47
HLTExoticaSubAnalysis::_recPFTauSelector
StringCutObjectSelector< reco::PFTau > * _recPFTauSelector
Definition: HLTExoticaSubAnalysis.h:181
HLTExoticaSubAnalysis::_genSelectorMap
std::map< unsigned int, StringCutObjectSelector< reco::GenParticle > * > _genSelectorMap
Definition: HLTExoticaSubAnalysis.h:169
muonDTDigis_cfi.pset
pset
Definition: muonDTDigis_cfi.py:27
dqm::implementation::IBooker::book1D
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
Definition: DQMStore.h:98
Photon_E30GeV_all_cfg.GEN
GEN
Definition: Photon_E30GeV_all_cfg.py:36
findQualityFiles.size
size
Write out results.
Definition: findQualityFiles.py:443
unpackBuffers-CaloStage2.token
token
Definition: unpackBuffers-CaloStage2.py:318