CMS 3D CMS Logo

List of all members | Classes | Public Types | Public Member Functions | Public Attributes | Private Types | Private Member Functions | Private Attributes
TrackerHitAssociator Class Reference

#include <TrackerHitAssociator.h>

Classes

struct  Config
 

Public Types

typedef std::map< subDetTofBin, unsigned int > simhit_collectionMap
 
typedef std::map< unsigned int, std::vector< PSimHit > > simhit_map
 
typedef std::pair< unsigned int, unsigned int > simhitAddr
 
typedef unsigned int simHitCollectionID
 
typedef std::pair< unsigned int, unsigned int > subDetTofBin
 

Public Member Functions

void associateCluster (const SiStripCluster *clust, const DetId &detid, std::vector< SimHitIdpr > &simtrackid, std::vector< PSimHit > &simhit) const
 
std::vector< SimHitIdprassociateFastRecHit (const FastTrackerRecHit *rechit) const
 
std::vector< PSimHitassociateHit (const TrackingRecHit &thit) const
 
std::vector< SimHitIdprassociateHitId (const TrackingRecHit &thit) const
 
void associateHitId (const TrackingRecHit &thit, std::vector< SimHitIdpr > &simhitid, std::vector< simhitAddr > *simhitCFPos=nullptr) const
 
std::vector< SimHitIdprassociateMatchedRecHit (const SiStripMatchedRecHit2D *matchedrechit, std::vector< simhitAddr > *simhitCFPos=nullptr) const
 
std::vector< PSimHitassociateMultiRecHit (const SiTrackerMultiRecHit *multirechit) const
 
std::vector< SimHitIdprassociateMultiRecHitId (const SiTrackerMultiRecHit *multirechit, std::vector< simhitAddr > *simhitCFPos=nullptr) const
 
void associatePhase2TrackerRecHit (const Phase2TrackerRecHit1D *rechit, std::vector< SimHitIdpr > &simtrackid, std::vector< simhitAddr > *simhitCFPos=nullptr) const
 
void associatePixelRecHit (const SiPixelRecHit *pixelrechit, std::vector< SimHitIdpr > &simtrackid, std::vector< simhitAddr > *simhitCFPos=nullptr) const
 
std::vector< SimHitIdprassociateProjectedRecHit (const ProjectedSiStripRecHit2D *projectedrechit, std::vector< simhitAddr > *simhitCFPos=nullptr) const
 
void associateSimpleRecHitCluster (const SiStripCluster *clust, const DetId &detid, std::vector< SimHitIdpr > &simtrackid, std::vector< simhitAddr > *simhitCFPos=nullptr) const
 
template<typename T >
void associateSiStripRecHit (const T *simplerechit, std::vector< SimHitIdpr > &simtrackid, std::vector< simhitAddr > *simhitCFPos=nullptr) const
 
 TrackerHitAssociator (const edm::Event &e, const Config &config)
 
virtual ~TrackerHitAssociator ()
 

Public Attributes

simhit_collectionMap SimHitCollMap
 
simhit_map SimHitMap
 

Private Types

typedef std::vector< std::string > vstring
 

Private Member Functions

void makeMaps (const edm::Event &theEvent, const Config &config)
 
std::string printDetBnchEvtTrk (const DetId &detid, const uint32_t &detID, std::vector< SimHitIdpr > &simtrackid) const
 

Private Attributes

bool assocHitbySimTrack_
 
bool doPixel_
 
bool doStrip_
 
bool doTrackAssoc_
 
edm::Handle< edm::DetSetVector< PixelDigiSimLink > > ph2trackerdigisimlink
 
edm::Handle< edm::DetSetVector< PixelDigiSimLink > > pixeldigisimlink
 
edm::Handle< edm::DetSetVector< StripDigiSimLink > > stripdigisimlink
 
bool useOTph2_
 

Detailed Description

Definition at line 55 of file TrackerHitAssociator.h.

Member Typedef Documentation

◆ simhit_collectionMap

Definition at line 117 of file TrackerHitAssociator.h.

◆ simhit_map

typedef std::map<unsigned int, std::vector<PSimHit> > TrackerHitAssociator::simhit_map

Definition at line 115 of file TrackerHitAssociator.h.

◆ simhitAddr

typedef std::pair<unsigned int, unsigned int> TrackerHitAssociator::simhitAddr

Definition at line 74 of file TrackerHitAssociator.h.

◆ simHitCollectionID

Definition at line 75 of file TrackerHitAssociator.h.

◆ subDetTofBin

typedef std::pair<unsigned int, unsigned int> TrackerHitAssociator::subDetTofBin

Definition at line 74 of file TrackerHitAssociator.h.

◆ vstring

typedef std::vector<std::string> TrackerHitAssociator::vstring
private

Definition at line 121 of file TrackerHitAssociator.h.

Constructor & Destructor Documentation

◆ TrackerHitAssociator()

TrackerHitAssociator::TrackerHitAssociator ( const edm::Event e,
const Config config 
)

Definition at line 103 of file TrackerHitAssociator.cc.

104  : doPixel_(config.doPixel_),
105  doStrip_(config.doStrip_),
106  useOTph2_(config.useOTph2_),
107  doTrackAssoc_(config.doTrackAssoc_),
108  assocHitbySimTrack_(config.assocHitbySimTrack_) {
109  //if track association there is no need to access the input collections
110  if (!doTrackAssoc_) {
111  makeMaps(e, config);
112  }
113 
114  if (doStrip_) {
115  if (useOTph2_)
116  e.getByToken(config.ph2OTrToken_, ph2trackerdigisimlink);
117  else
118  e.getByToken(config.stripToken_, stripdigisimlink);
119  }
120  if (doPixel_)
121  e.getByToken(config.pixelToken_, pixeldigisimlink);
122 }

References doPixel_, doStrip_, doTrackAssoc_, MillePedeFileConverter_cfg::e, makeMaps(), ph2trackerdigisimlink, pixeldigisimlink, stripdigisimlink, and useOTph2_.

◆ ~TrackerHitAssociator()

virtual TrackerHitAssociator::~TrackerHitAssociator ( )
inlinevirtual

Definition at line 72 of file TrackerHitAssociator.h.

72 {}

Member Function Documentation

◆ associateCluster()

void TrackerHitAssociator::associateCluster ( const SiStripCluster clust,
const DetId detid,
std::vector< SimHitIdpr > &  simtrackid,
std::vector< PSimHit > &  simhit 
) const

Definition at line 386 of file TrackerHitAssociator.cc.

