13 edm::LogVerbatim(
"MuonAssociatorEDProducer") <<
"constructing MuonAssociatorEDProducer";
14 produces<reco::RecoToSimCollection>();
15 produces<reco::SimToRecoCollection>();
23 LogTrace(
"MuonAssociatorEDProducer") <<
"constructing MuonAssociatorByHits" <<
parset_.
dump();
24 edm::LogVerbatim(
"MuonAssociatorEDProducer") <<
"\n MuonAssociatorByHits will associate reco::Tracks with " 30 if (recoTracksLabel ==
"seedsOfSTAmuons" || recoTracksLabel ==
"standAloneMuons" ||
31 recoTracksLabel ==
"refittedStandAloneMuons" || recoTracksLabel ==
"seedsOfDisplacedSTAmuons" ||
32 recoTracksLabel ==
"displacedStandAloneMuons" || recoTracksLabel ==
"cosmicMuons" ||
33 recoTracksLabel ==
"cosmicMuons1Leg" || recoTracksLabel ==
"hltL2Muons") {
36 <<
"\n*** WARNING : inconsistent input tracksTag = " <<
tracksTag <<
"\n with UseTracker = true" 37 <<
"\n ---> setting UseTracker = false ";
42 <<
"\n*** WARNING : inconsistent input tracksTag = " <<
tracksTag <<
"\n with UseMuon = false" 43 <<
"\n ---> setting UseMuon = true ";
48 if (recoTracksLabel ==
"generalTracks" || recoTracksLabel ==
"probeTracks" || recoTracksLabel ==
"displacedTracks" ||
49 recoTracksLabel ==
"extractGemMuons" || recoTracksLabel ==
"extractMe0Muons" ||
50 recoTracksLabel ==
"ctfWithMaterialTracksP5LHCNavigation" || recoTracksLabel ==
"ctfWithMaterialTracksP5" ||
51 recoTracksLabel ==
"hltIterL3OIMuonTrackSelectionHighPurity" || recoTracksLabel ==
"hltIterL3MuonMerged" ||
52 recoTracksLabel ==
"hltIterL3MuonAndMuonFromL1Merged") {
55 <<
"\n*** WARNING : inconsistent input tracksTag = " <<
tracksTag <<
"\n with UseMuon = true" 56 <<
"\n ---> setting UseMuon = false ";
61 <<
"\n*** WARNING : inconsistent input tracksTag = " <<
tracksTag <<
"\n with UseTracker = false" 62 <<
"\n ---> setting UseTracker = true ";
67 LogTrace(
"MuonAssociatorEDProducer") <<
"MuonAssociatorEDProducer::beginJob " 68 ": constructing MuonAssociatorByHits";
88 tmpTPptr = TPCollectionRefVector.
product();
94 for (
size_t i = 0;
i < nTP; ++
i) {
100 LogTrace(
"MuonAssociatorEDProducer") <<
"getting TrackingParticle collection - " <<
tpTag;
101 LogTrace(
"MuonAssociatorEDProducer") <<
"\t... size = " << tmpTPptr->
size();
104 LogTrace(
"MuonAssociatorEDProducer") <<
"getting reco::Track collection - " <<
tracksTag;
109 LogTrace(
"MuonAssociatorEDProducer") <<
"\t... NOT FOUND.";
111 std::unique_ptr<reco::RecoToSimCollection> rts;
112 std::unique_ptr<reco::SimToRecoCollection>
str;
118 LogTrace(
"MuonAssociatorEDProducer") <<
"\n ignoring missing track collection." 126 <<
"\n >>> RecoToSim association <<< \n" 130 <<
" (size = " << tmpTPptr->
size() <<
")";
135 <<
"\n >>> SimToReco association <<< \n" 137 <<
" (size = " << tmpTPptr->
size() <<
") \n" 143 rts = std::make_unique<reco::RecoToSimCollection>(recSimColl);
144 str = std::make_unique<reco::SimToRecoCollection>(simRecColl);
edm::ParameterSet parset_
Log< level::Info, true > LogVerbatim
edm::EDGetTokenT< TrackingParticleCollection > tpToken_
reco::RecoToSimCollection associateRecoToSim(edm::Handle< edm::View< reco::Track >> &tCH, edm::Handle< TrackingParticleCollection > &tPCH, const edm::Event *event, const edm::EventSetup *setup) const
T getParameter(std::string const &) const
MuonAssociatorEDProducer(const edm::ParameterSet &)
~MuonAssociatorEDProducer() override
edm::EDGetTokenT< TrackingParticleRefVector > tpRefVectorToken_
T const * product() const
ignoreMissingTrackCollection
void produce(edm::Event &, const edm::EventSetup &) override
MuonAssociatorByHits * associatorByHits
virtual reco::SimToRecoCollection associateSimToReco(edm::Handle< edm::View< reco::Track >> &tCH, edm::Handle< TrackingParticleCollection > &tPCH, const edm::Event *event, const edm::EventSetup *setup) const
void addParameter(std::string const &name, T const &value)
size_type size() const
Size of the RefVector.
edm::EDGetTokenT< edm::View< reco::Track > > tracksToken_
void push_back(const RefToBase< T > &)
std::string dump(unsigned int indent=0) const
void push_back(value_type const &ref)
Add a Ref<C, T> to the RefVector.
Log< level::Warning, false > LogWarning
std::vector< TPEntry > TPCollection
bool ignoreMissingTrackCollection
edm::Ref< TrackingParticleCollection > TrackingParticleRef