CMS 3D CMS Logo

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

#include <TriggerSummaryAnalyzerRAW.h>

Inheritance diagram for TriggerSummaryAnalyzerRAW:
edm::EDAnalyzer

Public Member Functions

virtual void analyze (const edm::Event &, const edm::EventSetup &)
 
 TriggerSummaryAnalyzerRAW (const edm::ParameterSet &)
 
 ~TriggerSummaryAnalyzerRAW ()
 
- Public Member Functions inherited from edm::EDAnalyzer
 EDAnalyzer ()
 
std::string workerType () const
 
virtual ~EDAnalyzer ()
 

Private Attributes

edm::InputTag inputTag_
 InputTag of TriggerEventWithRefs to analyze. More...
 

Additional Inherited Members

- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
typedef WorkerT< EDAnalyzerWorkerType
 
- Static Public Member Functions inherited from edm::EDAnalyzer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &)
 
- Protected Member Functions inherited from edm::EDAnalyzer
CurrentProcessingContext const * currentContext () const
 

Detailed Description

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

Date:
2008/04/11 18:09:11
Revision:
1.2
Author
Martin Grunewald

See header file for documentation

Date:
2012/01/30 09:40:35
Revision:
1.11
Author
Martin Grunewald

Definition at line 23 of file TriggerSummaryAnalyzerRAW.h.

Constructor & Destructor Documentation

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

Definition at line 18 of file TriggerSummaryAnalyzerRAW.cc.

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

Definition at line 22 of file TriggerSummaryAnalyzerRAW.cc.

23 {
24 }

Member Function Documentation

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

Implements edm::EDAnalyzer.

Definition at line 32 of file TriggerSummaryAnalyzerRAW.cc.

References gather_cfg::cout, edm::InputTag::encode(), edm::Event::getByLabel(), patZpeak::handle, inputTag_, and dt_dqm_sourceclient_common_cff::reco.

