Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backport the refactoring of the PropagateToMuon class and add the propagating to some HLT filters #37299

Merged
merged 1 commit into from
Mar 23, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions DQMOffline/L1Trigger/interface/L1TMuonDQMOffline.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
#include "FWCore/MessageLogger/interface/MessageLogger.h"
#include "DataFormats/MuonReco/interface/Muon.h"
#include "DataFormats/MuonReco/interface/MuonFwd.h"
#include "MuonAnalysis/MuonAssociators/interface/PropagateToMuon.h"
#include "MuonAnalysis/MuonAssociators/interface/PropagateToMuonSetup.h"
#include "TrackingTools/TransientTrack/interface/TransientTrack.h"
#include "TrackingTools/TransientTrack/interface/TrackTransientTrack.h"
#include "TrackingTools/TransientTrack/interface/TransientTrackBuilder.h"
Expand Down Expand Up @@ -98,13 +98,13 @@ class L1TMuonDQMOffline : public DQMEDAnalyzer {
double matchHlt(edm::Handle<trigger::TriggerEvent>& triggerEvent, const reco::Muon* mu);

// Cut and Matching
void getMuonGmtPairs(edm::Handle<l1t::MuonBxCollection>& gmtCands);
void getMuonGmtPairs(edm::Handle<l1t::MuonBxCollection>& gmtCands, PropagateToMuon const& propagator);
void getTightMuons(edm::Handle<reco::MuonCollection>& muons, const reco::Vertex& vertex);
void getProbeMuons(edm::Handle<edm::TriggerResults>& trigResults, edm::Handle<trigger::TriggerEvent>& trigEvent);

HLTConfigProvider m_hltConfig;

PropagateToMuon m_propagator;
PropagateToMuonSetup const m_propagatorSetup;

std::vector<float> getHistBinsEff(EffType eff);
std::tuple<int, double, double> getHistBinsRes(ResType res);
Expand Down
5 changes: 5 additions & 0 deletions DQMOffline/L1Trigger/python/L1TMuonDQMOffline_cfi.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,11 @@
useSimpleGeometry = cms.bool(True),
useStation2 = cms.bool(True),
fallbackToME1 = cms.bool(False),
cosmicPropagationHypothesis = cms.bool(False),
useMB2InOverlap = cms.bool(False),
propagatorAlong = cms.ESInputTag("", "SteppingHelixPropagatorAlong"),
propagatorAny = cms.ESInputTag("", "SteppingHelixPropagatorAny"),
propagatorOpposite = cms.ESInputTag("", "SteppingHelixPropagatorOpposite")
),

