44 return std::make_unique<AlCaIsoTracksProdFilter::Counters>();
48 void endStream()
override;
76 edm::LogInfo(
"HcalIsoTrack") <<
"Use process name " << processName_ <<
" Labels " << triggerResultsLabel_
77 <<
" selecting " <<
trigNames_.size() <<
" triggers\n";
91 bool triggerSatisfied(
false);
93 triggerSatisfied =
true;
98 std::vector<std::string>
modules;
100 const std::vector<std::string>& triggerNames_ = triggerNames.
triggerNames();
101 for (
unsigned int iHLT = 0; iHLT < triggerResults->
size(); iHLT++) {
105 edm::LogInfo(
"HcalIsoTrack") << triggerNames_[iHLT] <<
" has got HLT flag " << hlt <<
":" 106 << triggerSatisfied << std::endl;
108 triggerSatisfied =
true;
113 if (triggerSatisfied)
118 if (triggerSatisfied)
120 return triggerSatisfied;
124 globalCache()->nAll_ +=
nAll_;
125 globalCache()->nGood_ +=
nGood_;
129 edm::LogInfo(
"HcalIsoTrack") <<
"Selects " << count->
nGood_ <<
" in " << count->
nAll_ <<
" events " << std::endl;
135 edm::LogInfo(
"HcalIsoTrack") <<
"Run[" <<
nRun_ <<
"] " << iRun.
run() <<
" hltconfig.init " << flag << std::endl;
148 std::vector<std::string>
trigger = {
"HLT_IsoTrackHB",
"HLT_IsoTrackHE"};
149 desc.
add<std::vector<std::string> >(
"triggers", trigger);
151 descriptions.
add(
"alcaIsoTracksProducerFilter", desc);
T getParameter(std::string const &) const
EventNumber_t event() const
HLTConfigProvider hltConfig_
std::atomic< unsigned int > nAll_
bool getByToken(EDGetToken token, Handle< PROD > &result) const
bool accept() const
Has at least one path accepted the event?
int bunchCrossing() const
static std::unique_ptr< AlCaIsoTracksProdFilter::Counters > initializeGlobalCache(edm::ParameterSet const &iConfig)
edm::LuminosityBlockNumber_t luminosityBlock() const
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Strings const & triggerNames() const
std::atomic< unsigned int > nGood_
void beginRun(edm::Run const &, edm::EventSetup const &) override
#define DEFINE_FWK_MODULE(type)
~AlCaIsoTracksProducerFilter() override
unsigned int size() const
Get number of paths stored.
static std::string const triggerResults
ParameterDescriptionBase * add(U const &iLabel, T const &value)
edm::EDGetTokenT< edm::TriggerResults > tok_trigRes_
void endStream() override
std::vector< std::string > trigNames_
void endRun(edm::Run const &, edm::EventSetup const &) override
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
bool init(const edm::Run &iRun, const edm::EventSetup &iSetup, const std::string &processName, bool &changed)
d'tor
edm::InputTag triggerResultsLabel_
void add(std::string const &label, ParameterSetDescription const &psetDescription)
static void globalEndJob(const AlCaIsoTracksProdFilter::Counters *counters)
AlCaIsoTracksProducerFilter(edm::ParameterSet const &, const AlCaIsoTracksProdFilter::Counters *count)
bool filter(edm::Event &, edm::EventSetup const &) override
edm::TriggerNames const & triggerNames(edm::TriggerResults const &triggerResults) const override
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)