30 trackerHitAssociatorConfig_(ps, consumesCollector()),
56 switchNumrphi = ParametersNumrphi.getParameter<
bool>(
"switchon");
86 switchAdcrphi = ParametersAdcrphi.getParameter<
bool>(
"switchon");
89 switchPosxrphi = ParametersPosxrphi.getParameter<
bool>(
"switchon");
95 switchResrphi = ParametersResrphi.getParameter<
bool>(
"switchon");
104 switchChi2rphi = ParametersChi2rphi.getParameter<
bool>(
"switchon");
168 edm::LogInfo(
"SiStripRecHitsValid") <<
"SiStripRecHitsValid::beginRun: "
169 <<
" Creating MEs for new Cabling ";
176 LogInfo(
"EventInfo") <<
" Run = " <<
e.id().run() <<
" Event = " <<
e.id().event();
192 std::map<std::string, int> totnumrechitrphi;
193 std::map<std::string, int> totnumrechitstereo;
194 std::map<std::string, int> totnumrechitmatched;
195 int totrechitrphi = 0;
196 int totrechitstereo = 0;
197 int totrechitmatched = 0;
207 for (
auto const& theDetSet : *rechitsrphi) {
208 DetId detid = theDetSet.detId();
209 uint32_t myid = detid.
rawId();
210 totrechitrphi += theDetSet.size();
213 std::map<std::string, LayerMEs>::iterator iLayerME =
LayerMEsMap.find(
label);
214 std::pair<std::string, int32_t> det_lay_pair = fold_organ.
GetSubDetAndLayer(myid, tTopo,
true);
216 totnumrechitrphi[det_lay_pair.first] = totnumrechitrphi[det_lay_pair.first] + theDetSet.size();
219 for (
auto const& rechit : theDetSet) {
221 const StripTopology& topol = static_cast<const StripGeomDetUnit*>(det)->specificTopology();
231 std::map<std::string, SubDetMEs>::iterator iSubDetME =
SubDetMEsMap.find(det_lay_pair.first);
247 for (
auto const& theDetSet : *rechitsstereo) {
248 DetId detid = theDetSet.detId();
249 uint32_t myid = detid.
rawId();
250 totrechitstereo += theDetSet.size();
254 std::pair<std::string, int32_t> det_lay_pair = fold_organ.
GetSubDetAndLayer(myid, tTopo,
true);
256 totnumrechitstereo[det_lay_pair.first] = totnumrechitstereo[det_lay_pair.first] + theDetSet.size();
259 for (
auto const& rechit : theDetSet) {
261 const StripTopology& topol = static_cast<const StripGeomDetUnit*>(det)->specificTopology();
271 std::map<std::string, SubDetMEs>::iterator iSubDetME =
SubDetMEsMap.find(det_lay_pair.first);
287 for (
auto const& theDetSet : *rechitsmatched) {
288 DetId detid = theDetSet.detId();
289 uint32_t myid = detid.
rawId();
290 totrechitmatched += theDetSet.size();
294 std::pair<std::string, int32_t> det_lay_pair = fold_organ.
GetSubDetAndLayer(myid, tTopo,
true);
296 totnumrechitmatched[det_lay_pair.first] = totnumrechitmatched[det_lay_pair.first] + theDetSet.size();
299 for (
auto const& rechit : theDetSet) {
300 const GluedGeomDet* gluedDet = static_cast<const GluedGeomDet*>(
tracker.idToDet(rechit.geographicalId()));
310 std::map<std::string, SubDetMEs>::iterator iSubDetME =
SubDetMEsMap.find(det_lay_pair.first);
325 for (std::vector<std::string>::iterator iSubdet =
SubDetList_.begin(); iSubdet !=
SubDetList_.end(); ++iSubdet) {
326 std::map<std::string, SubDetMEs>::iterator iSubDetME =
SubDetMEsMap.find((*iSubdet));
327 fillME(iSubDetME->second.meNumrphi, totnumrechitrphi[(*iSubdet)]);
328 fillME(iSubDetME->second.meNumStereo, totnumrechitstereo[(*iSubdet)]);
329 fillME(iSubDetME->second.meNumMatched, totnumrechitmatched[(*iSubdet)]);
346 LocalPoint localHit = plane.toLocal(globalpos);
363 return std::pair<LocalPoint, LocalVector>(projectedPos, localStripDir);
380 const auto& amplitudes = (rechit.
cluster())->amplitudes();
382 for (
auto ia : amplitudes) {
400 PSimHit const* closest =
nullptr;
404 if (dist < mindist) {
429 float est =
R.similarity(
r);
467 PSimHit const* closest =
nullptr;
468 std::pair<LocalPoint, LocalVector> closestPair;
471 std::pair<LocalPoint, LocalVector> hitPair;
475 if (hitDetId.stereo()) {
480 dist2 = distx * distx + disty * disty;
482 if (dist < mindist) {
484 closestPair = hitPair;
503 shparameters[0] = sh.
x();
504 shparameters[1] = sh.
y();
512 float est =
R.similarity(
r);
527 std::vector<uint32_t> activeDets;
538 edm::LogInfo(
"SiStripTkRecHits|SiStripRecHitsValid") <<
"nr. of activeDets: " << activeDets.size();
539 const std::string &tec =
"TEC", tid =
"TID", tob =
"TOB", tib =
"TIB";
540 for (
auto detid_iterator = activeDets.begin(), detid_end = activeDets.end(); detid_iterator != detid_end;
542 uint32_t detid = (*detid_iterator);
545 activeDets.erase(detid_iterator);
550 std::pair<std::string, int32_t> det_layer_pair = folder_organizer.
GetSubDetAndLayer(detid, tTopo,
true);
557 int32_t lnumber = det_layer_pair.second;
559 std::vector<uint32_t> layerDetIds;
563 }
else if (lnumber < 0) {
566 }
else if (lname == tid) {
569 }
else if (lnumber < 0) {
572 }
else if (lname == tob) {
574 }
else if (lname == tib) {
580 folder_organizer.
setLayerFolder(detid, tTopo, det_layer_pair.second,
true);
592 bool isStereo =
false;
594 std::vector<uint32_t> stereoandmatchedDetIds;
595 int32_t stereolnumber = det_layer_pair.second;
596 const std::string& stereolname = det_layer_pair.first;
597 if (stereolname == tec && (tTopo->
tecIsStereo(detid))) {
598 if (stereolnumber > 0) {
600 activeDets, stereoandmatchedDetIds, tTopo, 2, 0, 0, 0,
abs(stereolnumber), 1);
602 }
else if (stereolnumber < 0) {
604 activeDets, stereoandmatchedDetIds, tTopo, 1, 0, 0, 0,
abs(stereolnumber), 1);
607 }
else if (stereolname == tid && (tTopo->
tidIsStereo(detid))) {
608 if (stereolnumber > 0) {
611 }
else if (stereolnumber < 0) {
615 }
else if (stereolname == tob && (tTopo->
tobIsStereo(detid))) {
618 }
else if (stereolname == tib && (tTopo->
tibIsStereo(detid))) {
627 folder_organizer.
setLayerFolder(detid, tTopo, det_layer_pair.second,
true);
676 "Cluster Width - Number of strips that belong to the RecHit cluster");
684 "RecHit Cluster Charge");
700 "RecHit resol(x) coord.");
708 "Residuals of the hit x coordinate");
716 "Pull distribution");
724 "Pull distribution");
740 "No. of assoc. simHits");
775 "Cluster Width - Number of strips that belong to the RecHit cluster");
783 "RecHit Cluster Charge");
800 "RecHit resol(x) coord.");
809 "Residuals of the hit x coordinate");
818 "Pull distribution");
827 "Pull distribution");
845 "No. of assoc. simHits");
872 "RecHit resol(x) coord.");
881 "RecHit resol(y) coord.");
890 "Residuals of the hit x coord.");
899 "Residuals of the hit y coord.");
917 "No. of assoc. simHits");
996 const char* ParameterSetLabel,
998 const char* HistoTitle) {