389  {
390  std::vector<simhitAddr> simhitCFPos;
391  associateSimpleRecHitCluster(clust, detid, simtrackid, &simhitCFPos);
392 
393  for (auto const& theSimHitAddr : simhitCFPos) {
394  simHitCollectionID theSimHitCollID = theSimHitAddr.first;
395  auto it = SimHitMap.find(theSimHitCollID);
396 
397  if (it != SimHitMap.end()) {
398  unsigned int theSimHitIndex = theSimHitAddr.second;
399  if (theSimHitIndex < (it->second).size())
400  simhit.push_back((it->second)[theSimHitIndex]);
401  LogDebug("TrkHitAssocTrace") << "For cluster, simHit detId = " << (it->second)[theSimHitIndex].detUnitId()
402  << " address = (" << theSimHitCollID << ", " << theSimHitIndex
403  << "), process = " << (it->second)[theSimHitIndex].processType()
404  << " (bnch, evt, trk) = (" << (it->second)[theSimHitIndex].eventId().bunchCrossing()
405  << ", " << (it->second)[theSimHitIndex].eventId().event() << ", "
406  << (it->second)[theSimHitIndex].trackId() << ")" << std::endl;
407  }
408  }
409 }

References associateSimpleRecHitCluster(), LogDebug, and SimHitMap.

◆ associateFastRecHit()

std::vector< SimHitIdpr > TrackerHitAssociator::associateFastRecHit ( const FastTrackerRecHit rechit) const

Definition at line 656 of file TrackerHitAssociator.cc.

656  {
657  vector<SimHitIdpr> simtrackid;
658  simtrackid.clear();
659  for (size_t index = 0, indexEnd = rechit->nSimTrackIds(); index < indexEnd; ++index) {
660  SimHitIdpr currentId(rechit->simTrackId(index), EncodedEventId(rechit->simTrackEventId(index)));
661  simtrackid.push_back(currentId);
662  }
663  return simtrackid;
664 }

References FastTrackerRecHit::nSimTrackIds(), FastTrackerRecHit::simTrackEventId(), and FastTrackerRecHit::simTrackId().

Referenced by associateHitId().

◆ associateHit()

std::vector< PSimHit > TrackerHitAssociator::associateHit ( const TrackingRecHit thit) const

Check if it's the gluedDet.

Definition at line 212 of file TrackerHitAssociator.cc.

212  {
213  if (const SiTrackerMultiRecHit* rechit = dynamic_cast<const SiTrackerMultiRecHit*>(&thit)) {
214  return associateMultiRecHit(rechit);
215  }
216 
217  //vector with the matched SimHit
218  std::vector<PSimHit> result;
219 
220  if (doTrackAssoc_)
221  return result; // We don't want the SimHits for this RecHit
222 
223  // Vectors to contain lists of matched simTracks, simHits
224  std::vector<SimHitIdpr> simtrackid;
225  std::vector<simhitAddr> simhitCFPos;
226 
227  //get the Detector type of the rechit
228  DetId detid = thit.geographicalId();
229  uint32_t detID = detid.rawId();
230 
231  // Get the vectors of simtrackIDs and simHit addresses associated with this rechit
232  associateHitId(thit, simtrackid, &simhitCFPos);
233  LogDebug("TrkHitAssocTrace") << printDetBnchEvtTrk(detid, detID, simtrackid);
234 
235  // Get the vector of simHits associated with this rechit
236  if (!assocHitbySimTrack_ && !simhitCFPos.empty()) {
237  // We use the indices to the simHit collections taken
238  // from the DigiSimLinks and returned in simhitCFPos.
239  // simhitCFPos[i] contains the full address of the ith simhit:
240  // <collection index, simhit index>
241 
242  //check if the recHit is a SiStripMatchedRecHit2D
243  if (dynamic_cast<const SiStripMatchedRecHit2D*>(&thit)) {
244  for (auto const& theSimHitAddr : simhitCFPos) {
245  simHitCollectionID theSimHitCollID = theSimHitAddr.first;
246  auto it = SimHitMap.find(theSimHitCollID);
247  if (it != SimHitMap.end()) {
248  unsigned int theSimHitIndex = theSimHitAddr.second;
249  if (theSimHitIndex < (it->second).size()) {
250  const PSimHit& theSimHit = (it->second)[theSimHitIndex];
251  // Try to remove ghosts by requiring a match to the simTrack also
252  unsigned int simHitid = theSimHit.trackId();
253  EncodedEventId simHiteid = theSimHit.eventId();
254  for (auto const& id : simtrackid) {
255  if (simHitid == id.first && simHiteid == id.second) {
256  result.push_back(theSimHit);
257  }
258  }
259  LogDebug("TrkHitAssocTrace") << "by CFpos, simHit detId = " << theSimHit.detUnitId() << " address = ("
260  << theSimHitAddr.first << ", " << theSimHitIndex
261  << "), process = " << theSimHit.processType() << " ("
262  << theSimHit.eventId().bunchCrossing() << ", " << theSimHit.eventId().event()
263  << ", " << theSimHit.trackId() << ")" << std::endl;
264  }
265  }
266  }
267  } else { // Not a SiStripMatchedRecHit2D
268  for (auto const& theSimHitAddr : simhitCFPos) {
269  simHitCollectionID theSimHitCollID = theSimHitAddr.first;
270  auto it = SimHitMap.find(theSimHitCollID);
271  if (it != SimHitMap.end()) {
272  unsigned int theSimHitIndex = theSimHitAddr.second;
273  if (theSimHitIndex < (it->second).size()) {
274  result.push_back((it->second)[theSimHitIndex]);
275  LogDebug("TrkHitAssocTrace") << "by CFpos, simHit detId = " << (it->second)[theSimHitIndex].detUnitId()
276  << " address = (" << theSimHitCollID << ", " << theSimHitIndex
277  << "), process = " << (it->second)[theSimHitIndex].processType() << " ("
278  << (it->second)[theSimHitIndex].eventId().bunchCrossing() << ", "
279  << (it->second)[theSimHitIndex].eventId().event() << ", "
280  << (it->second)[theSimHitIndex].trackId() << ")" << std::endl;
281  }
282  }
283  }
284  }
285  return result;
286  } // if !assocHitbySimTrack
287 
288  // Get the SimHit from the trackid instead
289  auto it = SimHitMap.find(detID);
290  if (it != SimHitMap.end()) {
291  for (auto const& ihit : it->second) {
292  unsigned int simHitid = ihit.trackId();
293  EncodedEventId simHiteid = ihit.eventId();
294  for (auto id : simtrackid) {
295  if (simHitid == id.first && simHiteid == id.second) {
296  result.push_back(ihit);
297  LogDebug("TrkHitAssocTrace") << "by TrackID, simHit detId = " << ihit.detUnitId()
298  << ", process = " << ihit.processType() << " (" << ihit.eventId().bunchCrossing()
299  << ", " << ihit.eventId().event() << ", " << ihit.trackId() << ")" << std::endl;
300  break;
301  }
302  }
303  }
304 
305  } else {
307  auto itrphi = SimHitMap.find(detID + 2); //iterator to the simhit in the rphi module
308  auto itster = SimHitMap.find(detID + 1); //iterator to the simhit in the stereo module
309  if (itrphi != SimHitMap.end() && itster != SimHitMap.end()) {
310  std::vector<PSimHit> simHitVector = itrphi->second;
311  simHitVector.insert(simHitVector.end(), (itster->second).begin(), (itster->second).end());
312  for (auto const& ihit : simHitVector) {
313  unsigned int simHitid = ihit.trackId();
314  EncodedEventId simHiteid = ihit.eventId();
315  for (auto const& id : simtrackid) {
316  if (simHitid == id.first && simHiteid == id.second) {
317  result.push_back(ihit);
318  LogDebug("TrkHitAssocTrace") << "by TrackID, simHit detId = " << ihit.detUnitId()
319  << ", process = " << ihit.processType() << " ("
320  << ihit.eventId().bunchCrossing() << ", " << ihit.eventId().event() << ", "
321  << ihit.trackId() << ")" << std::endl;
322  break;
323  }
324  }
325  }
326  }
327  }
328 
329  return result;
330 }