33 {
34  using namespace std;
35  using namespace edm;
36  using namespace reco;
37  using namespace l1extra;
38  using namespace trigger;
39 
40  cout << endl;
41  cout << "TriggerSummaryAnalyzerRAW: content of TriggerEventWithRefs: " << inputTag_.encode();
42 
44  iEvent.getByLabel(inputTag_,handle);
45  if (handle.isValid()) {
46  cout << "Used Processname: " << handle->usedProcessName() << endl;
47  const size_type nFO(handle->size());
48  cout << "Number of TriggerFilterObjects: " << nFO << endl;
49  cout << "The TriggerFilterObjects: #, tag" << endl;
50  for (size_type iFO=0; iFO!=nFO; ++iFO) {
51  cout << iFO << " " << handle->filterTag(iFO).encode() << endl;
52  cout << " # of objects:";
53 
54  const unsigned int nPhotons(handle->photonSlice(iFO).second-
55  handle->photonSlice(iFO).first);
56  if (nPhotons>0) cout << " Photons: " << nPhotons;
57 
58  const unsigned int nElectrons(handle->electronSlice(iFO).second-
59  handle->electronSlice(iFO).first);
60  if (nElectrons>0) cout << " Electrons: " << nElectrons;
61 
62  const unsigned int nMuons(handle->muonSlice(iFO).second-
63  handle->muonSlice(iFO).first);
64  if (nMuons>0) cout << " Muons: " << nMuons;
65 
66  const unsigned int nJets(handle->jetSlice(iFO).second-
67  handle->jetSlice(iFO).first);
68  if (nJets>0) cout << " Jets: " << nJets;
69 
70  const unsigned int nComposites(handle->compositeSlice(iFO).second-
71  handle->compositeSlice(iFO).first);
72  if (nComposites>0) cout << " Composites: " << nComposites;
73 
74  const unsigned int nBaseMETs(handle->basemetSlice(iFO).second-
75  handle->basemetSlice(iFO).first);
76  if (nBaseMETs>0) cout << " BaseMETs: " << nBaseMETs;
77 
78  const unsigned int nCaloMETs(handle->calometSlice(iFO).second-
79  handle->calometSlice(iFO).first);
80  if (nCaloMETs>0) cout << " CaloMETs: " << nCaloMETs;
81 
82  const unsigned int nPixTracks(handle->pixtrackSlice(iFO).second-
83  handle->pixtrackSlice(iFO).first);
84  if (nPixTracks>0) cout << " PixTracks: " << nPixTracks;
85 
86  const unsigned int nL1EM(handle->l1emSlice(iFO).second-
87  handle->l1emSlice(iFO).first);
88  if (nL1EM>0) cout << " L1EM: " << nL1EM;
89 
90  const unsigned int nL1Muon(handle->l1muonSlice(iFO).second-
91  handle->l1muonSlice(iFO).first);
92  if (nL1Muon>0) cout << " L1Muon: " << nL1Muon;
93 
94  const unsigned int nL1Jet(handle->l1jetSlice(iFO).second-
95  handle->l1jetSlice(iFO).first);
96  if (nL1Jet>0) cout << " L1Jet: " << nL1Jet;
97 
98  const unsigned int nL1EtMiss(handle->l1etmissSlice(iFO).second-
99  handle->l1etmissSlice(iFO).first);
100  if (nL1EtMiss>0) cout << " L1EtMiss: " << nL1EtMiss;
101 
102  const unsigned int nL1HfRings(handle->l1hfringsSlice(iFO).second-
103  handle->l1hfringsSlice(iFO).first);
104  if (nL1HfRings>0) cout << " L1HfRings: " << nL1HfRings;
105 
106  const unsigned int nPFJets(handle->pfjetSlice(iFO).second-
107  handle->pfjetSlice(iFO).first);
108  if (nPFJets>0) cout << " PFJets: " << nPFJets;
109 
110  const unsigned int nPFTaus(handle->pftauSlice(iFO).second-
111  handle->pftauSlice(iFO).first);
112  if (nPFTaus>0) cout << " PFTaus: " << nPFTaus;
113 
114  cout << endl;
115  }
116  cout << "Elements in linearised collections of Refs: " << endl;
117  cout << " Photons: " << handle->photonSize() << endl;
118  cout << " Electrons: " << handle->electronSize() << endl;
119  cout << " Muons: " << handle->muonSize() << endl;
120  cout << " Jets: " << handle->jetSize() << endl;
121  cout << " Composites: " << handle->compositeSize() << endl;
122  cout << " BaseMETs: " << handle->basemetSize() << endl;
123  cout << " CaloMETs: " << handle->calometSize() << endl;
124  cout << " Pixtracks: " << handle->pixtrackSize() << endl;
125  cout << " L1EM: " << handle->l1emSize() << endl;
126  cout << " L1Muon: " << handle->l1muonSize() << endl;
127  cout << " L1Jet: " << handle->l1jetSize() << endl;
128  cout << " L1EtMiss: " << handle->l1etmissSize() << endl;
129  cout << " L1HfRings: " << handle->l1hfringsSize() << endl;
130  cout << " PFJets: " << handle->pfjetSize() << endl;
131  cout << " PFTaus: " << handle->pftauSize() << endl;
132  } else {
133  cout << "Handle invalid! Check InputTag provided." << endl;
134  }
135  cout << endl;
136 
137  return;
138 }
uint16_t size_type
std::string encode() const
Definition: InputTag.cc:72
tuple handle
Definition: patZpeak.py:22
edm::InputTag inputTag_
InputTag of TriggerEventWithRefs to analyze.
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
Definition: Event.h:356
tuple cout
Definition: gather_cfg.py:121

Member Data Documentation

edm::InputTag TriggerSummaryAnalyzerRAW::inputTag_
private

InputTag of TriggerEventWithRefs to analyze.

Definition at line 32 of file TriggerSummaryAnalyzerRAW.h.

Referenced by analyze().