54 edm::LogVerbatim(
"MuonAssociatorByHits")<<
"\n"<<
"reco::Track collection --- size = "<<tC.size();
58 edm::LogVerbatim(
"MuonAssociatorByHits")<<
"\n"<<
"TrackingParticle collection --- size = "<<tPC.size();
60 for(TrackingParticleCollection::const_iterator ITER=tPC.begin(); ITER!=tPC.end(); ITER++, j++) {
62 <<
"TrackingParticle "<<j<<
", q = "<<ITER->charge()<<
", p = "<<ITER->p()
63 <<
", pT = "<<ITER->pt()<<
", eta = "<<ITER->eta()<<
", phi = "<<ITER->phi();
66 <<
"\t pdg code = "<<ITER->pdgId()<<
", made of "<<ITER->numberOfHits()<<
" PSimHit" 67 <<
" (in "<<ITER->numberOfTrackerLayers()<<
" layers)" 68 <<
" from "<<ITER->g4Tracks().size()<<
" SimTrack:";
71 <<
"\t\t Id:"<<g4T->trackId()<<
"/Evt:("<<g4T->eventId().event()<<
","<<g4T->eventId().bunchCrossing()<<
")";
87 <<
" has size = "<<SimTk->size();
92 <<
" - Id:"<<ITER->trackId()<<
"/Evt:("<<ITER->eventId().event()<<
","<<ITER->eventId().bunchCrossing()<<
")" 93 <<
" pdgId = "<<ITER->type()<<
", q = "<<ITER->charge()<<
", p = "<<ITER->momentum().P()
94 <<
", pT = "<<ITER->momentum().Pt()<<
", eta = "<<ITER->momentum().Eta()<<
", phi = "<<ITER->momentum().Phi()
95 <<
"\n * "<<*ITER <<endl;
100 <<
" has size = "<<SimVtx->size();
105 <<
" : "<< *VITER <<endl;
112 <<
" has size = "<<simTC.size()<<endl;
114 for(edm::SimTrackContainer::const_iterator ITER=simTC.begin(); ITER!=simTC.end(); ITER++, k++){
117 <<
" - Id:"<<ITER->trackId()<<
"/Evt:("<<ITER->eventId().event()<<
","<<ITER->eventId().bunchCrossing()<<
")" 118 <<
" pdgId = "<<ITER->type()<<
", q = "<<ITER->charge()<<
", p = "<<ITER->momentum().P()
119 <<
", pT = "<<ITER->momentum().Pt()<<
", eta = "<<ITER->momentum().Eta()<<
", phi = "<<ITER->momentum().Phi()
120 <<
"\n * "<<*ITER <<endl;
124 edm::LogVerbatim(
"MuonAssociatorByHits")<<
"\n"<<
"SimVertex collection with InputTag = "<<
"g4SimHits" 125 <<
" has size = "<<simVC.size()<<endl;
127 for (edm::SimVertexContainer::const_iterator VITER=simVC.begin(); VITER!=simVC.end(); VITER++, kv++){
130 <<
" : "<< *VITER <<endl;
141 trackerHitAssociatorConfig_(conf,
std::
move(iC))
166 for (
auto it = tC.
begin(), ed = tC.
end(); it != ed; ++it) {
167 tH.push_back(std::make_pair((*it)->recHitsBegin(), (*it)->recHitsEnd()));
197 for (
auto it = bareAssoc.begin(), ed = bareAssoc.end(); it != ed; ++it) {
198 for (
auto itma = it->second.begin(), edma = it->second.end(); itma != edma; ++itma) {
199 outputCollection.insert(tC[it->first], std::make_pair(TPCollectionH[itma->idx], itma->quality));
203 outputCollection.post_insert();
204 return outputCollection;
214 for (
auto it = tC.
begin(), ed = tC.
end(); it != ed; ++it) {
215 tH.push_back(std::make_pair((*it)->recHitsBegin(), (*it)->recHitsEnd()));
228 bool printRtS =
false;
238 for (
auto it = bareAssoc.begin(), ed = bareAssoc.end(); it != ed; ++it) {
239 for (
auto itma = it->second.begin(), edma = it->second.end(); itma != edma; ++itma) {
240 outputCollection.insert(TPCollectionH[ it->first],
241 std::make_pair(tC[itma->idx], itma->quality));
245 outputCollection.post_insert();
246 return outputCollection;
T getUntrackedParameter(std::string const &, T const &) const
edm::ParameterSet const conf_
MuonAssociatorByHits(const edm::ParameterSet &conf, edm::ConsumesCollector &&iC)
std::vector< TrackingParticle > TrackingParticleCollection
EDProductGetter const & productGetter() const
const_iterator end() const
def setup(process, global_tag, zero_tesla=False)
TrackerHitAssociator::Config trackerHitAssociatorConfig_
IndexAssociation associateSimToRecoIndices(const TrackHitsCollection &, const edm::RefVector< TrackingParticleCollection > &, Resources const &) const
std::unique_ptr< muonAssociatorByHitsDiagnostics::InputDumper > diagnostics_
std::vector< std::pair< trackingRecHit_iterator, trackingRecHit_iterator > > TrackHitsCollection
std::function< void(const TrackHitsCollection &, const TrackingParticleCollection &)> diagnostics_
MuonAssociatorByHitsHelper::TrackHitsCollection TrackHitsCollection
std::vector< SimTrack >::const_iterator g4t_iterator
reco::RecoToSimCollection associateRecoToSim(edm::Handle< edm::View< reco::Track > > &tCH, edm::Handle< TrackingParticleCollection > &tPCH, const edm::Event *event, const edm::EventSetup *setup) const
T const * product() const
std::vector< SimVertex > SimVertexContainer
const_iterator begin() const
IndexAssociation associateRecoToSimIndices(const TrackHitsCollection &, const edm::RefVector< TrackingParticleCollection > &, Resources const &) const
virtual reco::SimToRecoCollection associateSimToReco(edm::Handle< edm::View< reco::Track > > &tCH, edm::Handle< TrackingParticleCollection > &tPCH, const edm::Event *event, const edm::EventSetup *setup) const
MuonAssociatorByHitsHelper helper_
T const * product() const
std::vector< SimTrack > SimTrackContainer