References assocHitbySimTrack_, associateHitId(), associateMultiRecHit(), EncodedEventId::bunchCrossing(), PSimHit::detUnitId(), doTrackAssoc_, mps_fire::end, EncodedEventId::event(), PSimHit::eventId(), first, TrackingRecHit::geographicalId(), LogDebug, printDetBnchEvtTrk(), PSimHit::processType(), DetId::rawId(), mps_fire::result, edm::second(), SimHitMap, and PSimHit::trackId().

Referenced by CkfDebugger::analyseCompatibleMeasurements(), SiPixelPhase1RecHitsV::analyze(), SiPixelRecHitsValid::analyze(), SiPixelErrorEstimation::analyze(), SiPixelTrackingRecHitsValid::analyze(), CkfDebugger::associated(), associateMultiRecHit(), PixelClusterShapeExtractor::checkSimHits(), CkfDebugger::correctTrajectory(), GlobalRecHitsAnalyzer::fillTrk(), GlobalRecHitsProducer::fillTrk(), spr::matchedSimTrack(), CkfDebugger::nextCorrectHits(), SiStripRecHitsValid::rechitanalysis(), SiStripTrackingRecHitsValid::rechitanalysis(), SiStripRecHitsValid::rechitanalysis_matched(), SiStripTrackingRecHitsValid::rechitanalysis_matched(), and CkfDebugger::testSeed().

◆ associateHitId() [1/2]

std::vector< SimHitIdpr > TrackerHitAssociator::associateHitId ( const TrackingRecHit thit) const

Definition at line 332 of file TrackerHitAssociator.cc.

332  {
333  std::vector<SimHitIdpr> simhitid;
334  associateHitId(thit, simhitid);
335  return simhitid;
336 }

Referenced by associateHit(), associateMultiRecHitId(), CkfDebugger::assocTrackId(), CkfDebugger::correctMeas(), CkfDebugger::correctTrajectory(), Phase2ITValidateRecHit::fillITHistos(), and MuonAssociatorByHitsHelper::getMatchedIds().

◆ associateHitId() [2/2]

void TrackerHitAssociator::associateHitId ( const TrackingRecHit thit,
std::vector< SimHitIdpr > &  simhitid,
std::vector< simhitAddr > *  simhitCFPos = nullptr 
) const

Definition at line 338 of file TrackerHitAssociator.cc.

340  {
341  simtkid.clear();
342 
343  if (const SiTrackerMultiRecHit* rechit = dynamic_cast<const SiTrackerMultiRecHit*>(&thit))
344  simtkid = associateMultiRecHitId(rechit, simhitCFPos);
345 
346  //check if it is a simple SiStripRecHit2D
347  if (const SiStripRecHit2D* rechit = dynamic_cast<const SiStripRecHit2D*>(&thit))
348  associateSiStripRecHit(rechit, simtkid, simhitCFPos);
349 
350  //check if it is a SiStripRecHit1D
351  else if (const SiStripRecHit1D* rechit = dynamic_cast<const SiStripRecHit1D*>(&thit))
352  associateSiStripRecHit(rechit, simtkid, simhitCFPos);
353 
354  //check if it is a SiStripMatchedRecHit2D
355  else if (const SiStripMatchedRecHit2D* rechit = dynamic_cast<const SiStripMatchedRecHit2D*>(&thit))
356  simtkid = associateMatchedRecHit(rechit, simhitCFPos);
357 
358  //check if it is a ProjectedSiStripRecHit2D
359  else if (const ProjectedSiStripRecHit2D* rechit = dynamic_cast<const ProjectedSiStripRecHit2D*>(&thit))
360  simtkid = associateProjectedRecHit(rechit, simhitCFPos);
361 
362  //check if it is a Phase2TrackerRecHit1D
363  else if (const Phase2TrackerRecHit1D* rechit = dynamic_cast<const Phase2TrackerRecHit1D*>(&thit))
364  associatePhase2TrackerRecHit(rechit, simtkid, simhitCFPos);
365 
366  //check if it is a SiPixelRecHit
367  else if (const SiPixelRecHit* rechit = dynamic_cast<const SiPixelRecHit*>(&thit))
368  associatePixelRecHit(rechit, simtkid, simhitCFPos);
369 
370  //check if these are GSRecHits (from FastSim)
371  if (trackerHitRTTI::isFast(thit))
372  simtkid = associateFastRecHit(static_cast<const FastTrackerRecHit*>(&thit));
373 }

References associateFastRecHit(), associateMatchedRecHit(), associateMultiRecHitId(), associatePhase2TrackerRecHit(), associatePixelRecHit(), associateProjectedRecHit(), associateSiStripRecHit(), and trackerHitRTTI::isFast().

◆ associateMatchedRecHit()

std::vector< SimHitIdpr > TrackerHitAssociator::associateMatchedRecHit ( const SiStripMatchedRecHit2D matchedrechit,
std::vector< simhitAddr > *  simhitCFPos = nullptr 
) const

Definition at line 471 of file TrackerHitAssociator.cc.