verbose = cms.untracked.bool(False)
Expand Down
13 changes: 7 additions & 6 deletions DQMOffline/L1Trigger/src/L1TMuonDQMOffline.cc
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ double MuonGmtPair::getVar(const L1TMuonDQMOffline::EffType type) const {

//__________DQM_base_class_______________________________________________
L1TMuonDQMOffline::L1TMuonDQMOffline(const ParameterSet& ps)
: m_propagator(ps.getParameter<edm::ParameterSet>("muProp"), consumesCollector()),
: m_propagatorSetup(ps.getParameter<edm::ParameterSet>("muProp"), consumesCollector()),
m_effTypes({kEffPt, kEffPhi, kEffEta, kEffVtx}),
m_resTypes({kResPt, kResQOverPt, kResPhi, kResEta}),
m_etaRegions({kEtaRegionAll, kEtaRegionBmtf, kEtaRegionOmtf, kEtaRegionEmtf}),
Expand Down Expand Up @@ -210,7 +210,7 @@ void L1TMuonDQMOffline::bookHistograms(DQMStore::IBooker& ibooker, const edm::Ru

//_____________________________________________________________________
void L1TMuonDQMOffline::analyze(const Event& iEvent, const EventSetup& eventSetup) {
m_propagator.init(eventSetup);
auto const propagator = m_propagatorSetup.init(eventSetup);

Handle<reco::MuonCollection> muons;
iEvent.getByToken(m_MuonInputTag, muons);
Expand All @@ -231,7 +231,7 @@ void L1TMuonDQMOffline::analyze(const Event& iEvent, const EventSetup& eventSetu
getTightMuons(muons, primaryVertex);
getProbeMuons(trigResults, trigEvent); // CB add flag to run on orthogonal datasets (no T&P)

getMuonGmtPairs(gmtCands);
getMuonGmtPairs(gmtCands, propagator);

if (m_verbose)
cout << "[L1TMuonDQMOffline:] Computing efficiencies" << endl;
Expand Down Expand Up @@ -553,7 +553,8 @@ void L1TMuonDQMOffline::getProbeMuons(Handle<edm::TriggerResults>& trigResults,
}

//_____________________________________________________________________
void L1TMuonDQMOffline::getMuonGmtPairs(edm::Handle<l1t::MuonBxCollection>& gmtCands) {
void L1TMuonDQMOffline::getMuonGmtPairs(edm::Handle<l1t::MuonBxCollection>& gmtCands,
PropagateToMuon const& propagator) {
m_MuonGmtPairs.clear();
if (m_verbose)
cout << "[L1TMuonDQMOffline:] Getting muon GMT pairs" << endl;
Expand All @@ -565,7 +566,7 @@ void L1TMuonDQMOffline::getMuonGmtPairs(edm::Handle<l1t::MuonBxCollection>& gmtC
l1t::MuonBxCollection::const_iterator gmtEnd = gmtCands->end(0);

for (; probeMuIt != probeMuEnd; ++probeMuIt) {
MuonGmtPair pairBestCand((*probeMuIt), nullptr, m_propagator, m_useAtVtxCoord);
MuonGmtPair pairBestCand((*probeMuIt), nullptr, propagator, m_useAtVtxCoord);

// Fill the control histograms with the probe muon kinematic variables used
m_ControlHistos[kCtrlProbeEta]->Fill(pairBestCand.getVar(L1TMuonDQMOffline::kEffEta));
Expand All @@ -575,7 +576,7 @@ void L1TMuonDQMOffline::getMuonGmtPairs(edm::Handle<l1t::MuonBxCollection>& gmtC
gmtIt = gmtCands->begin(0); // use only on L1T muons from BX 0

for (; gmtIt != gmtEnd; ++gmtIt) {
MuonGmtPair pairTmpCand((*probeMuIt), &(*gmtIt), m_propagator, m_useAtVtxCoord);
MuonGmtPair pairTmpCand((*probeMuIt), &(*gmtIt), propagator, m_useAtVtxCoord);

if ((pairTmpCand.dR() < m_maxGmtMuonDR) && (pairTmpCand.dR() < pairBestCand.dR())) {
pairBestCand = pairTmpCand;
Expand Down
1 change: 1 addition & 0 deletions HLTrigger/Muon/plugins/BuildFile.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,5 @@
<use name="TrackingTools/PatternTools"/>
<use name="TrackingTools/TransientTrack"/>
<use name="RecoTracker/FinalTrackSelectors"/>
<use name="MuonAnalysis/MuonAssociators"/>
<flags EDM_PLUGIN="1"/>
16 changes: 14 additions & 2 deletions HLTrigger/Muon/plugins/HLTMuonDimuonL3Filter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ namespace {

HLTMuonDimuonL3Filter::HLTMuonDimuonL3Filter(const edm::ParameterSet& iConfig)
: HLTFilter(iConfig),
propSetup_(iConfig, consumesCollector()),
idealMagneticFieldRecordToken_(esConsumes()),
beamspotTag_(iConfig.getParameter<edm::InputTag>("BeamSpotTag")),
beamspotToken_(consumes<reco::BeamSpot>(beamspotTag_)),
Expand Down Expand Up @@ -89,6 +90,7 @@ HLTMuonDimuonL3Filter::HLTMuonDimuonL3Filter(const edm::ParameterSet& iConfig)
theL3LinksLabel(iConfig.getParameter<InputTag>("InputLinks")),
linkToken_(consumes<reco::MuonTrackLinksCollection>(theL3LinksLabel)),
L1MatchingdR_(iConfig.getParameter<double>("L1MatchingdR")),
L1MatchingdR2_(L1MatchingdR_ * L1MatchingdR_),
matchPreviousCand_(iConfig.getParameter<bool>("MatchToPreviousCand")),
MuMass2_(0.106 * 0.106) {
// check consistency of parameters for mass-window cuts
Expand Down Expand Up @@ -117,6 +119,10 @@ HLTMuonDimuonL3Filter::HLTMuonDimuonL3Filter(const edm::ParameterSet& iConfig)
<< ") and \"MaxInvMass\" (" << max_InvMass_.size() << ") differ";
}

if (L1MatchingdR_ <= 0.) {
throw cms::Exception("HLTMuonDimuonL3FilterConfiguration")
<< "invalid value for parameter \"L1MatchingdR\" (must be > 0): " << L1MatchingdR_;
}
LogDebug("HLTMuonDimuonL3Filter") << " CandTag/FastAccept/MinN/MaxEta/MinNhits/MaxDr/MaxDz/MinPt1/MinPt2/MinInvMass/"
"MaxInvMass/applyMinDiMuonDeltaRCut/MinDiMuonDeltaR"
"MinAcop/MaxAcop/MinPtBalance/MaxPtBalance/NSigmaPt/MaxDzMuMu/MaxRapidityPair : "
Expand Down Expand Up @@ -181,6 +187,7 @@ void HLTMuonDimuonL3Filter::fillDescriptions(edm::ConfigurationDescriptions& des
desc.add<edm::InputTag>("InputLinks", edm::InputTag(""));
desc.add<double>("L1MatchingdR", 0.3);
desc.add<bool>("MatchToPreviousCand", true);
PropagateToMuonSetup::fillPSetDescription(desc);
descriptions.add("hltMuonDimuonL3Filter", desc);
}

Expand All @@ -196,6 +203,8 @@ bool HLTMuonDimuonL3Filter::hltFilter(edm::Event& iEvent,
// recording any reconstructed physics objects satisfying (or not)
// this HLT filter, and place it in the Event.

auto const prop = propSetup_.init(iSetup);

// Read RecoChargedCandidates from L3MuonCandidateProducer:
Handle<RecoChargedCandidateCollection> mucands;
if (saveTags())
Expand Down Expand Up @@ -282,12 +291,15 @@ bool HLTMuonDimuonL3Filter::hltFilter(edm::Event& iEvent,
} //MTL loop

if (not l1CandTag_.label().empty() and check_l1match) {
auto const propagated = prop.extrapolate(*tk);
auto const etaForMatch = propagated.isValid() ? propagated.globalPosition().eta() : cand->eta();
auto const phiForMatch = propagated.isValid() ? (double)propagated.globalPosition().phi() : cand->phi();
iEvent.getByToken(l1CandToken_, level1Cands);
level1Cands->getObjects(trigger::TriggerL1Mu, vl1cands);
const unsigned int nL1Muons(vl1cands.size());
for (unsigned int il1 = 0; il1 != nL1Muons; ++il1) {
if (deltaR(cand->eta(), cand->phi(), vl1cands[il1]->eta(), vl1cands[il1]->phi()) <
L1MatchingdR_) { //was muon, non cand
if (deltaR2(etaForMatch, phiForMatch, vl1cands[il1]->eta(), vl1cands[il1]->phi()) <
L1MatchingdR2_) { //was muon, non cand
MuonToL3s[i] = RecoChargedCandidateRef(cand);
}
}
Expand Down
4 changes: 4 additions & 0 deletions HLTrigger/Muon/plugins/HLTMuonDimuonL3Filter.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
#include "FWCore/Framework/interface/ESHandle.h"
#include "MagneticField/Engine/interface/MagneticField.h"
#include "MagneticField/Records/interface/IdealMagneticFieldRecord.h"
#include "MuonAnalysis/MuonAssociators/interface/PropagateToMuonSetup.h"

namespace edm {
class ConfigurationDescriptions;
Expand All @@ -45,6 +46,8 @@ class HLTMuonDimuonL3Filter : public HLTFilter {
const reco::RecoChargedCandidateRef&,
const reco::BeamSpot&,
const edm::ESHandle<MagneticField>&) const;

const PropagateToMuonSetup propSetup_;
const edm::ESGetToken<MagneticField, IdealMagneticFieldRecord> idealMagneticFieldRecordToken_;
const edm::InputTag beamspotTag_;
const edm::EDGetTokenT<reco::BeamSpot> beamspotToken_;
Expand Down Expand Up @@ -86,6 +89,7 @@ class HLTMuonDimuonL3Filter : public HLTFilter {
const edm::InputTag theL3LinksLabel; //Needed to iterL3
const edm::EDGetTokenT<reco::MuonTrackLinksCollection> linkToken_; //Needed to iterL3
const double L1MatchingdR_;
const double L1MatchingdR2_;
const bool matchPreviousCand_;
const double MuMass2_;
};
Expand Down
14 changes: 13 additions & 1 deletion HLTrigger/Muon/plugins/HLTMuonL3PreFilter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ using namespace trigger;

HLTMuonL3PreFilter::HLTMuonL3PreFilter(const ParameterSet& iConfig)
: HLTFilter(iConfig),
propSetup_(iConfig, consumesCollector()),
beamspotTag_(iConfig.getParameter<edm::InputTag>("BeamSpotTag")),
beamspotToken_(consumes<reco::BeamSpot>(beamspotTag_)),
candTag_(iConfig.getParameter<InputTag>("CandTag")),
Expand Down Expand Up @@ -66,11 +67,16 @@ HLTMuonL3PreFilter::HLTMuonL3PreFilter(const ParameterSet& iConfig)
maxNormalizedChi2_L3fromL1_(iConfig.getParameter<double>("MaxNormalizedChi2_L3FromL1")),
trkMuonId_(muon::SelectionType(iConfig.getParameter<unsigned int>("trkMuonId"))),
L1MatchingdR_(iConfig.getParameter<double>("L1MatchingdR")),
L1MatchingdR2_(L1MatchingdR_ * L1MatchingdR_),
matchPreviousCand_(iConfig.getParameter<bool>("MatchToPreviousCand")),

devDebug_(false),
theL3LinksLabel(iConfig.getParameter<InputTag>("InputLinks")),
linkToken_(consumes<reco::MuonTrackLinksCollection>(theL3LinksLabel)) {
if (L1MatchingdR_ <= 0.) {
throw cms::Exception("HLTMuonL3PreFilterConfiguration")
<< "invalid value for parameter \"L1MatchingdR\" (must be > 0): " << L1MatchingdR_;
}
LogDebug("HLTMuonL3PreFilter") << " CandTag/MinN/MaxEta/MinNhits/MaxDr/MinDr/MaxDz/MinDxySig/MinPt/NSigmaPt : "
<< candTag_.encode() << " " << min_N_ << " " << max_Eta_ << " " << min_Nhits_ << " "
<< max_Dr_ << " " << min_Dr_ << " " << max_Dz_ << " " << min_DxySig_ << " " << min_Pt_
Expand Down Expand Up @@ -113,6 +119,7 @@ void HLTMuonL3PreFilter::fillDescriptions(edm::ConfigurationDescriptions& descri
desc.add<double>("L1MatchingdR", 0.3);
desc.add<bool>("MatchToPreviousCand", true);
desc.add<edm::InputTag>("InputLinks", edm::InputTag(""));
PropagateToMuonSetup::fillPSetDescription(desc);
descriptions.add("hltMuonL3PreFilter", desc);
}

Expand All @@ -128,6 +135,8 @@ bool HLTMuonL3PreFilter::hltFilter(Event& iEvent,
// recording any reconstructed physics objects satisfying (or not)
// this HLT filter, and place it in the Event.

auto const prop = propSetup_.init(iSetup);

if (saveTags())
filterproduct.addCollectionTag(candTag_);

Expand Down Expand Up @@ -224,11 +233,14 @@ bool HLTMuonL3PreFilter::hltFilter(Event& iEvent,
} //MTL loop

if (!l1CandTag_.label().empty() && check_l1match) {
auto const propagated = prop.extrapolate(*tk);
auto const etaForMatch = propagated.isValid() ? propagated.globalPosition().eta() : cand->eta();
auto const phiForMatch = propagated.isValid() ? (double)propagated.globalPosition().phi() : cand->phi();
iEvent.getByToken(l1CandToken_, level1Cands);
level1Cands->getObjects(trigger::TriggerL1Mu, vl1cands);
const unsigned int nL1Muons(vl1cands.size());
for (unsigned int il1 = 0; il1 != nL1Muons; ++il1) {
if (deltaR(cand->eta(), cand->phi(), vl1cands[il1]->eta(), vl1cands[il1]->phi()) < L1MatchingdR_) {
if (deltaR2(etaForMatch, phiForMatch, vl1cands[il1]->eta(), vl1cands[il1]->phi()) < L1MatchingdR2_) {
MuonToL3s[i] = RecoChargedCandidateRef(cand);
}
}
Expand Down
3 changes: 3 additions & 0 deletions HLTrigger/Muon/plugins/HLTMuonL3PreFilter.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
#include "DataFormats/RecoCandidate/interface/RecoChargedCandidateFwd.h"
#include "FWCore/ParameterSet/interface/ConfigurationDescriptions.h"
#include "FWCore/ParameterSet/interface/ParameterSetDescription.h"
#include "MuonAnalysis/MuonAssociators/interface/PropagateToMuonSetup.h"

class HLTMuonL3PreFilter : public HLTFilter {
public:
Expand All @@ -38,6 +39,7 @@ class HLTMuonL3PreFilter : public HLTFilter {
bool triggeredByLevel2(const reco::TrackRef& track, std::vector<reco::RecoChargedCandidateRef>& vcands) const;
bool applySelection(const reco::RecoChargedCandidateRef&, const reco::BeamSpot&) const;

const PropagateToMuonSetup propSetup_;
const edm::InputTag beamspotTag_;
const edm::EDGetTokenT<reco::BeamSpot> beamspotToken_;
const edm::InputTag candTag_; // input tag identifying product contains muons
Expand Down Expand Up @@ -73,6 +75,7 @@ class HLTMuonL3PreFilter : public HLTFilter {
double maxNormalizedChi2_L3fromL1_;
muon::SelectionType trkMuonId_;
const double L1MatchingdR_;
const double L1MatchingdR2_;
const bool matchPreviousCand_;

const bool devDebug_;
Expand Down
61 changes: 42 additions & 19 deletions HLTrigger/Muon/plugins/HLTMuonTrkFilter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -27,23 +27,31 @@

#include "DataFormats/Math/interface/deltaR.h"

HLTMuonTrkFilter::HLTMuonTrkFilter(const edm::ParameterSet& iConfig) : HLTFilter(iConfig) {
m_muonsTag = iConfig.getParameter<edm::InputTag>("inputMuonCollection");
m_muonsToken = consumes<reco::MuonCollection>(m_muonsTag);
m_candsTag = iConfig.getParameter<edm::InputTag>("inputCandCollection");
m_candsToken = consumes<reco::RecoChargedCandidateCollection>(m_candsTag);
m_previousCandTag = iConfig.getParameter<edm::InputTag>("previousCandTag");
m_previousCandToken = consumes<trigger::TriggerFilterObjectWithRefs>(m_previousCandTag);
m_minTrkHits = iConfig.getParameter<int>("minTrkHits");
m_minMuonHits = iConfig.getParameter<int>("minMuonHits");
m_minMuonStations = iConfig.getParameter<int>("minMuonStations");
m_maxNormalizedChi2 = iConfig.getParameter<double>("maxNormalizedChi2");
m_allowedTypeMask = iConfig.getParameter<unsigned int>("allowedTypeMask");
m_requiredTypeMask = iConfig.getParameter<unsigned int>("requiredTypeMask");
m_trkMuonId = muon::SelectionType(iConfig.getParameter<unsigned int>("trkMuonId"));
m_minPt = iConfig.getParameter<double>("minPt");
m_minN = iConfig.getParameter<unsigned int>("minN");
m_maxAbsEta = iConfig.getParameter<double>("maxAbsEta");
HLTMuonTrkFilter::HLTMuonTrkFilter(const edm::ParameterSet& iConfig)
: HLTFilter(iConfig),
propSetup_(iConfig, consumesCollector()),
m_muonsTag(iConfig.getParameter<edm::InputTag>("inputMuonCollection")),
m_muonsToken(consumes<reco::MuonCollection>(m_muonsTag)),
m_candsTag(iConfig.getParameter<edm::InputTag>("inputCandCollection")),
m_candsToken(consumes<reco::RecoChargedCandidateCollection>(m_candsTag)),
m_previousCandTag(iConfig.getParameter<edm::InputTag>("previousCandTag")),
m_previousCandToken(consumes<trigger::TriggerFilterObjectWithRefs>(m_previousCandTag)),
m_minTrkHits(iConfig.getParameter<int>("minTrkHits")),
m_minMuonHits(iConfig.getParameter<int>("minMuonHits")),
m_minMuonStations(iConfig.getParameter<int>("minMuonStations")),
m_maxNormalizedChi2(iConfig.getParameter<double>("maxNormalizedChi2")),
m_allowedTypeMask(iConfig.getParameter<unsigned int>("allowedTypeMask")),
m_requiredTypeMask(iConfig.getParameter<unsigned int>("requiredTypeMask")),
m_trkMuonId(muon::SelectionType(iConfig.getParameter<unsigned int>("trkMuonId"))),
m_minPt(iConfig.getParameter<double>("minPt")),
m_minN(iConfig.getParameter<unsigned int>("minN")),
m_maxAbsEta(iConfig.getParameter<double>("maxAbsEta")),
m_l1MatchingdR(iConfig.getParameter<double>("L1MatchingdR")),
m_l1MatchingdR2(m_l1MatchingdR * m_l1MatchingdR) {
if (m_l1MatchingdR <= 0.) {
throw cms::Exception("HLTMuonTrkFilterConfiguration")
<< "invalid value for parameter \"L1MatchingdR\" (must be > 0): " << m_l1MatchingdR;
}
}

void HLTMuonTrkFilter::fillDescriptions(edm::ConfigurationDescriptions& descriptions) {
Expand All @@ -62,12 +70,16 @@ void HLTMuonTrkFilter::fillDescriptions(edm::ConfigurationDescriptions& descript
desc.add<double>("minPt", 24);
desc.add<unsigned int>("minN", 1);
desc.add<double>("maxAbsEta", 1e99);
desc.add<double>("L1MatchingdR", 0.3);
PropagateToMuonSetup::fillPSetDescription(desc);
descriptions.add("hltMuonTrkFilter", desc);
}

bool HLTMuonTrkFilter::hltFilter(edm::Event& iEvent,
const edm::EventSetup& iSetup,
trigger::TriggerFilterObjectWithRefs& filterproduct) const {
auto const prop = propSetup_.init(iSetup);

edm::Handle<reco::MuonCollection> muons;
iEvent.getByToken(m_muonsToken, muons);
edm::Handle<reco::RecoChargedCandidateCollection> cands;
Expand Down Expand Up @@ -96,11 +108,22 @@ bool HLTMuonTrkFilter::hltFilter(edm::Event& iEvent,
std::vector<unsigned int> filteredMuons;
for (unsigned int i = 0; i < muons->size(); ++i) {
const reco::Muon& muon(muons->at(i));
// check for dR match to L1 muons
if (check_l1match) {
const reco::RecoChargedCandidateRef cand(cands, i);
const reco::TrackRef tk = cand->track();
auto etaForMatch = cand->eta();
auto phiForMatch = cand->phi();
// check for dR match to L1 muons
if (tk.isNonnull()) {
auto const propagated = prop.extrapolate(*tk);
if (propagated.isValid()) {
etaForMatch = propagated.globalPosition().eta();
phiForMatch = propagated.globalPosition().phi();
}
}
bool matchl1 = false;
for (auto l1cand = vl1cands_begin; l1cand != vl1cands_end; ++l1cand) {
if (deltaR(muon, **l1cand) < 0.3) {
if (deltaR2(etaForMatch, phiForMatch, (*l1cand)->eta(), (*l1cand)->phi()) < m_l1MatchingdR2) {
matchl1 = true;
break;
}
Expand Down
Loading