CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Static Public Member Functions | Private Attributes
TriggerSummaryAnalyzerRAW Class Reference

#include <TriggerSummaryAnalyzerRAW.h>

Inheritance diagram for TriggerSummaryAnalyzerRAW:
edm::stream::EDAnalyzer<> edm::stream::EDAnalyzerBase edm::EDConsumerBase

Public Member Functions

virtual void analyze (const edm::Event &, const edm::EventSetup &) override
 
 TriggerSummaryAnalyzerRAW (const edm::ParameterSet &)
 
virtual ~TriggerSummaryAnalyzerRAW ()
 
- Public Member Functions inherited from edm::stream::EDAnalyzer<>
 EDAnalyzer ()=default
 
- Public Member Functions inherited from edm::stream::EDAnalyzerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzerBase ()
 
ModuleDescription const & moduleDescription () const
 
virtual ~EDAnalyzerBase ()
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
 EDConsumerBase ()
 
ProductHolderIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
std::vector
< ProductHolderIndexAndSkipBit >
const & 
itemsToGetFromEvent () const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesDependentUpon (std::string const &iProcessName, std::string const &iModuleLabel, bool iPrint, std::vector< char const * > &oModuleLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
bool registeredToConsume (ProductHolderIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
void updateLookup (BranchType iBranchType, ProductHolderIndexHelper const &)
 
virtual ~EDConsumerBase ()
 

Static Public Member Functions

static void fillDescriptions (edm::ConfigurationDescriptions &descriptions)
 
- Static Public Member Functions inherited from edm::stream::EDAnalyzerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 

Private Attributes

const edm::InputTag inputTag_
 InputTag of TriggerEventWithRefs to analyze. More...
 
const edm::EDGetTokenT
< trigger::TriggerEventWithRefs
inputToken_
 

Additional Inherited Members

- Public Types inherited from edm::stream::EDAnalyzer<>
typedef CacheContexts< T...> CacheTypes
 
typedef CacheTypes::GlobalCache GlobalCache
 
typedef AbilityChecker< T...> HasAbility
 
typedef
CacheTypes::LuminosityBlockCache 
LuminosityBlockCache
 
typedef
LuminosityBlockContextT
< LuminosityBlockCache,
RunCache, GlobalCache
LuminosityBlockContext
 
typedef
CacheTypes::LuminosityBlockSummaryCache 
LuminosityBlockSummaryCache
 
typedef CacheTypes::RunCache RunCache
 
typedef RunContextT< RunCache,
GlobalCache
RunContext
 
typedef CacheTypes::RunSummaryCache RunSummaryCache
 
- Public Types inherited from edm::stream::EDAnalyzerBase
typedef EDAnalyzerAdaptorBase ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 

Detailed Description

This class is an EDAnalyzer analyzing the HLT summary object for RAW

Author
Martin Grunewald

See header file for documentation

Author
Martin Grunewald

Definition at line 25 of file TriggerSummaryAnalyzerRAW.h.

Constructor & Destructor Documentation

TriggerSummaryAnalyzerRAW::TriggerSummaryAnalyzerRAW ( const edm::ParameterSet ps)
explicit

Definition at line 17 of file TriggerSummaryAnalyzerRAW.cc.

17  :
18  inputTag_(ps.getParameter<edm::InputTag>("inputTag")),
19  inputToken_(consumes<trigger::TriggerEventWithRefs>(inputTag_))
20 { }
T getParameter(std::string const &) const
const edm::InputTag inputTag_
InputTag of TriggerEventWithRefs to analyze.
const edm::EDGetTokenT< trigger::TriggerEventWithRefs > inputToken_
TriggerSummaryAnalyzerRAW::~TriggerSummaryAnalyzerRAW ( )
virtual

Definition at line 22 of file TriggerSummaryAnalyzerRAW.cc.

23 {
24 }

Member Function Documentation

void TriggerSummaryAnalyzerRAW::analyze ( const edm::Event iEvent,
const edm::EventSetup iSetup 
)
overridevirtual

Implements edm::stream::EDAnalyzerBase.

Definition at line 38 of file TriggerSummaryAnalyzerRAW.cc.

References edm::InputTag::encode(), edm::Event::getByToken(), patZpeak::handle, inputTag_, inputToken_, and dt_dqm_sourceclient_common_cff::reco.

39 {
40  using namespace std;
41  using namespace edm;
42  using namespace reco;
43  using namespace l1extra;
44  using namespace trigger;
45  using namespace l1t;
46 
47  LogVerbatim("TriggerSummaryAnalyzerRAW") << endl;
48  LogVerbatim("TriggerSummaryAnalyzerRAW") << "TriggerSummaryAnalyzerRAW: content of TriggerEventWithRefs: " << inputTag_.encode();
49 
52  if (handle.isValid()) {
53  LogVerbatim("TriggerSummaryAnalyzerRAW") << "Used Processname: " << handle->usedProcessName() << endl;
54  const size_type nFO(handle->size());
55  LogVerbatim("TriggerSummaryAnalyzerRAW") << "Number of TriggerFilterObjects: " << nFO << endl;
56  LogVerbatim("TriggerSummaryAnalyzerRAW") << "The TriggerFilterObjects: #, tag" << endl;
57  for (size_type iFO=0; iFO!=nFO; ++iFO) {
58  LogVerbatim("TriggerSummaryAnalyzerRAW") << iFO << " " << handle->filterTag(iFO).encode() << endl;
59  LogVerbatim("TriggerSummaryAnalyzerRAW") << " # of objects:";
60 
61  const unsigned int nPhotons(handle->photonSlice(iFO).second-
62  handle->photonSlice(iFO).first);
63  if (nPhotons>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " Photons: " << nPhotons;
64 
65  const unsigned int nElectrons(handle->electronSlice(iFO).second-
66  handle->electronSlice(iFO).first);
67  if (nElectrons>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " Electrons: " << nElectrons;
68 
69  const unsigned int nMuons(handle->muonSlice(iFO).second-
70  handle->muonSlice(iFO).first);
71  if (nMuons>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " Muons: " << nMuons;
72 
73  const unsigned int nJets(handle->jetSlice(iFO).second-
74  handle->jetSlice(iFO).first);
75  if (nJets>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " Jets: " << nJets;
76 
77  const unsigned int nComposites(handle->compositeSlice(iFO).second-
78  handle->compositeSlice(iFO).first);
79  if (nComposites>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " Composites: " << nComposites;
80 
81  const unsigned int nBaseMETs(handle->basemetSlice(iFO).second-
82  handle->basemetSlice(iFO).first);
83  if (nBaseMETs>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " BaseMETs: " << nBaseMETs;
84 
85  const unsigned int nCaloMETs(handle->calometSlice(iFO).second-
86  handle->calometSlice(iFO).first);
87  if (nCaloMETs>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " CaloMETs: " << nCaloMETs;
88 
89  const unsigned int nPixTracks(handle->pixtrackSlice(iFO).second-
90  handle->pixtrackSlice(iFO).first);
91  if (nPixTracks>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " PixTracks: " << nPixTracks;
92 
93  const unsigned int nL1EM(handle->l1emSlice(iFO).second-
94  handle->l1emSlice(iFO).first);
95  if (nL1EM>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1EM: " << nL1EM;
96 
97  const unsigned int nL1Muon(handle->l1muonSlice(iFO).second-
98  handle->l1muonSlice(iFO).first);
99  if (nL1Muon>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1Muon: " << nL1Muon;
100 
101  const unsigned int nL1Jet(handle->l1jetSlice(iFO).second-
102  handle->l1jetSlice(iFO).first);
103  if (nL1Jet>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1Jet: " << nL1Jet;
104 
105  const unsigned int nL1EtMiss(handle->l1etmissSlice(iFO).second-
106  handle->l1etmissSlice(iFO).first);
107  if (nL1EtMiss>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1EtMiss: " << nL1EtMiss;
108 
109  const unsigned int nL1HfRings(handle->l1hfringsSlice(iFO).second-
110  handle->l1hfringsSlice(iFO).first);
111  if (nL1HfRings>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1HfRings: " << nL1HfRings;
112 
113  const unsigned int nPFJets(handle->pfjetSlice(iFO).second-
114  handle->pfjetSlice(iFO).first);
115  if (nPFJets>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " PFJets: " << nPFJets;
116 
117  const unsigned int nPFTaus(handle->pftauSlice(iFO).second-
118  handle->pftauSlice(iFO).first);
119  if (nPFTaus>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " PFTaus: " << nPFTaus;
120 
121  const unsigned int nPFMETs(handle->pfmetSlice(iFO).second-
122  handle->pfmetSlice(iFO).first);
123  if (nPFMETs>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " PFMETs: " << nPFMETs;
124 
125  const unsigned int nL1TMuon(handle->l1tmuonSlice(iFO).second-
126  handle->l1tmuonSlice(iFO).first);
127  if (nL1TMuon>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1TMuon: " << nL1TMuon;
128 
129  const unsigned int nL1TEGamma(handle->l1tegammaSlice(iFO).second-
130  handle->l1tegammaSlice(iFO).first);
131  if (nL1TEGamma>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1TEGamma: " << nL1TEGamma;
132 
133  const unsigned int nL1TJet(handle->l1tjetSlice(iFO).second-
134  handle->l1tjetSlice(iFO).first);
135  if (nL1TJet>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1TJet: " << nL1TJet;
136 
137  const unsigned int nL1TTau(handle->l1ttauSlice(iFO).second-
138  handle->l1ttauSlice(iFO).first);
139  if (nL1TTau>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1TTau: " << nL1TTau;
140 
141  const unsigned int nL1TEtSum(handle->l1tetsumSlice(iFO).second-
142  handle->l1tetsumSlice(iFO).first);
143  if (nL1TEtSum>0) LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1TEtSum: " << nL1TEtSum;
144 
145 
146  LogVerbatim("TriggerSummaryAnalyzerRAW") << endl;
147  }
148  LogVerbatim("TriggerSummaryAnalyzerRAW") << "Elements in linearised collections of Refs: " << endl;
149  LogVerbatim("TriggerSummaryAnalyzerRAW") << " Photons: " << handle->photonSize() << endl;
150  LogVerbatim("TriggerSummaryAnalyzerRAW") << " Electrons: " << handle->electronSize() << endl;
151  LogVerbatim("TriggerSummaryAnalyzerRAW") << " Muons: " << handle->muonSize() << endl;
152  LogVerbatim("TriggerSummaryAnalyzerRAW") << " Jets: " << handle->jetSize() << endl;
153  LogVerbatim("TriggerSummaryAnalyzerRAW") << " Composites: " << handle->compositeSize() << endl;
154  LogVerbatim("TriggerSummaryAnalyzerRAW") << " BaseMETs: " << handle->basemetSize() << endl;
155  LogVerbatim("TriggerSummaryAnalyzerRAW") << " CaloMETs: " << handle->calometSize() << endl;
156  LogVerbatim("TriggerSummaryAnalyzerRAW") << " Pixtracks: " << handle->pixtrackSize() << endl;
157  LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1EM: " << handle->l1emSize() << endl;
158  LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1Muon: " << handle->l1muonSize() << endl;
159  LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1Jet: " << handle->l1jetSize() << endl;
160  LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1EtMiss: " << handle->l1etmissSize() << endl;
161  LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1HfRings: " << handle->l1hfringsSize() << endl;
162  LogVerbatim("TriggerSummaryAnalyzerRAW") << " PFJets: " << handle->pfjetSize() << endl;
163  LogVerbatim("TriggerSummaryAnalyzerRAW") << " PFTaus: " << handle->pftauSize() << endl;
164  LogVerbatim("TriggerSummaryAnalyzerRAW") << " PFMETs: " << handle->pfmetSize() << endl;
165  LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1TMuon: " << handle->l1tmuonSize() << endl;
166  LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1TEGamma: " << handle->l1tegammaSize() << endl;
167  LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1TJet: " << handle->l1tjetSize() << endl;
168  LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1TTau: " << handle->l1ttauSize() << endl;
169  LogVerbatim("TriggerSummaryAnalyzerRAW") << " L1TEtSum: " << handle->l1tetsumSize() << endl;
170  } else {
171  LogVerbatim("TriggerSummaryAnalyzerRAW") << "Handle invalid! Check InputTag provided." << endl;
172  }
173  LogVerbatim("TriggerSummaryAnalyzerRAW") << endl;
174 
175  return;
176 }
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:462
uint16_t size_type
std::string encode() const
Definition: InputTag.cc:164
const edm::InputTag inputTag_
InputTag of TriggerEventWithRefs to analyze.
tuple handle
Definition: patZpeak.py:22
const edm::EDGetTokenT< trigger::TriggerEventWithRefs > inputToken_
void TriggerSummaryAnalyzerRAW::fillDescriptions ( edm::ConfigurationDescriptions descriptions)
static

Definition at line 30 of file TriggerSummaryAnalyzerRAW.cc.

References edm::ConfigurationDescriptions::add(), edm::ParameterSetDescription::add(), and HLT_25ns10e33_v2_cff::InputTag.

30  {
32  desc.add<edm::InputTag>("inputTag",edm::InputTag("hltTriggerSummaryRAW"));
33  descriptions.add("triggerSummaryAnalyzerRAW", desc);
34 }
ParameterDescriptionBase * add(U const &iLabel, T const &value)
void add(std::string const &label, ParameterSetDescription const &psetDescription)

Member Data Documentation

const edm::InputTag TriggerSummaryAnalyzerRAW::inputTag_
private

InputTag of TriggerEventWithRefs to analyze.

Definition at line 35 of file TriggerSummaryAnalyzerRAW.h.

Referenced by analyze().

const edm::EDGetTokenT<trigger::TriggerEventWithRefs> TriggerSummaryAnalyzerRAW::inputToken_
private

Definition at line 36 of file TriggerSummaryAnalyzerRAW.h.

Referenced by analyze().