472  {
473  std::vector<SimHitIdpr> matched_mono;
474  std::vector<SimHitIdpr> matched_st;
475 
476  const SiStripRecHit2D mono = matchedrechit->monoHit();
477  const SiStripRecHit2D st = matchedrechit->stereoHit();
478  //associate the two simple hits separately
479  associateSiStripRecHit(&mono, matched_mono, simhitCFPos);
480  associateSiStripRecHit(&st, matched_st, simhitCFPos);
481 
482  //save in a vector all the simtrack-id's that are common to mono and stereo hits
483  std::vector<SimHitIdpr> simtrackid;
484  if (!(matched_mono.empty() || matched_st.empty())) {
485  for (auto const& mhit : matched_mono) {
486  //save only once the ID
487  if (find(simtrackid.begin(), simtrackid.end(), mhit) == simtrackid.end()) {
488  //save if the stereoID matched the monoID
489  if (find(matched_st.begin(), matched_st.end(), mhit) != matched_st.end()) {
490  simtrackid.push_back(mhit);
491  }
492  }
493  }
494  }
495  return simtrackid;
496 }

References associateSiStripRecHit(), spr::find(), SiStripMatchedRecHit2D::monoHit(), and SiStripMatchedRecHit2D::stereoHit().

Referenced by associateHitId().

◆ associateMultiRecHit()

std::vector< PSimHit > TrackerHitAssociator::associateMultiRecHit ( const SiTrackerMultiRecHit multirechit) const

Definition at line 627 of file TrackerHitAssociator.cc.

627  {
628  std::vector<const TrackingRecHit*> componenthits = multirechit->recHits();
629  // std::vector<PSimHit> assimhits;
630  int size = multirechit->weights().size(), idmostprobable = 0;
631 
632  for (int i = 0; i < size; ++i) {
633  if (multirechit->weight(i) > multirechit->weight(idmostprobable))
634  idmostprobable = i;
635  }
636 
637  return associateHit(*componenthits[idmostprobable]);
638 }

References associateHit(), mps_fire::i, SiTrackerMultiRecHit::recHits(), findQualityFiles::size, SiTrackerMultiRecHit::weight(), and SiTrackerMultiRecHit::weights().

Referenced by associateHit().

◆ associateMultiRecHitId()

std::vector< SimHitIdpr > TrackerHitAssociator::associateMultiRecHitId ( const SiTrackerMultiRecHit multirechit,
std::vector< simhitAddr > *  simhitCFPos = nullptr 
) const

Definition at line 640 of file TrackerHitAssociator.cc.

641  {
642  std::vector<const TrackingRecHit*> componenthits = multirechit->recHits();
643  int size = multirechit->weights().size(), idmostprobable = 0;
644 
645  for (int i = 0; i < size; ++i) {
646  if (multirechit->weight(i) > multirechit->weight(idmostprobable))
647  idmostprobable = i;
648  }
649 
650  std::vector<SimHitIdpr> simhitid;
651  associateHitId(*componenthits[idmostprobable], simhitid, simhitCFPos);
652  return simhitid;
653 }

References associateHitId(), mps_fire::i, SiTrackerMultiRecHit::recHits(), findQualityFiles::size, SiTrackerMultiRecHit::weight(), and SiTrackerMultiRecHit::weights().

Referenced by associateHitId().

◆ associatePhase2TrackerRecHit()

void TrackerHitAssociator::associatePhase2TrackerRecHit ( const Phase2TrackerRecHit1D rechit,
std::vector< SimHitIdpr > &  simtrackid,
std::vector< simhitAddr > *  simhitCFPos = nullptr 
) const

Definition at line 509 of file TrackerHitAssociator.cc.

511  {
512  //
513  // Phase 2 outer tracker associator
514  //
515  DetId detid = rechit->geographicalId();
516  uint32_t detID = detid.rawId();
517 
518  auto isearch = ph2trackerdigisimlink->find(detID);
519  if (isearch != ph2trackerdigisimlink->end()) { //if it is not empty
520  auto link_detset = (*isearch);
521  Phase2TrackerRecHit1D::CluRef const& cluster = rechit->cluster();
522 
523  //check the reference is valid
524  if (!(cluster.isNull())) { //if the cluster is valid
525  int minRow = (*cluster).firstStrip();
526  int maxRow = (*cluster).firstStrip() + (*cluster).size();
527  int Col = (*cluster).column();
528  LogDebug("TrkHitAssocDbg") << " Cluster minRow " << minRow << " maxRow " << maxRow << " column " << Col
529  << std::endl;
530  int dsl = 0;
531  for (auto const& linkiter : link_detset.data) {
532  ++dsl;
533  std::pair<int, int> coord = Phase2TrackerDigi::channelToPixel(linkiter.channel());
534  LogDebug("TrkHitAssocDbg") << " " << dsl << ") Digi link: row " << coord.first << " col " << coord.second
535  << std::endl;
536  if (coord.first <= maxRow && coord.first >= minRow && coord.second == Col) {
537  LogDebug("TrkHitAssocDbg") << " !-> trackid " << linkiter.SimTrackId() << endl
538  << " fraction " << linkiter.fraction() << endl;
539  SimHitIdpr currentId(linkiter.SimTrackId(), linkiter.eventId());
540  if (find(simtrackid.begin(), simtrackid.end(), currentId) == simtrackid.end()) {
541  simtrackid.push_back(currentId);
542  }
543 
544  if (simhitCFPos != nullptr) {
545  //create a vector that contains all the positions (in the MixCollection) of the SimHits that contributed to the RecHit
546  //write position only once
547  unsigned int currentCFPos = linkiter.CFposition();
548  unsigned int tofBin = linkiter.TofBin();
549  subDetTofBin theSubDetTofBin = std::make_pair(detid.subdetId(), tofBin);
550  auto it = SimHitCollMap.find(theSubDetTofBin);
551  if (it != SimHitCollMap.end()) {
552  simhitAddr currentAddr = std::make_pair(it->second, currentCFPos);
553  if (find(simhitCFPos->begin(), simhitCFPos->end(), currentAddr) == simhitCFPos->end()) {
554  simhitCFPos->push_back(currentAddr);
555  }
556  }
557  }
558  }
559  } // end of simlink loop
560  } else {
561  edm::LogError("TrackerHitAssociator") << "no Phase2 outer tracker cluster reference attached";
562  }
563  }
564 }

References Phase2TrackerDigi::channelToPixel(), Phase2TrackerRecHit1D::cluster(), spr::find(), TrackingRecHit::geographicalId(), edm::Ref< C, T, F >::isNull(), LogDebug, ph2trackerdigisimlink, DetId::rawId(), SimHitCollMap, and DetId::subdetId().

Referenced by associateHitId().

◆ associatePixelRecHit()

void TrackerHitAssociator::associatePixelRecHit ( const SiPixelRecHit pixelrechit,
std::vector< SimHitIdpr > &  simtrackid,
std::vector< simhitAddr > *  simhitCFPos = nullptr 
) const

Definition at line 566 of file TrackerHitAssociator.cc.

