47 : processName_(ps.getParameter<std::
string>(
"processName")),
48 triggerName_(ps.getParameter<std::
string>(
"triggerName")),
49 triggerResultsTag_(ps.getParameter<edm::
InputTag>(
"triggerResults")),
50 triggerResultsToken_(consumes<edm::TriggerResults>(triggerResultsTag_)),
51 triggerEventWithRefsTag_(ps.getParameter<edm::
InputTag>(
"triggerEventWithRefs")),
52 triggerEventWithRefsToken_(consumes<trigger::TriggerEventWithRefs>(triggerEventWithRefsTag_)) {
56 LogVerbatim(
"HLTEventAnalyzerRAW") <<
"HLTEventAnalyzerRAW configuration: " << endl
74 descriptions.
add(
"hltEventAnalyzerRAW", desc);
90 if (triggerIndex >=
n) {
92 <<
"HLTEventAnalyzerRAW::analyze:"
93 <<
" TriggerName " <<
triggerName_ <<
" not available in (new) config!" << endl;
94 LogVerbatim(
"HLTEventAnalyzerRAW") <<
"Available TriggerNames are: " << endl;
100 LogVerbatim(
"HLTEventAnalyzerRAW") <<
"HLTEventAnalyzerRAW::analyze:"
101 <<
" config extraction failure with process name " <<
processName_ << endl;
116 <<
"HLTEventAnalyzerRAW::analyze: Error in getting TriggerResults product from Event!" << endl;
122 <<
"HLTEventAnalyzerRAW::analyze: Error in getting TriggerEventWithRefs product from Event!" << endl;
131 for (
unsigned int i = 0;
i !=
n; ++
i) {
146 using namespace reco;
147 using namespace trigger;
156 if (triggerIndex >=
n) {
157 LogVerbatim(
"HLTEventAnalyzerRAW") <<
"HLTEventAnalyzerRAW::analyzeTrigger: path " << triggerName <<
" - not found!"
162 LogVerbatim(
"HLTEventAnalyzerRAW") <<
"HLTEventAnalyzerRAW::analyzeTrigger: path " << triggerName <<
" ["
163 << triggerIndex <<
"]" << endl;
169 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" Trigger path status:"
174 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" Last active module - label/type: " << moduleLabels[moduleIndex] <<
"/"
176 <<
" out of 0-" << (
m - 1) <<
" on this path]" << endl;
229 for (
unsigned int j = 0;
j <= moduleIndex; ++
j) {
230 const string& moduleLabel(moduleLabels[
j]);
234 if (filterIndex < triggerEventWithRefsHandle_->
size()) {
235 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" Filter in slot " << j <<
" - label/type " << moduleLabel <<
"/"
236 << moduleType << endl;
237 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" Filter packed up at: " << filterIndex << endl;
238 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" Accepted objects:" << endl;
241 const unsigned int nPhotons(
photonIds_.size());
243 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" Photons: " << nPhotons <<
" - the objects: # id pt" << endl;
244 for (
unsigned int i = 0;
i != nPhotons; ++
i) {
252 if (nElectrons > 0) {
253 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" Electrons: " << nElectrons <<
" - the objects: # id pt" << endl;
254 for (
unsigned int i = 0;
i != nElectrons; ++
i) {
261 const unsigned int nMuons(
muonIds_.size());
263 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" Muons: " << nMuons <<
" - the objects: # id pt" << endl;
264 for (
unsigned int i = 0;
i != nMuons; ++
i) {
270 const unsigned int nJets(
jetIds_.size());
272 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" Jets: " << nJets <<
" - the objects: # id pt" << endl;
273 for (
unsigned int i = 0;
i != nJets; ++
i) {
280 if (nComposites > 0) {
281 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" Composites: " << nComposites <<
" - the objects: # id pt" << endl;
282 for (
unsigned int i = 0;
i != nComposites; ++
i) {
291 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" BaseMETs: " << nBaseMETs <<
" - the objects: # id pt" << endl;
292 for (
unsigned int i = 0;
i != nBaseMETs; ++
i) {
301 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" CaloMETs: " << nCaloMETs <<
" - the objects: # id pt" << endl;
302 for (
unsigned int i = 0;
i != nCaloMETs; ++
i) {
310 if (nPixTracks > 0) {
311 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" PixTracks: " << nPixTracks <<
" - the objects: # id pt" << endl;
312 for (
unsigned int i = 0;
i != nPixTracks; ++
i) {
319 const unsigned int nL1EM(
l1emIds_.size());
321 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" L1EM: " << nL1EM <<
" - the objects: # id pt" << endl;
322 for (
unsigned int i = 0;
i != nL1EM; ++
i) {
328 const unsigned int nL1Muon(
l1muonIds_.size());
330 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" L1Muon: " << nL1Muon <<
" - the objects: # id pt" << endl;
331 for (
unsigned int i = 0;
i != nL1Muon; ++
i) {
338 const unsigned int nL1Jet(
l1jetIds_.size());
340 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" L1Jet: " << nL1Jet <<
" - the objects: # id pt" << endl;
341 for (
unsigned int i = 0;
i != nL1Jet; ++
i) {
349 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" L1EtMiss: " << nL1EtMiss <<
" - the objects: # id pt" << endl;
350 for (
unsigned int i = 0;
i != nL1EtMiss; ++
i) {
358 if (nL1HfRings > 0) {
359 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" L1HfRings: " << nL1HfRings <<
" - the objects: # id 4 4" << endl;
360 for (
unsigned int i = 0;
i != nL1HfRings; ++
i) {
376 const unsigned int nL1TTkMuons(
l1ttkmuIds_.size());
377 if (nL1TTkMuons > 0) {
378 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" L1TTkMuons: " << nL1TTkMuons <<
" - the objects: # id pt" << endl;
379 for (
unsigned int i = 0;
i != nL1TTkMuons; ++
i) {
386 const unsigned int nL1TTkElectrons(
l1ttkeleIds_.size());
387 if (nL1TTkElectrons > 0) {
389 <<
" L1TTkElectrons: " << nL1TTkElectrons <<
" - the objects: # id pt" << endl;
390 for (
unsigned int i = 0;
i != nL1TTkElectrons; ++
i) {
399 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" L1TTkEMs: " << nL1TTkEMs <<
" - the objects: # id pt" << endl;
400 for (
unsigned int i = 0;
i != nL1TTkEMs; ++
i) {
408 if (nL1TPFJets > 0) {
409 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" L1TPFJets: " << nL1TPFJets <<
" - the objects: # id pt" << endl;
410 for (
unsigned int i = 0;
i != nL1TPFJets; ++
i) {
418 if (nL1TPFTaus > 0) {
419 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" L1TPFTaus: " << nL1TPFTaus <<
" - the objects: # id pt" << endl;
420 for (
unsigned int i = 0;
i != nL1TPFTaus; ++
i) {
428 if (nL1THPSPFTaus > 0) {
430 <<
" L1THPSPFTaus: " << nL1THPSPFTaus <<
" - the objects: # id pt" << endl;
431 for (
unsigned int i = 0;
i != nL1THPSPFTaus; ++
i) {
439 if (nL1TPFTracks > 0) {
440 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" L1TPFTracks: " << nL1TPFTracks <<
" - the objects: # id pt" << endl;
441 for (
unsigned int i = 0;
i != nL1TPFTracks; ++
i) {
448 const unsigned int nPFJets(
pfjetIds_.size());
450 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" PFJets: " << nPFJets <<
" - the objects: # id pt" << endl;
451 for (
unsigned int i = 0;
i != nPFJets; ++
i) {
457 const unsigned int nPFTaus(
pftauIds_.size());
459 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" PFTaus: " << nPFTaus <<
" - the objects: # id pt" << endl;
460 for (
unsigned int i = 0;
i != nPFTaus; ++
i) {
466 const unsigned int nPfMETs(
pfmetIds_.size());
468 LogVerbatim(
"HLTEventAnalyzerRAW") <<
" PfMETs: " << nPfMETs <<
" - the objects: # id pt" << endl;
469 for (
unsigned int i = 0;
i != nPfMETs; ++
i) {
unsigned int size() const
number of trigger paths in trigger table
Log< level::Info, true > LogVerbatim
void dump(const std::string &what) const
Dumping config info to cout.
trigger::VRl1ttkele l1ttkeleRefs_
trigger::Vids compositeIds_
trigger::Vids calometIds_
const std::string moduleType(const std::string &module) const
C++ class name of module.
trigger::Vids l1thpspftauIds_
trigger::Vids l1etmissIds_
edm::Handle< edm::TriggerResults > triggerResultsHandle_
additional class data memebers
const std::string & triggerName(unsigned int triggerIndex) const
bool getByToken(EDGetToken token, Handle< PROD > &result) const
trigger::VRl1muon l1muonRefs_
trigger::Vids electronIds_
const edm::InputTag triggerEventWithRefsTag_
trigger::VRl1em l1emRefs_
unsigned int triggerIndex(std::string_view name) const
trigger::VRpftau pftauRefs_
trigger::VRl1tpftrack l1tpftrackRefs_
void endRun(edm::Run const &, edm::EventSetup const &) override
HLTEventAnalyzerRAW(const edm::ParameterSet &)
const edm::InputTag triggerResultsTag_
trigger::VRpfjet pfjetRefs_
trigger::Vids photonIds_
payload extracted from TriggerEventWithRefs
trigger::VRl1jet l1jetRefs_
edm::TriggerNames const & triggerNames(edm::TriggerResults const &triggerResults) const override
unsigned int triggerIndex(const std::string &triggerName) const
slot position of trigger path in trigger table (0 to size-1)
void beginRun(edm::Run const &, edm::EventSetup const &) override
trigger::Vids l1ttkemIds_
trigger::VRcomposite compositeRefs_
const std::string processName_
module config parameters
const edm::EDGetTokenT< trigger::TriggerEventWithRefs > triggerEventWithRefsToken_
trigger::VRphoton photonRefs_
trigger::Vids basemetIds_
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
HLTConfigProvider hltConfig_
trigger::VRpfmet pfmetRefs_
~HLTEventAnalyzerRAW() override
void analyze(const edm::Event &, const edm::EventSetup &) override
ParameterDescriptionBase * add(U const &iLabel, T const &value)
trigger::VRelectron electronRefs_
trigger::Vids l1tpftauIds_
const std::vector< std::string > & moduleLabels(unsigned int trigger) const
label(s) of module(s) on a trigger path
trigger::VRl1tpftau l1tpftauRefs_
const edm::EDGetTokenT< edm::TriggerResults > triggerResultsToken_
trigger::Vids pixtrackIds_
trigger::Vids l1hfringsIds_
trigger::VRl1etmiss l1etmissRefs_
trigger::Vids l1ttkeleIds_
trigger::VRl1tpfjet l1tpfjetRefs_
trigger::VRl1thpspftau l1thpspftauRefs_
edm::Handle< trigger::TriggerEventWithRefs > triggerEventWithRefsHandle_
bool init(const edm::Run &iRun, const edm::EventSetup &iSetup, const std::string &processName, bool &changed)
d'tor
trigger::Vids l1tpftrackIds_
void add(std::string const &label, ParameterSetDescription const &psetDescription)
trigger::VRl1hfrings l1hfringsRefs_
trigger::VRcalomet calometRefs_
virtual void analyzeTrigger(const edm::Event &, const edm::EventSetup &, const std::string &triggerName)
trigger::VRl1ttkmuon l1ttkmuRefs_
const std::string triggerName_
trigger::VRmuon muonRefs_
trigger::VRpixtrack pixtrackRefs_
trigger::Vids l1tpfjetIds_
trigger::VRbasemet basemetRefs_
trigger::VRl1ttkem l1ttkemRefs_
tuple size
Write out results.
trigger::Vids l1ttkmuIds_