21 processName_(ps.getParameter<std::
string>(
"processName")),
22 triggerName_(ps.getParameter<std::
string>(
"triggerName")),
23 triggerResultsTag_(ps.getParameter<edm::
InputTag>(
"triggerResults")),
25 triggerEventTag_(ps.getParameter<edm::
InputTag>(
"triggerEvent")),
26 triggerEventToken_(consumes<trigger::TriggerEvent>(triggerEventTag_))
31 LogVerbatim(
"HLTEventAnalyzerAOD") <<
"HLTEventAnalyzerAOD configuration: " << endl
53 descriptions.
add(
"hltEventAnalyzerAOD", desc);
72 if (triggerIndex>=
n) {
73 LogVerbatim(
"HLTEventAnalyzerAOD") <<
"HLTEventAnalyzerAOD::analyze:"
75 <<
" not available in (new) config!" << endl;
76 LogVerbatim(
"HLTEventAnalyzerAOD") <<
"Available TriggerNames are: " << endl;
89 LogVerbatim(
"HLTEventAnalyzerAOD") <<
"HLTEventAnalyzerAOD::analyze:"
90 <<
" config extraction failure with process name "
107 LogVerbatim(
"HLTEventAnalyzerAOD") <<
"HLTEventAnalyzerAOD::analyze: Error in getting TriggerResults product from Event!" << endl;
112 LogVerbatim(
"HLTEventAnalyzerAOD") <<
"HLTEventAnalyzerAOD::analyze: Error in getting TriggerEvent product from Event!" << endl;
121 for (
unsigned int i=0;
i!=
n; ++
i) {
136 using namespace reco;
137 using namespace trigger;
146 if (triggerIndex>=
n) {
147 LogVerbatim(
"HLTEventAnalyzerAOD") <<
"HLTEventAnalyzerAOD::analyzeTrigger: path "
148 << triggerName <<
" - not found!" << endl;
153 LogVerbatim(
"HLTEventAnalyzerAOD") <<
"HLTEventAnalyzerAOD::analyzeTrigger: path "
154 << triggerName <<
" [" << triggerIndex <<
"] "
159 for (
unsigned int i=0;
i<prescalesInDetail.first.size(); ++
i) {
160 message <<
" " <<
i <<
":" << prescalesInDetail.first[
i].first <<
"/" << prescalesInDetail.first[
i].second;
162 LogVerbatim(
"HLTEventAnalyzerAOD") <<
"HLTEventAnalyzerAOD::analyzeTrigger: path "
163 << triggerName <<
" [" << triggerIndex <<
"] "
165 <<
"prescales L1T: " << prescalesInDetail.first.size() <<
message.str()
167 <<
"prescale HLT: " << prescalesInDetail.second
175 LogVerbatim(
"HLTEventAnalyzerAOD") <<
" Trigger path status:"
181 LogVerbatim(
"HLTEventAnalyzerAOD") <<
" Last active module - label/type: "
183 <<
" [" << moduleIndex <<
" out of 0-" << (
m-1) <<
" on this path]"
189 for (
unsigned int j=0;
j<=moduleIndex; ++
j) {
190 const string& moduleLabel(moduleLabels[
j]);
194 if (filterIndex<triggerEventHandle_->sizeFilters()) {
195 LogVerbatim(
"HLTEventAnalyzerAOD") <<
" 'L3' filter in slot " << j <<
" - label/type " << moduleLabel <<
"/" << moduleType << endl;
202 LogVerbatim(
"HLTEventAnalyzerAOD") <<
" " << n <<
" accepted 'L3' objects found: " << endl;
206 LogVerbatim(
"HLTEventAnalyzerAOD") <<
" " << i <<
" " << VIDS[
i] <<
"/" << KEYS[
i] <<
": "
207 << TO.
id() <<
" " << TO.
pt() <<
" " << TO.
eta() <<
" " << TO.
phi() <<
" " << TO.
mass()
unsigned int size() const
number of trigger paths in trigger table
void dump(const std::string &what) const
Dumping config info to cout.
virtual void analyzeTrigger(const edm::Event &, const edm::EventSetup &, const std::string &triggerName)
virtual edm::TriggerNames const & triggerNames(edm::TriggerResults const &triggerResults) const
const std::string moduleType(const std::string &module) const
C++ class name of module.
const std::string & triggerName(unsigned int triggerIndex) const
bool getByToken(EDGetToken token, Handle< PROD > &result) const
const edm::InputTag triggerResultsTag_
const edm::EDGetTokenT< edm::TriggerResults > triggerResultsToken_
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
const std::string triggerName_
std::pair< std::vector< std::pair< std::string, int > >, int > prescaleValuesInDetail(const edm::Event &iEvent, const edm::EventSetup &iSetup, const std::string &trigger) const
edm::Handle< trigger::TriggerEvent > triggerEventHandle_
const std::string processName_
module config parameters
triggerResultsToken_(consumes< edm::TriggerResults >(edm::InputTag("TriggerResults")))
unsigned int triggerIndex(const std::string &triggerName) const
slot position of trigger path in trigger table (0 to size-1)
Single trigger physics object (e.g., an isolated muon)
const edm::InputTag triggerEventTag_
unsigned int triggerIndex(std::string const &name) const
virtual void beginRun(edm::Run const &, edm::EventSetup const &) override
ParameterDescriptionBase * add(U const &iLabel, T const &value)
virtual void analyze(const edm::Event &, const edm::EventSetup &) override
const edm::EDGetTokenT< trigger::TriggerEvent > triggerEventToken_
const std::vector< std::string > & moduleLabels(unsigned int trigger) const
label(s) of module(s) on a trigger path
edm::Handle< edm::TriggerResults > triggerResultsHandle_
additional class data memebers
virtual ~HLTEventAnalyzerAOD()
std::vector< TriggerObject > TriggerObjectCollection
collection of trigger physics objects (e.g., all isolated muons)
virtual void endRun(edm::Run const &, edm::EventSetup const &) override
std::vector< size_type > Keys
HLTEventAnalyzerAOD(const edm::ParameterSet &)
bool init(const edm::Run &iRun, const edm::EventSetup &iSetup, const std::string &processName, bool &changed)
d'tor
void add(std::string const &label, ParameterSetDescription const &psetDescription)
std::pair< int, int > prescaleValues(const edm::Event &iEvent, const edm::EventSetup &iSetup, const std::string &trigger) const
Combined L1T (pair.first) and HLT (pair.second) prescales per HLT path.
HLTConfigProvider hltConfig_