568  {
569  //
570  // Pixel associator
571  //
572  DetId detid = pixelrechit->geographicalId();
573  uint32_t detID = detid.rawId();
574 
575  auto isearch = pixeldigisimlink->find(detID);
576  if (isearch != pixeldigisimlink->end()) { //if it is not empty
577  auto link_detset = (*isearch);
578  SiPixelRecHit::ClusterRef const& cluster = pixelrechit->cluster();
579 
580  //check the reference is valid
581 
582  if (!(cluster.isNull())) { //if the cluster is valid
583 
584  int minPixelRow = (*cluster).minPixelRow();
585  int maxPixelRow = (*cluster).maxPixelRow();
586  int minPixelCol = (*cluster).minPixelCol();
587  int maxPixelCol = (*cluster).maxPixelCol();
588  LogDebug("TrkHitAssocDbg") << " Cluster minRow " << minPixelRow << " maxRow " << maxPixelRow << std::endl
589  << " Cluster minCol " << minPixelCol << " maxCol " << maxPixelCol << std::endl;
590  int dsl = 0;
591  for (auto const& linkiter : link_detset.data) {
592  ++dsl;
593  std::pair<int, int> pixel_coord = PixelDigi::channelToPixel(linkiter.channel());
594  LogDebug("TrkHitAssocDbg") << " " << dsl << ") Digi link: row " << pixel_coord.first << " col "
595  << pixel_coord.second << std::endl;
596  if (pixel_coord.first <= maxPixelRow && pixel_coord.first >= minPixelRow && pixel_coord.second <= maxPixelCol &&
597  pixel_coord.second >= minPixelCol) {
598  LogDebug("TrkHitAssocDbg") << " !-> trackid " << linkiter.SimTrackId() << endl
599  << " fraction " << linkiter.fraction() << endl;
600  SimHitIdpr currentId(linkiter.SimTrackId(), linkiter.eventId());
601  if (find(simtrackid.begin(), simtrackid.end(), currentId) == simtrackid.end()) {
602  simtrackid.push_back(currentId);
603  }
604 
605  if (simhitCFPos != nullptr) {
606  //create a vector that contains all the positions (in the MixCollection) of the SimHits that contributed to the RecHit
607  //write position only once
608  unsigned int currentCFPos = linkiter.CFposition();
609  unsigned int tofBin = linkiter.TofBin();
610  subDetTofBin theSubDetTofBin = std::make_pair(detid.subdetId(), tofBin);
611  auto it = SimHitCollMap.find(theSubDetTofBin);
612  if (it != SimHitCollMap.end()) {
613  simhitAddr currentAddr = std::make_pair(it->second, currentCFPos);
614  if (find(simhitCFPos->begin(), simhitCFPos->end(), currentAddr) == simhitCFPos->end()) {
615  simhitCFPos->push_back(currentAddr);
616  }
617  }
618  }
619  }
620  }
621  } else {
622  edm::LogError("TrackerHitAssociator") << "no Pixel cluster reference attached";
623  }
624  }
625 }

References PixelDigi::channelToPixel(), SiPixelRecHit::cluster(), spr::find(), TrackingRecHit::geographicalId(), edm::Ref< C, T, F >::isNull(), LogDebug, pixeldigisimlink, DetId::rawId(), SimHitCollMap, and DetId::subdetId().

Referenced by associateHitId().

◆ associateProjectedRecHit()

std::vector< SimHitIdpr > TrackerHitAssociator::associateProjectedRecHit ( const ProjectedSiStripRecHit2D projectedrechit,
std::vector< simhitAddr > *  simhitCFPos = nullptr 
) const

Definition at line 498 of file TrackerHitAssociator.cc.

499  {
500  //projectedRecHit is a "matched" rechit with only one component
501 
502  std::vector<SimHitIdpr> matched_mono;
503 
504  const SiStripRecHit2D mono = projectedrechit->originalHit();
505  associateSiStripRecHit(&mono, matched_mono, simhitCFPos);
506  return matched_mono;
507 }

References associateSiStripRecHit(), and ProjectedSiStripRecHit2D::originalHit().

Referenced by associateHitId().

◆ associateSimpleRecHitCluster()

void TrackerHitAssociator::associateSimpleRecHitCluster ( const SiStripCluster clust,
const DetId detid,
std::vector< SimHitIdpr > &  simtrackid,
std::vector< simhitAddr > *  simhitCFPos = nullptr 
) const

Definition at line 411 of file TrackerHitAssociator.cc.

414  {
415  uint32_t detID = detid.rawId();
416  auto isearch = stripdigisimlink->find(detID);
417  if (isearch != stripdigisimlink->end()) { //if it is not empty
418  auto link_detset = (*isearch);
419 
420  if (clust != nullptr) { //the cluster is valid
421  int clusiz = clust->amplitudes().size();
422  int first = clust->firstStrip();
423  int last = first + clusiz;
424 
425  LogDebug("TrkHitAssocDbg") << "Cluster size " << clusiz << " first strip = " << first
426  << " last strip = " << last - 1 << std::endl
427  << " detID = " << detID << " DETSET size = " << link_detset.data.size() << std::endl;
428  int channel;
429  for (const auto& linkiter : link_detset.data) {
430  channel = (int)(linkiter.channel());
431  if (channel >= first && channel < last) {
432  LogDebug("TrkHitAssocDbg") << "Channel = " << std::setw(4) << linkiter.channel()
433  << ", TrackID = " << std::setw(8) << linkiter.SimTrackId()
434  << ", tofBin = " << std::setw(3) << linkiter.TofBin()
435  << ", fraction = " << std::setw(8) << linkiter.fraction()
436  << ", Position = " << linkiter.CFposition() << std::endl;
437  SimHitIdpr currentId(linkiter.SimTrackId(), linkiter.eventId());
438 
439  //create a vector with the list of SimTrack ID's of the tracks that contributed to the RecHit
440  //write the id only once in the vector
441 
442  if (find(simtrackid.begin(), simtrackid.end(), currentId) == simtrackid.end()) {
443  LogDebug("TrkHitAssocDbg") << " Adding track id = " << currentId.first
444  << " Event id = " << currentId.second.event()
445  << " Bunch Xing = " << currentId.second.bunchCrossing() << std::endl;
446  simtrackid.push_back(currentId);
447  }
448 
449  if (simhitCFPos != nullptr) {
450  //create a vector that contains all the positions (in the MixCollection) of the SimHits that contributed to the RecHit
451  //write position only once
452  unsigned int currentCFPos = linkiter.CFposition();
453  unsigned int tofBin = linkiter.TofBin();
454  subDetTofBin theSubDetTofBin = std::make_pair(detid.subdetId(), tofBin);
455  auto it = SimHitCollMap.find(theSubDetTofBin);
456  if (it != SimHitCollMap.end()) {
457  simhitAddr currentAddr = std::make_pair(it->second, currentCFPos);
458  if (find(simhitCFPos->begin(), simhitCFPos->end(), currentAddr) == simhitCFPos->end()) {
459  simhitCFPos->push_back(currentAddr);
460  }
461  }
462  }
463  }
464  }
465  } else {
466  edm::LogError("TrackerHitAssociator") << "no cluster reference attached";
467  }
468  }
469 }

