34 candTag_ (iConfig.getParameter< edm::
InputTag > (
"CandTag") ),
36 previousCandTag_ (iConfig.getParameter<edm::
InputTag > (
"PreviousCandTag")),
37 previousCandToken_ (consumes<trigger::TriggerFilterObjectWithRefs>(previousCandTag_)),
38 depTag_ (iConfig.getParameter< std::vector< edm::
InputTag > >(
"DepTag" ) ),
40 theDepositIsolator(0),
41 min_N_ (iConfig.getParameter<int> (
"MinN"))
43 std::stringstream
tags;
46 tags<<
" IsoTag["<<i<<
"] : "<<
depTag_[
i].encode()<<
" \n";
55 if (isolatorPSet.
empty()) {
78 desc.
add<
int>(
"MinN",1);
79 std::vector<edm::InputTag> depTag(1,
edm::InputTag(
"hltL3MuonIsolations"));
80 desc.
add<std::vector<edm::InputTag> >(
"DepTag",depTag);
83 descriptions.
add(
"hltMuonIsoFilter", desc);
92 using namespace trigger;
100 std::auto_ptr<edm::ValueMap<bool> >
109 vector<RecoChargedCandidateRef> vcands;
110 previousLevelCands->getObjects(
TriggerMuon,vcands);
113 unsigned int nDep=
depTag_.size();
114 std::vector< Handle<edm::ValueMap<reco::IsoDeposit> > > depMap(nDep);
127 unsigned int nMu=mucands->size();
128 std::vector<bool> isos(nMu,
false);
130 for (; iMu<nMu; iMu++) {
143 for(
unsigned int iDep=0;iDep!=nDep;++iDep){
146 LogDebug(
"HLTMuonIsoFilter") <<
" Muon with q*pt= " << tk->charge()*tk->pt() <<
" (" << candref->charge()*candref->pt() <<
") " <<
", eta= " << tk->eta() <<
" (" << candref->eta() <<
") " <<
"; has deposit["<<iDep<<
"]: " << muonDeposit.
print();
157 isos[iMu]=(*decisionMap)[candref];
159 LogDebug(
"HLTMuonIsoFilter") <<
" Muon with q*pt= " << tk->charge()*tk->pt() <<
", eta= " << tk->eta() <<
"; "<<(isos[iMu]?
"Is an isolated muon.":
"Is NOT an isolated muon.");
161 if (!isos[iMu])
continue;
174 isoFiller.
insert(mucands, isos.begin(), isos.end());
180 LogDebug(
"HLTMuonIsoFilter") <<
" >>>>> Result of HLTMuonIsoFilter is " << accept <<
", number of muons passing isolation cuts= " << nIsolatedMu;
188 unsigned int i_max=vcands.size();
190 if (candref == vcands[i]) { ok=
true;
break;}
virtual bool hltFilter(edm::Event &, const edm::EventSetup &, trigger::TriggerFilterObjectWithRefs &filterproduct) const override
T getParameter(std::string const &) const
bool isNonnull() const
Checks for non-null.
bool getByToken(EDGetToken token, Handle< PROD > &result) const
edm::EDGetTokenT< edm::ValueMap< bool > > decMapToken_
virtual Result result(const DepositContainer &deposits, const edm::Event *=0) const =0
Compute and return the isolation variable.
void insert(const H &h, I begin, I end)
std::vector< edm::EDGetTokenT< edm::ValueMap< reco::IsoDeposit > > > depToken_
bool accept(const edm::Event &event, const edm::TriggerResults &triggerTable, const std::string &triggerPath)
edm::EDGetTokenT< trigger::TriggerFilterObjectWithRefs > previousCandToken_
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
void addObject(int id, const reco::RecoEcalCandidateRef &ref)
setters for L3 collections: (id=physics type, and Ref<C>)
HLTMuonIsoFilter(const edm::ParameterSet &)
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
ConsumesCollector consumesCollector()
Use a ConsumesCollector to gather consumes information from helper functions.
static bool triggerdByPreviousLevel(const reco::RecoChargedCandidateRef &, const std::vector< reco::RecoChargedCandidateRef > &)
const muonisolation::MuIsoBaseIsolator * theDepositIsolator
T const * get() const
Returns C++ pointer to the item.
ParameterDescriptionBase * add(U const &iLabel, T const &value)
Container::value_type value_type
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
std::vector< RecoChargedCandidate > RecoChargedCandidateCollection
collectin of RecoChargedCandidate objects
static void makeHLTFilterDescription(edm::ParameterSetDescription &desc)
std::vector< DepositAndVetos > DepositContainer
void addCollectionTag(const edm::InputTag &collectionTag)
collectionTags
void add(std::string const &label, ParameterSetDescription const &psetDescription)
std::string print() const
edm::EDGetTokenT< reco::RecoChargedCandidateCollection > candToken_
std::vector< edm::InputTag > depTag_
T get(const Candidate &c)