References SiStripCluster::amplitudes(), spr::find(), first, SiStripCluster::firstStrip(), createfilelist::int, dqmdumpme::last, LogDebug, DetId::rawId(), SimHitCollMap, SiStripCluster::size(), stripdigisimlink, and DetId::subdetId().

Referenced by associateCluster(), and associateSiStripRecHit().

◆ associateSiStripRecHit()

template<typename T >
void TrackerHitAssociator::associateSiStripRecHit ( const T simplerechit,
std::vector< SimHitIdpr > &  simtrackid,
std::vector< simhitAddr > *  simhitCFPos = nullptr 
) const
inline

Definition at line 376 of file TrackerHitAssociator.cc.

378  {
379  const SiStripCluster* clust = &(*simplerechit->cluster());
380  associateSimpleRecHitCluster(clust, simplerechit->geographicalId(), simtrackid, simhitCFPos);
381 }

References associateSimpleRecHitCluster().

Referenced by associateHitId(), associateMatchedRecHit(), and associateProjectedRecHit().

◆ makeMaps()

void TrackerHitAssociator::makeMaps ( const edm::Event theEvent,
const Config config 
)
private

Definition at line 124 of file TrackerHitAssociator.cc.

124  {
125  // Step A: Get Inputs
126  // The collections are specified via ROUList in the configuration, and can
127  // be either crossing frames (e.g., mix/g4SimHitsTrackerHitsTIBLowTof)
128  // or just PSimHits (e.g., g4SimHits/TrackerHitsTIBLowTof)
129  if (assocHitbySimTrack_) {
130  for (auto const& cfToken : config.cfTokens_) {
132  int Nhits = 0;
133  if (theEvent.getByToken(cfToken, cf_simhit)) {
134  std::unique_ptr<MixCollection<PSimHit> > thisContainerHits(new MixCollection<PSimHit>(cf_simhit.product()));
135  for (auto const& isim : *thisContainerHits) {
136  DetId theDet(isim.detUnitId());
137  SimHitMap[theDet].push_back(isim);
138  ++Nhits;
139  }
140  LogDebug("TrkHitAssocTrace") << "simHits from crossing frames; map size = " << SimHitMap.size()
141  << ", Hit count = " << Nhits << std::endl;
142  }
143  }
144  for (auto const& simHitToken : config.simHitTokens_) {
146  int Nhits = 0;
147  if (theEvent.getByToken(simHitToken, simHits)) {
148  for (auto const& isim : *simHits) {
149  DetId theDet(isim.detUnitId());
150  SimHitMap[theDet].push_back(isim);
151  ++Nhits;
152  }
153  LogDebug("TrkHitAssocTrace") << "simHits from prompt collections; map size = " << SimHitMap.size()
154  << ", Hit count = " << Nhits << std::endl;
155  }
156  }
157  } else { // !assocHitbySimTrack_
158  const char* const highTag = "HighTof";
159  unsigned int tofBin;
161  subDetTofBin theSubDetTofBin;
162  unsigned int collectionIndex = 0;
163  for (auto const& cfToken : config.cfTokens_) {
164  collectionIndex++;
166  int Nhits = 0;
167  if (theEvent.getByToken(cfToken, cf_simhit)) {
168  std::unique_ptr<MixCollection<PSimHit> > thisContainerHits(new MixCollection<PSimHit>(cf_simhit.product()));
169  theEvent.labelsForToken(cfToken, labels);
170  if (std::strstr(labels.productInstance, highTag) != nullptr) {
171  tofBin = StripDigiSimLink::HighTof;
172  } else {
173  tofBin = StripDigiSimLink::LowTof;
174  }
175  for (auto const& isim : *thisContainerHits) {
176  DetId theDet(isim.detUnitId());
177  theSubDetTofBin = std::make_pair(theDet.subdetId(), tofBin);
178  SimHitCollMap[theSubDetTofBin] = collectionIndex;
179  SimHitMap[SimHitCollMap[theSubDetTofBin]].push_back(isim);
180  ++Nhits;
181  }
182  LogDebug("TrkHitAssocTrace") << "simHits from crossing frames " << collectionIndex << ": " << Nhits
183  << std::endl;
184  }
185  }
186  collectionIndex = 0;
187  for (auto const& simHitToken : config.simHitTokens_) {
188  collectionIndex++;
190  int Nhits = 0;
191  if (theEvent.getByToken(simHitToken, simHits)) {
192  theEvent.labelsForToken(simHitToken, labels);
193  if (std::strstr(labels.productInstance, highTag) != nullptr) {
194  tofBin = StripDigiSimLink::HighTof;
195  } else {
196  tofBin = StripDigiSimLink::LowTof;
197  }
198  for (auto const& isim : *simHits) {
199  DetId theDet(isim.detUnitId());
200  theSubDetTofBin = std::make_pair(theDet.subdetId(), tofBin);
201  SimHitCollMap[theSubDetTofBin] = collectionIndex;
202  SimHitMap[SimHitCollMap[theSubDetTofBin]].push_back(isim);
203  ++Nhits;
204  }
205  LogDebug("TrkHitAssocTrace") << "simHits from prompt collection " << collectionIndex << ": " << Nhits
206  << std::endl;
207  }
208  }
209  }
210 }

References assocHitbySimTrack_, edm::Event::getByToken(), StripDigiSimLink::HighTof, SummaryClient_cfi::labels, edm::Event::labelsForToken(), LogDebug, StripDigiSimLink::LowTof, edm::Handle< T >::product(), SimHitCollMap, SimHitMap, FastTrackerRecHitCombiner_cfi::simHits, and SiPixelPhase1TrackingParticleV_cfi::simHitToken.

Referenced by TrackerHitAssociator().

◆ printDetBnchEvtTrk()

std::string TrackerHitAssociator::printDetBnchEvtTrk ( const DetId detid,
const uint32_t &  detID,
std::vector< SimHitIdpr > &  simtrackid 
) const
inlineprivate

Definition at line 666 of file TrackerHitAssociator.cc.

668  {
669  std::stringstream message;
670  message << "recHit subdet, detID = " << detid.subdetId() << ", " << detID << ", (bnch, evt, trk) = ";
671  for (size_t i = 0; i < simtrackid.size(); ++i)
672  message << ", (" << simtrackid[i].second.bunchCrossing() << ", " << simtrackid[i].second.event() << ", "
673  << simtrackid[i].first << ")";
674  // message << std::endl;
675  return message.str();
676 }

References mps_fire::i, edm::second(), and DetId::subdetId().

Referenced by associateHit().

Member Data Documentation

◆ assocHitbySimTrack_

bool TrackerHitAssociator::assocHitbySimTrack_
private

Definition at line 130 of file TrackerHitAssociator.h.

Referenced by associateHit(), and makeMaps().

◆ doPixel_

bool TrackerHitAssociator::doPixel_
private

Definition at line 130 of file TrackerHitAssociator.h.

Referenced by TrackerHitAssociator().

◆ doStrip_

bool TrackerHitAssociator::doStrip_
private

Definition at line 130 of file TrackerHitAssociator.h.

Referenced by TrackerHitAssociator().

◆ doTrackAssoc_

bool TrackerHitAssociator::doTrackAssoc_
private

Definition at line 130 of file TrackerHitAssociator.h.

Referenced by associateHit(), and TrackerHitAssociator().

◆ ph2trackerdigisimlink

edm::Handle<edm::DetSetVector<PixelDigiSimLink> > TrackerHitAssociator::ph2trackerdigisimlink
private

Definition at line 129 of file TrackerHitAssociator.h.

Referenced by associatePhase2TrackerRecHit(), and TrackerHitAssociator().

◆ pixeldigisimlink

edm::Handle<edm::DetSetVector<PixelDigiSimLink> > TrackerHitAssociator::pixeldigisimlink
private

Definition at line 128 of file TrackerHitAssociator.h.

Referenced by associatePixelRecHit(), and TrackerHitAssociator().

◆ SimHitCollMap

simhit_collectionMap TrackerHitAssociator::SimHitCollMap

◆ SimHitMap

simhit_map TrackerHitAssociator::SimHitMap

◆ stripdigisimlink

edm::Handle<edm::DetSetVector<StripDigiSimLink> > TrackerHitAssociator::stripdigisimlink
private

Definition at line 127 of file TrackerHitAssociator.h.

Referenced by associateSimpleRecHitCluster(), and TrackerHitAssociator().

◆ useOTph2_

bool TrackerHitAssociator::useOTph2_
private

Definition at line 130 of file TrackerHitAssociator.h.

Referenced by TrackerHitAssociator().

SummaryClient_cfi.labels
labels
Definition: SummaryClient_cfi.py:61
TrackerHitAssociator::SimHitCollMap
simhit_collectionMap SimHitCollMap
Definition: TrackerHitAssociator.h:118
mps_fire.i
i
Definition: mps_fire.py:428
TrackerHitAssociator::associatePhase2TrackerRecHit
void associatePhase2TrackerRecHit(const Phase2TrackerRecHit1D *rechit, std::vector< SimHitIdpr > &simtrackid, std::vector< simhitAddr > *simhitCFPos=nullptr) const
Definition: TrackerHitAssociator.cc:509
TrackerHitAssociator::assocHitbySimTrack_
bool assocHitbySimTrack_
Definition: TrackerHitAssociator.h:130
edm::Handle::product
T const * product() const
Definition: Handle.h:70
TrackerHitAssociator::associateSimpleRecHitCluster
void associateSimpleRecHitCluster(const SiStripCluster *clust, const DetId &detid, std::vector< SimHitIdpr > &simtrackid, std::vector< simhitAddr > *simhitCFPos=nullptr) const
Definition: TrackerHitAssociator.cc:411
SiPixelPhase1TrackingParticleV_cfi.simHitToken
simHitToken
Definition: SiPixelPhase1TrackingParticleV_cfi.py:122
TrackerHitAssociator::associatePixelRecHit
void associatePixelRecHit(const SiPixelRecHit *pixelrechit, std::vector< SimHitIdpr > &simtrackid, std::vector< simhitAddr > *simhitCFPos=nullptr) const
Definition: TrackerHitAssociator.cc:566
SimHitIdpr
std::pair< uint32_t, EncodedEventId > SimHitIdpr
Definition: TrackerHitAssociator.h:54
TrackerHitAssociator::ph2trackerdigisimlink
edm::Handle< edm::DetSetVector< PixelDigiSimLink > > ph2trackerdigisimlink
Definition: TrackerHitAssociator.h:129
TrackerHitAssociator::associateMultiRecHit
std::vector< PSimHit > associateMultiRecHit(const SiTrackerMultiRecHit *multirechit) const
Definition: TrackerHitAssociator.cc:627
edm::Ref::isNull
bool isNull() const
Checks for null.
Definition: Ref.h:235
TrackerHitAssociator::associateProjectedRecHit
std::vector< SimHitIdpr > associateProjectedRecHit(const ProjectedSiStripRecHit2D *projectedrechit, std::vector< simhitAddr > *simhitCFPos=nullptr) const
Definition: TrackerHitAssociator.cc:498
TrackerHitAssociator::stripdigisimlink
edm::Handle< edm::DetSetVector< StripDigiSimLink > > stripdigisimlink
Definition: TrackerHitAssociator.h:127
TrackerHitAssociator::associateHit
std::vector< PSimHit > associateHit(const TrackingRecHit &thit) const
Definition: TrackerHitAssociator.cc:212
SiTrackerMultiRecHit::recHits
std::vector< const TrackingRecHit * > recHits() const override
Access to component RecHits (if any)
Definition: SiTrackerMultiRecHit.cc:59
FastTrackerRecHitCombiner_cfi.simHits
simHits
Definition: FastTrackerRecHitCombiner_cfi.py:5
edm::second
U second(std::pair< T, U > const &p)
Definition: ParameterSet.cc:222
SiStripRecHit2D
Definition: SiStripRecHit2D.h:7
spr::find
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:19
edm::Handle
Definition: AssociativeIterator.h:50
SiPixelRecHit::cluster
ClusterRef cluster() const
Definition: SiPixelRecHit.h:47
TrackingRecHit::geographicalId
DetId geographicalId() const
Definition: TrackingRecHit.h:120
ProjectedSiStripRecHit2D
Definition: ProjectedSiStripRecHit2D.h:8
SiPixelRecHit
Our base class.
Definition: SiPixelRecHit.h:23
edm::Ref
Definition: AssociativeIterator.h:58
PSimHit::eventId
EncodedEventId eventId() const
Definition: PSimHit.h:108
PSimHit::detUnitId
unsigned int detUnitId() const
Definition: PSimHit.h:97
SiStripCluster::firstStrip
uint16_t firstStrip() const
Definition: SiStripCluster.h:46
EncodedEventId
Definition: EncodedEventId.h:11
config
Definition: config.py:1
DetId
Definition: DetId.h:17
dqmdumpme.last
last
Definition: dqmdumpme.py:56
Phase2TrackerRecHit1D::cluster
CluRef cluster() const
Definition: Phase2TrackerRecHit1D.h:24
PSimHit::processType
unsigned short processType() const
Definition: PSimHit.h:120
edm::Event::labelsForToken
void labelsForToken(EDGetToken const &iToken, ProductLabels &oLabels) const
Definition: Event.h:255
MixCollection
Definition: MixCollection.h:10
mps_fire.end
end
Definition: mps_fire.py:242
SiStripMatchedRecHit2D::stereoHit
SiStripRecHit2D stereoHit() const
Definition: SiStripMatchedRecHit2D.h:25
ProjectedSiStripRecHit2D::originalHit
SiStripRecHit2D originalHit() const
Definition: ProjectedSiStripRecHit2D.h:56
FastTrackerRecHit::simTrackId
virtual int32_t simTrackId(size_t i) const
Definition: FastTrackerRecHit.h:99
SiTrackerMultiRecHit::weight
float weight(unsigned int i) const
Definition: SiTrackerMultiRecHit.h:52
edm::Event::getByToken
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:535
TrackerHitAssociator::simHitCollectionID
unsigned int simHitCollectionID
Definition: TrackerHitAssociator.h:75
first
auto first
Definition: CAHitNtupletGeneratorKernelsImpl.h:112
DetId::subdetId
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum)
Definition: DetId.h:48
FastTrackerRecHit::nSimTrackIds
virtual size_t nSimTrackIds() const
Definition: FastTrackerRecHit.h:98
LogDebug
#define LogDebug(id)
Definition: MessageLogger.h:233
FastTrackerRecHit::simTrackEventId
virtual int32_t simTrackEventId(size_t i) const
Definition: FastTrackerRecHit.h:100
SiTrackerMultiRecHit::weights
std::vector< float > const & weights() const
Definition: SiTrackerMultiRecHit.h:47
TrackerHitAssociator::printDetBnchEvtTrk
std::string printDetBnchEvtTrk(const DetId &detid, const uint32_t &detID, std::vector< SimHitIdpr > &simtrackid) const
Definition: TrackerHitAssociator.cc:666
TrackerHitAssociator::doStrip_
bool doStrip_
Definition: TrackerHitAssociator.h:130
TrackerHitAssociator::SimHitMap
simhit_map SimHitMap
Definition: TrackerHitAssociator.h:116
TrackerHitAssociator::pixeldigisimlink
edm::Handle< edm::DetSetVector< PixelDigiSimLink > > pixeldigisimlink
Definition: TrackerHitAssociator.h:128
EncodedEventId::event
int event() const
get the contents of the subdetector field (should be protected?)
Definition: EncodedEventId.h:30
SiStripMatchedRecHit2D::monoHit
SiStripRecHit2D monoHit() const
Definition: SiStripMatchedRecHit2D.h:26
TrackerHitAssociator::useOTph2_
bool useOTph2_
Definition: TrackerHitAssociator.h:130
createfilelist.int
int
Definition: createfilelist.py:10
SiStripCluster::size
uint8_t size() const
Definition: SiStripCluster.h:63
Phase2TrackerDigi::channelToPixel
static std::pair< unsigned int, unsigned int > channelToPixel(unsigned int ch)
Definition: Phase2TrackerDigi.h:39
TrackerHitAssociator::associateMatchedRecHit
std::vector< SimHitIdpr > associateMatchedRecHit(const SiStripMatchedRecHit2D *matchedrechit, std::vector< simhitAddr > *simhitCFPos=nullptr) const
Definition: TrackerHitAssociator.cc:471
TrackerHitAssociator::doTrackAssoc_
bool doTrackAssoc_
Definition: TrackerHitAssociator.h:130
edm::LogError
Log< level::Error, false > LogError
Definition: MessageLogger.h:123
SiStripRecHit1D
Definition: SiStripRecHit1D.h:8
SiStripCluster::amplitudes
SiStripCluster const & amplitudes() const
Definition: SiStripCluster.h:68
DetId::rawId
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:57
SiStripMatchedRecHit2D
Definition: SiStripMatchedRecHit2D.h:8
TrackerHitAssociator::associateMultiRecHitId
std::vector< SimHitIdpr > associateMultiRecHitId(const SiTrackerMultiRecHit *multirechit, std::vector< simhitAddr > *simhitCFPos=nullptr) const
Definition: TrackerHitAssociator.cc:640
AlignmentPI::index
index
Definition: AlignmentPayloadInspectorHelper.h:46
PSimHit::trackId
unsigned int trackId() const
Definition: PSimHit.h:106
mps_fire.result
result
Definition: mps_fire.py:311
PSimHit
Definition: PSimHit.h:15
SiStripCluster
Definition: SiStripCluster.h:8
SiTrackerMultiRecHit
Definition: SiTrackerMultiRecHit.h:13
TrackerHitAssociator::associateHitId
std::vector< SimHitIdpr > associateHitId(const TrackingRecHit &thit) const
Definition: TrackerHitAssociator.cc:332
TrackerHitAssociator::associateFastRecHit
std::vector< SimHitIdpr > associateFastRecHit(const FastTrackerRecHit *rechit) const
Definition: TrackerHitAssociator.cc:656
TrackerHitAssociator::associateSiStripRecHit
void associateSiStripRecHit(const T *simplerechit, std::vector< SimHitIdpr > &simtrackid, std::vector< simhitAddr > *simhitCFPos=nullptr) const
Definition: TrackerHitAssociator.cc:376
TrackerHitAssociator::makeMaps
void makeMaps(const edm::Event &theEvent, const Config &config)
Definition: TrackerHitAssociator.cc:124
EncodedEventId::bunchCrossing
int bunchCrossing() const
get the detector field from this detid
Definition: EncodedEventId.h:25
TrackerHitAssociator::doPixel_
bool doPixel_
Definition: TrackerHitAssociator.h:130
TrackerHitAssociator::simhitAddr
std::pair< unsigned int, unsigned int > simhitAddr
Definition: TrackerHitAssociator.h:74
Phase2TrackerRecHit1D
Definition: Phase2TrackerRecHit1D.h:10
edm::ProductLabels
Definition: ProductLabels.h:4
PixelDigi::channelToPixel
static std::pair< int, int > channelToPixel(int ch)
Definition: PixelDigi.h:65
trackerHitRTTI::isFast
bool isFast(TrackingRecHit const &hit)
Definition: trackerHitRTTI.h:37
TrackerHitAssociator::subDetTofBin
std::pair< unsigned int, unsigned int > subDetTofBin
Definition: TrackerHitAssociator.h:74
findQualityFiles.size
size
Write out results.
Definition: findQualityFiles.py:443
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37