29 tracksCollection_in_EventTree(
true),
75 LogDebug(
"SiStripMonitorTrack") <<
"[SiStripMonitorTrack::beginRun] There are "<<
tkgeom_->
detUnits().size() <<
" detectors instantiated in the geometry" << std::endl;
90 book(ibooker , tTopo);
103 LogDebug(
"SiStripMonitorTrack") <<
"[SiStripMonitorTrack::analyse] " <<
"Run " << e.
id().
run() <<
" Event " << e.
id().
event() << std::endl;
110 for (std::map<std::string, SubDetMEs>::iterator iSubDet =
SubDetMEsMap.begin();
112 iSubDet->second.totNClustersOnTrack = 0;
113 iSubDet->second.totNClustersOffTrack = 0;
124 std::map<std::string, MonitorElement*>::iterator iME;
125 std::map<std::string, LayerMEs>::iterator iLayerME;
177 std::vector<uint32_t> vdetId_;
179 const char* tec =
"TEC";
180 const char* tid =
"TID";
185 for (std::vector<uint32_t>::const_iterator detid_iter=vdetId_.begin(),detid_end=vdetId_.end();detid_iter!=detid_end;++detid_iter){
186 uint32_t detid = *detid_iter;
189 edm::LogError(
"SiStripMonitorTrack")<<
"[" <<__PRETTY_FUNCTION__ <<
"] invalid detid " << detid<< std::endl;
197 std::pair<std::string,int32_t> det_layer_pair = folder_organizer.
GetSubDetAndLayer(detid,tTopo,
false);
206 std::map<std::string, LayerMEs>::iterator iLayerME =
LayerMEsMap.find(layer_id);
208 folder_organizer.
setLayerFolder(detid, tTopo, det_layer_pair.second,
false);
212 const char* subdet = det_layer_pair.first.c_str();
213 if ( std::strstr(subdet, tec) !=
nullptr || std::strstr(subdet, tid) !=
nullptr ) {
215 std::map<std::string, RingMEs>::iterator iRingME =
RingMEsMap.find(ring_id);
217 std::pair<std::string,int32_t> det_ring_pair = folder_organizer.
GetSubDetAndLayer(detid,tTopo,
true);
218 folder_organizer.
setLayerFolder(detid, tTopo, det_ring_pair.second,
true);
234 for (std::vector<uint32_t>::const_iterator detid_iter=vdetId_.begin(),detid_end=vdetId_.end();detid_iter!=detid_end;++detid_iter){
235 uint32_t detid = *detid_iter;
238 edm::LogError(
"SiStripMonitorTrack")<<
"[" <<__PRETTY_FUNCTION__ <<
"] invalid detid " << detid<< std::endl;
246 std::pair<std::string,int32_t> det_layer_pair = folder_organizer.
GetSubDetAndLayer(detid,tTopo,
false);
255 std::map<std::string, LayerMEs>::iterator iLayerME =
LayerMEsMap.find(layer_id);
257 folder_organizer.
setLayerFolder(detid, tTopo, det_layer_pair.second,
false);
261 const char* subdet = det_layer_pair.first.c_str();
262 if ( std::strstr(subdet, tec) !=
nullptr || std::strstr(subdet, tid) !=
nullptr ) {
264 std::map<std::string, RingMEs>::iterator iRingME =
RingMEsMap.find(ring_id);
266 std::pair<std::string,int32_t> det_ring_pair = folder_organizer.
GetSubDetAndLayer(detid,tTopo,
true);
267 folder_organizer.
setLayerFolder(detid, tTopo, det_ring_pair.second,
true);
286 ibooker.
book1D(
"ClusterStoNCorr_OnTrack_TIBTID",
"TIB/TID [FECCrate=1] (OnTrack)",100,0.,100.);
290 ibooker.
book1D(
"ClusterStoNCorr_OnTrack_TOB",
"TOB [FECCrate=4] (OnTrack)",100,0.,100.);
294 ibooker.
book1D(
"ClusterStoNCorr_OnTrack_TECM",
"TECM [FECCrate=3] (OnTrack)",100,0.,100.);
298 ibooker.
book1D(
"ClusterStoNCorr_OnTrack_TECP",
"TECP [FECCrate=2] (OnTrack)",100,0.,100.);
303 ibooker.
book2D(
"ClusterStoNCorr_OnTrack_FECCratevsFECSlot",
" S/N (On track)",22,0.5,22.5,4,0.5,4.5);
312 ibooker.
book2D(
"ClusterStoNCorr_OnTrack_FECSlotVsFECRing_TIBTID",
"TIB/TID [FECCrate=1] (OnTrack)",10,-0.5,9.5,22,0.5,22.5)\
318 ibooker.
book2D(
"ClusterStoNCorr_OnTrack_FECSlotVsFECRing_TOB",
"TOB [FECCrate=4] (OnTrack)",10,-0.5,9.5,22,0.5,22.5);
323 ibooker.
book2D(
"ClusterStoNCorr_OnTrack_FECSlotVsFECRing_TECM",
"TEC- [FECCrate=3] (OnTrack)",10,-0.5,9.5,22,0.5,22.5);
328 ibooker.
book2D(
"ClusterStoNCorr_OnTrack_FECSlotVsFECRing_TECP",
"TEC- [FECCrate=2] (OnTrack)",10,-0.5,9.5,22,0.5,22.5);
337 ibooker.
book2D(
"ClusterCount_OnTrack_FECCratevsFECSlot",
" S/N (On track)",22,0.5,22.5,4,0.5,4.5);
346 ibooker.
book2D(
"ClusterCount_OnTrack_FECSlotVsFECRing_TIBTID",
"TIB/TID [FECCrate=1] (OnTrack)",10,-0.5,9.5,22,0.5,22.5)\
352 ibooker.
book2D(
"ClusterCount_OnTrack_FECSlotVsFECRing_TOB",
"TOB [FECCrate=4] (OnTrack)",10,-0.5,9.5,22,0.5,22.5);
357 ibooker.
book2D(
"ClusterCount_OnTrack_FECSlotVsFECRing_TECM",
"TEC- [FECCrate=3] (OnTrack)",10,-0.5,9.5,22,0.5,22.5);
362 ibooker.
book2D(
"ClusterCount_OnTrack_FECSlotVsFECRing_TECP",
"TEC- [FECCrate=2] (OnTrack)",10,-0.5,9.5,22,0.5,22.5);
377 std::map<std::string, ModMEs>::iterator iModME =
ModMEsMap.find(hid);
403 theModMEs.
ClusterPos=ibooker.
book1D(hidmanager.
createHistoId(
"ClusterPosition_OnTrack",name,
id).c_str(),hidmanager.
createHistoId(
"ClusterPosition_OnTrack",name,
id).c_str(),total_nr_strips,0.5,total_nr_strips+0.5);
424 if (
id.
find(
"TEC") == std::string::npos &&
id.find(
"TID") == std::string::npos ) {
425 me =
bookME1D(ibooker , histoParameters.c_str(), histoName.c_str());
429 me =
bookME1D(ibooker , histoParameters.c_str(), histoName.c_str());
450 hname = hidmanager.
createHistoLayer(
"Summary_ClusterStoNCorr",name,layer_id,
"OnTrack");
451 hpar =
"TH1ClusterStoNCorr";
455 hname = hidmanager.
createHistoLayer(
"Summary_ClusterGain",name,layer_id,
"");
456 hpar =
"TH1ClusterGain";
460 hname = hidmanager.
createHistoLayer(
"Summary_ClusterChargeCorr",name,layer_id,
"OnTrack");
461 hpar =
"TH1ClusterChargeCorr";
465 hname = hidmanager.
createHistoLayer(
"Summary_ClusterCharge",name,layer_id,
"OnTrack");
466 hpar =
"TH1ClusterCharge";
469 hname = hidmanager.
createHistoLayer(
"Summary_ClusterCharge",name,layer_id,
"OffTrack");
470 hpar =
"TH1ClusterCharge";
474 hname = hidmanager.
createHistoLayer(
"Summary_ClusterChargeRaw",name,layer_id,
"OnTrack");
475 hpar =
"TH1ClusterChargeRaw";
478 hname = hidmanager.
createHistoLayer(
"Summary_ClusterChargeRaw",name,layer_id,
"OffTrack");
479 hpar =
"TH1ClusterChargeRaw";
483 hname = hidmanager.
createHistoLayer(
"Summary_ClusterNoise",name,layer_id,
"OnTrack");
484 hpar =
"TH1ClusterNoise";
487 hname = hidmanager.
createHistoLayer(
"Summary_ClusterNoise",name,layer_id,
"OffTrack");
488 hpar =
"TH1ClusterNoise";
492 hname = hidmanager.
createHistoLayer(
"Summary_ClusterWidth",name,layer_id,
"OnTrack");
493 hpar =
"TH1ClusterWidth";
496 hname = hidmanager.
createHistoLayer(
"Summary_ClusterWidth",name,layer_id,
"OffTrack");
497 hpar =
"TH1ClusterWidth";
502 if (layer_id.find(
"TEC") != std::string::npos) total_nr_strips = 3 * 2 * 128;
504 hname = hidmanager.
createHistoLayer(
"Summary_ClusterPosition",name,layer_id,
"OnTrack");
505 hpar =
"TH1ClusterPos";
506 if ( layer_id.find(
"TIB") != std::string::npos || layer_id.find(
"TOB") != std::string::npos || (
conf_.
getParameter<
edm::ParameterSet>(hpar.c_str())).getParameter<
bool>(view.c_str()) ) theLayerMEs.
ClusterPosOnTrack = ibooker.
book1D(hname, hname, total_nr_strips, 0.5,total_nr_strips+0.5);
508 hname = hidmanager.
createHistoLayer(
"Summary_ClusterPosition",name,layer_id,
"OffTrack");
509 hpar =
"TH1ClusterPos";
510 if ( layer_id.find(
"TIB") != std::string::npos || layer_id.find(
"TOB") != std::string::npos || (
conf_.
getParameter<
edm::ParameterSet>(hpar.c_str())).getParameter<
bool>(view.c_str()) ) theLayerMEs.
ClusterPosOffTrack = ibooker.
book1D(hname, hname, total_nr_strips, 0.5,total_nr_strips+0.5);
513 hname = hidmanager.
createHistoLayer(
"Summary_ClusterChargePerCMfromTrack",name,layer_id,
"");
514 hpar =
"TH1ClusterChargePerCM";
517 hname = hidmanager.
createHistoLayer(
"Summary_ClusterChargePerCMfromOrigin",name,layer_id,
"OnTrack");
518 hpar =
"TH1ClusterChargePerCM";
521 hname = hidmanager.
createHistoLayer(
"Summary_ClusterChargePerCMfromOrigin",name,layer_id,
"OffTrack");
522 hpar =
"TH1ClusterChargePerCM";
541 hname = hidmanager.
createHistoLayer(
"Summary_ClusterStoNCorr",name,ring_id,
"OnTrack");
542 hpar =
"TH1ClusterStoNCorr";
547 hpar =
"TH1ClusterGain";
551 hname = hidmanager.
createHistoLayer(
"Summary_ClusterChargeCorr",name,ring_id,
"OnTrack");
552 hpar =
"TH1ClusterChargeCorr";
556 hname = hidmanager.
createHistoLayer(
"Summary_ClusterCharge",name,ring_id,
"OnTrack");
557 hpar =
"TH1ClusterCharge";
560 hname = hidmanager.
createHistoLayer(
"Summary_ClusterCharge",name,ring_id,
"OffTrack");
561 hpar =
"TH1ClusterCharge";
565 hname = hidmanager.
createHistoLayer(
"Summary_ClusterChargeRaw",name,ring_id,
"OnTrack");
566 hpar =
"TH1ClusterChargeRaw";
569 hname = hidmanager.
createHistoLayer(
"Summary_ClusterChargeRaw",name,ring_id,
"OffTrack");
570 hpar =
"TH1ClusterChargeRaw";
574 hname = hidmanager.
createHistoLayer(
"Summary_ClusterNoise",name,ring_id,
"OnTrack");
575 hpar =
"TH1ClusterNoise";
578 hname = hidmanager.
createHistoLayer(
"Summary_ClusterNoise",name,ring_id,
"OffTrack");
579 hpar =
"TH1ClusterNoise";
583 hname = hidmanager.
createHistoLayer(
"Summary_ClusterWidth",name,ring_id,
"OnTrack");
584 hpar =
"TH1ClusterWidth";
587 hname = hidmanager.
createHistoLayer(
"Summary_ClusterWidth",name,ring_id,
"OffTrack");
588 hpar =
"TH1ClusterWidth";
593 if (ring_id.find(
"TEC") != std::string::npos) total_nr_strips = 3 * 2 * 128;
595 hname = hidmanager.
createHistoLayer(
"Summary_ClusterPosition",name,ring_id,
"OnTrack");
596 hpar =
"TH1ClusterPos";
599 hname = hidmanager.
createHistoLayer(
"Summary_ClusterPosition",name,ring_id,
"OffTrack");
600 hpar =
"TH1ClusterPos";
604 hname = hidmanager.
createHistoLayer(
"Summary_ClusterChargePerCMfromTrack",name,ring_id,
"");
605 hpar =
"TH1ClusterChargePerCM";
608 hname = hidmanager.
createHistoLayer(
"Summary_ClusterChargePerCMfromOrigin",name,ring_id,
"OnTrack");
609 hpar =
"TH1ClusterChargePerCM";
612 hname = hidmanager.
createHistoLayer(
"Summary_ClusterChargePerCMfromOrigin",name,ring_id,
"OffTrack");
613 hpar =
"TH1ClusterChargePerCM";
627 subdet_tag =
"__" +
name;
634 completeName =
"Summary_TotalNumberOfClusters_OnTrack" +
subdet_tag;
635 axisName =
"Number of on-track clusters in " +
name;
641 completeName =
"Summary_TotalNumberOfClusters_OffTrack" +
subdet_tag;
642 axisName =
"Number of off-track clusters in " +
name;
647 if(name.find(
"TIB") != std::string::npos){
651 if(name.find(
"TOB") != std::string::npos){
655 if(name.find(
"TID") != std::string::npos){
659 if(name.find(
"TEC") != std::string::npos){
667 completeName =
"Summary_ClusterGain" +
subdet_tag;
671 completeName =
"Summary_ClusterStoNCorr_OnTrack" +
subdet_tag;
674 completeName =
"Summary_ClusterStoNCorrThin_OnTrack" +
subdet_tag;
677 completeName =
"Summary_ClusterStoNCorrThick_OnTrack" +
subdet_tag;
681 completeName =
"Summary_ClusterChargeCorr_OnTrack" +
subdet_tag;
684 completeName =
"Summary_ClusterChargeCorrThin_OnTrack" +
subdet_tag;
687 completeName =
"Summary_ClusterChargeCorrThick_OnTrack" +
subdet_tag;
691 completeName =
"Summary_ClusterCharge_OnTrack" +
subdet_tag;
695 completeName =
"Summary_ClusterChargeRaw_OnTrack" +
subdet_tag;
699 completeName =
"Summary_ClusterCharge_OffTrack" +
subdet_tag;
703 completeName =
"Summary_ClusterChargeRaw_OffTrack" +
subdet_tag;
707 completeName =
"Summary_ClusterStoN_OffTrack" +
subdet_tag;
711 completeName =
"Summary_ClusterChargePerCMfromTrack" +
subdet_tag;
715 completeName =
"Summary_ClusterChargePerCMfromOrigin_OnTrack" +
subdet_tag;
719 completeName =
"Summary_ClusterChargePerCMfromOrigin_OffTrack" +
subdet_tag;
724 completeName =
"Trend_TotalNumberOfClusters_OnTrack" +
subdet_tag;
726 completeName =
"Trend_TotalNumberOfClusters_OffTrack" +
subdet_tag;
739 return ibooker.
book1D(HistoName,HistoName,
750 return ibooker.
book2D(HistoName,HistoName,
764 return ibooker.
book3D(HistoName,HistoName,
803 me->setAxisTitle(
"Lumisection",1);
816 auto const & trajParams = track.
extra()->trajParams();
824 uint32_t thedetid=ttrh->rawId();
826 if ( (ttrh->getType()==1) )
828 if ( (ttrh->getType()==2) )
830 if ( (ttrh->getType()==0) )
835 if (!ttrh->isValid())
continue;
838 auto statedirection = trajParams[
h].momentum();
849 LogTrace(
"SiStripMonitorTrack")<<
"\nMatched recHit found"<< std::endl;
856 statedirection=monodet->
toLocal(gtrkdirup);
859 if(statedirection.mag()) RecHitInfo<SiStripRecHit2D>(&m,statedirection,digilist,ev,es,track_ok);
862 statedirection=stereodet->
toLocal(gtrkdirup);
865 if(statedirection.mag()) RecHitInfo<SiStripRecHit2D>(&s,statedirection,digilist,ev,es,track_ok);
868 LogTrace(
"SiStripMonitorTrack")<<
"\nProjected recHit found"<< std::endl;
877 LogTrace(
"SiStripMonitorTrack")<<
"\nProjected recHit found MONO"<< std::endl;
879 statedirection=det->
toLocal(gtrkdirup);
880 if(statedirection.mag()) RecHitInfo<SiStripRecHit2D>(&(originalhit),statedirection,digilist,
ev,es,track_ok);
883 LogTrace(
"SiStripMonitorTrack")<<
"\nProjected recHit found STEREO"<< std::endl;
886 statedirection=det->
toLocal(gtrkdirup);
887 if(statedirection.mag()) RecHitInfo<SiStripRecHit2D>(&(originalhit),statedirection,digilist,
ev,es,track_ok);
890 if(statedirection.mag()) RecHitInfo<SiStripRecHit2D>(hit2D,statedirection,digilist,ev,es,track_ok);
892 if(statedirection.mag()) RecHitInfo<SiStripRecHit1D>(hit1D,statedirection,digilist,ev,es,track_ok);
895 <<
" LocalMomentum: "<<statedirection
896 <<
"\nLocal x-z plane angle: "<<atan2(statedirection.x(),statedirection.z());
916 LogTrace(
"SiStripMonitorTrack")<<
"\nMatched recHit found"<< std::endl;
924 statedirection=monodet->
toLocal(gtrkdirup);
926 if(statedirection.
mag()) RecHitInfo<SiStripRecHit2D>(&m,statedirection,digilist,ev,es,track_ok);
930 statedirection=stereodet->
toLocal(gtrkdirup);
932 if(statedirection.
mag()) RecHitInfo<SiStripRecHit2D>(&s,statedirection,digilist,ev,es,track_ok);
935 LogTrace(
"SiStripMonitorTrack")<<
"\nProjected recHit found"<< std::endl;
945 LogTrace(
"SiStripMonitorTrack")<<
"\nProjected recHit found MONO"<< std::endl;
947 statedirection=det->
toLocal(gtrkdirup);
948 if(statedirection.
mag()) RecHitInfo<SiStripRecHit2D>(&(originalhit),statedirection,digilist,
ev,es,track_ok);
951 LogTrace(
"SiStripMonitorTrack")<<
"\nProjected recHit found STEREO"<< std::endl;
954 statedirection=det->
toLocal(gtrkdirup);
955 if(statedirection.
mag()) RecHitInfo<SiStripRecHit2D>(&(originalhit),statedirection,digilist,
ev,es,track_ok);
958 statedirection=localMomentum;
959 if(statedirection.
mag()) RecHitInfo<SiStripRecHit2D>(hit2D,statedirection,digilist,ev,es,track_ok);
961 statedirection=localMomentum;
962 if(statedirection.
mag()) RecHitInfo<SiStripRecHit1D>(hit1D,statedirection,digilist,ev,es,track_ok);
965 <<
" LocalMomentum: "<<statedirection
966 <<
"\nLocal x-z plane angle: "<<atan2(statedirection.
x(),statedirection.
z());
975 using namespace reco;
989 auto& digilist = digihandle.
isValid()? *(digihandle.
product()) : dummy;
991 if (trackCollectionHandle.
isValid()){
1002 if (track.
pt() < 0.8)
return false;
1003 if (track.
p() < 2.0)
return false;
1022 for (reco::TrackCollection::const_iterator
track = trackCollection.begin(), etrack = trackCollection.end();
1032 uint32_t thedetid=(*hit)->rawId();
1034 if ( ((*hit)->getType()==1) )
1036 if ( ((*hit)->getType()==2) )
1038 if ( ((*hit)->getType()==0) )
1043 if (!(*hit)->isValid())
continue;
1044 DetId detID = (*hit)->geographicalId();
1056 hitStudy(ev,es,digilist,projhit,matchedhit,hit2D,hit1D,localMomentum,track_ok);
1103 for (reco::TrackCollection::const_iterator
track = trackCollection.begin(), etrack = trackCollection.end();
1107 <<
"Track number "<< ++i << std::endl;
1133 if(!tkrecHit->isValid()){
1134 LogTrace(
"SiStripMonitorTrack") <<
"\t\t Invalid Hit " << std::endl;
1138 const uint32_t& detid = tkrecHit->geographicalId().rawId();
1141 <<
"\n\t\tRecHit on det "<<detid
1142 <<
"\n\t\tRecHit in LP "<<tkrecHit->localPosition()
1143 <<
"\n\t\tRecHit in GP "<<
tkgeom_->
idToDet(tkrecHit->geographicalId())->surface().
toGlobal(tkrecHit->localPosition())
1144 <<
"\n\t\tRecHit trackLocal vector "<<LV.
x() <<
" " << LV.
y() <<
" " << LV.
z() <<std::endl;
1163 if ( tkrecHit !=
nullptr ){
1169 if (
clusterInfos(&SiStripClusterInfo_,detid,
OnTrack, track_ok, LV, MEs, tTopo,stripGain,stripQuality,digilist))
1176 edm::LogError(
"SiStripMonitorTrack") <<
"NULL hit" << std::endl;
1200 auto& digilist = digihandle.
isValid()? *(digihandle.
product()) : dummy;
1204 if (siStripClusterHandle.
isValid()){
1207 DSViter!=DSVEnd; ++DSViter) {
1209 uint32_t detid=DSViter->id();
1212 LogDebug(
"SiStripMonitorTrack") <<
"on detid "<< detid <<
" N Cluster= " << DSViter->size();
1226 edm::LogError(
"SiStripMonitorTrack")<<
"ClusterCollection is not valid!!" << std::endl;
1244 std::map<std::string, LayerMEs>::iterator iLayer =
LayerMEsMap.find(layer_id);
1246 me.
iLayer = &(iLayer->second);
1249 std::map<std::string, RingMEs>::iterator iRing =
RingMEsMap.find(ring_id);
1251 me.
iRing = &(iRing->second);
1254 std::map<std::string, SubDetMEs>::iterator iSubdet =
SubDetMEsMap.find(sdet_tag);
1256 me.
iSubdet = &(iSubdet->second);
1269 if( !tracks.
isValid() )
return false;
1272 for (
const auto &
track : *tracks) {
1278 uint32_t thedetid = (*hit)->rawId();
1279 if ( !(
DetId(thedetid).subdetId() >=3 &&
DetId(thedetid).subdetId() <=6) ) {
continue; }
1281 if (!(*hit)->isValid())
continue;
1284 if ( theHit ==
nullptr ) {
continue; }
1294 if (hit1D && !hit2D) {
1300 else if (!hit1D && hit2D) {
1307 std::vector<const FedChannelConnection *> getFedChanConnections;
1314 for (
const auto & getFedChanConnection : getFedChanConnections ) {
1316 if (getFedChanConnection==
nullptr) {
continue; }
1318 int binfeccrate = getFedChanConnection->fecCrate();
1319 int binfecslot = getFedChanConnection->fecSlot();
1320 int binfecring = getFedChanConnection->fecRing();
1370 double theMeanSoN = (input1->
getBinContent(binx,biny)*nentries +
value)/(nentries+1);
1383 const uint32_t detid,
1395 if (cluster==
nullptr)
return false;
1405 LogDebug(
"SiStripMonitorTrack")<<
"\n\tLV " << LV.
x() <<
" " << LV.
y() <<
" " << LV.
z() <<
" " << LV.
mag() << std::endl;
1407 cosRZ= fabs(LV.
z())/LV.
mag();
1408 LogDebug(
"SiStripMonitorTrack")<<
"\n\t cosRZ " << cosRZ << std::endl;
1419 double chargeraw = 0;
1420 double clustergain = 0 ;
1421 auto digi_it = digilist.
find(detid);
1423 for(
size_t chidx = 0 ; chidx < cluster->
stripCharges().size() ; ++chidx ){
1424 if( cluster->
stripCharges().at(chidx) <= 0 ){ continue ; }
1428 if( digi_it == digilist.
end() ){
1431 for(
const auto& digiobj : *digi_it ){
1432 if( digiobj.strip() == cluster->
firstStrip() + chidx ){
1433 chargeraw += digiobj.adc();
1437 clustergain /= double(cluster->
stripCharges().size()) ;
1450 uint32_t adet=cluster->
detId();
1454 uint32_t adet=cluster->
detId();
1461 if (MEs.
iLayer !=
nullptr) {
1475 if (MEs.
iRing !=
nullptr) {
1497 if( tTopo->
moduleGeometry(detid) == SiStripDetId::ModuleGeometry::W5 || tTopo->
moduleGeometry(detid) == SiStripDetId::ModuleGeometry::W6 || tTopo->
moduleGeometry(detid) == SiStripDetId::ModuleGeometry::W7) {
1507 uint32_t adet=cluster->
detId();
1511 LogDebug(
"SiStripMonitorTrack") <<
"Module " << detid <<
" in Event " <<
eventNb <<
" noise " << noise << std::endl;
1514 uint32_t adet=cluster->
detId();
1525 std::map<std::string, ModMEs>::iterator iModME =
ModMEsMap.find(name);
1527 if(noise > 0.0)
fillME(iModME->second.ClusterStoNCorr ,StoN*cosRZ);
1528 if(noise == 0.0)
LogDebug(
"SiStripMonitorTrack") <<
"Module " << name <<
" in Event " <<
eventNb <<
" noise " << noise << std::endl;
1529 fillME(iModME->second.ClusterGain, clustergain);
1530 fillME(iModME->second.ClusterCharge,charge);
1531 fillME(iModME->second.ClusterChargeRaw,chargeraw);
1533 fillME(iModME->second.ClusterChargeCorr,charge*cosRZ);
1535 fillME(iModME->second.ClusterWidth ,width);
1536 fillME(iModME->second.ClusterPos ,position);
1538 if(track_ok)
fillME(iModME->second.ClusterChargePerCMfromTrack, dQdx_fromTrack);
1539 if(track_ok)
fillME(iModME->second.ClusterChargePerCMfromOrigin, dQdx_fromOrigin);
1543 int PGVposCounter = cluster->
maxIndex();
1545 fillME(iModME->second.ClusterPGV,
i,0.);
1547 fillME(iModME->second.ClusterPGV, PGVposCounter++,(*it)/PGVmax);
1550 fillME(iModME->second.ClusterPGV,
i,0.);
1559 uint32_t adet=cluster->
detId();
1562 LogDebug(
"SiStripMonitorTrack") <<
"Module firing " << detid <<
" in Event " <<
eventNb << std::endl;
1566 uint32_t adet=cluster->
detId();
1572 if (MEs.
iLayer !=
nullptr) {
1582 if (MEs.
iRing !=
nullptr) {
MonitorElement * ClusterStoNCorr
ClusterRef cluster() const
MonitorElement * ClusterStoNCorr_OnTrack_FECSlotVsFECRing_TIBTID
uint8_t maxCharge() const
MonitorElement * ClusterNoiseOnTrack
double p() const
momentum vector magnitude
T getParameter(std::string const &) const
EventNumber_t event() const
struct SubDetMEs * iSubdet
void return2DME(MonitorElement *input1, MonitorElement *input2, int binx, int biny, double value)
Det2MEs findMEs(const TrackerTopology *tTopo, const uint32_t detid)
MonitorElement * ClusterStoNCorr_OnTrack_TECP
MonitorElement * ClusterChargePerCMfromTrack
boost::transform_iterator< IterHelp, const_IdIter > const_iterator
TkHistoMap * tkhisto_NumOffTrack
void setBinContent(int binx, double content)
set content of bin (1-D)
uint16_t firstStrip() const
void addActiveDetectorsRawIds(std::vector< uint32_t > &) const
SiStripMonitorTrack(const edm::ParameterSet &)
~SiStripMonitorTrack() override
TkHistoMap * tkhisto_ClusterWidthOnTrack
iterator find(det_id_type id)
void setSiStripFolderName(std::string name)
void trackStudy(const edm::Event &ev, const edm::EventSetup &es)
edm::EDGetTokenT< reco::TrackCollection > trackToken_
MonitorElement * ClusterChargeRawOffTrack
const GeomDetUnit * monoDet() const
FWCore Framework interface EventSetupRecordImplementation h
Helper function to determine trigger accepts.
void fillME(MonitorElement *ME, float value1)
const TrackExtraRef & extra() const
reference to "extra" object
std::pair< const std::string, const char * > getSubDetFolderAndTag(const uint32_t &detid, const TrackerTopology *tTopo)
void setAxisRange(double xmin, double xmax, int axis=1)
set x-, y- or z-axis range (axis=1, 2, 3 respectively)
SiStripDCSStatus * dcsStatus_
MonitorElement * nClustersTrendOnTrack
double normalizedChi2() const
chi-squared divided by n.d.o.f. (or chi-squared * 1e6 if n.d.o.f. is zero)
const DetContainer & detUnits() const override
Returm a vector of all GeomDet.
MonitorElement * bookProfile(Args &&...args)
MonitorElement * ClusterPosOffTrack
MonitorElement * ClusterPosOnTrack
bool getByToken(EDGetToken token, Handle< PROD > &result) const
float noiseRescaledByGain() const
MonitorElement * ClusterGain
void book(DQMStore::IBooker &, const TrackerTopology *tTopo)
MonitorElement * ClusterStoNCorrOnTrack
void AllClusters(const edm::Event &ev, const edm::EventSetup &es)
math::XYZTLorentzVectorD LV
size_t recHitsSize() const
Get number of RecHits. (Warning, this includes invalid hits, which are not physical hits)...
MonitorElement * ClusterStoNOffTrack
MonitorElement * ClusterChargeOnTrack
bool IsStripBad(const uint32_t &detid, const short &strip) const
std::map< std::string, RingMEs > RingMEsMap
GlobalPoint toGlobal(const Local2DPoint &lp) const
Conversion to the global R.F. from the R.F. of the GeomDet.
std::string topFolderName_
Global3DPoint GlobalPoint
std::vector< Track > TrackCollection
collection of Tracks
void setBinLabel(int bin, const std::string &label, int axis=1)
set bin label for x, y or z axis (axis=1, 2, 3 respectively)
MonitorElement * ClusterStoNCorrThinOnTrack
LocalPoint toLocal(const GlobalPoint &gp) const
Conversion to the R.F. of the GeomDet.
MonitorElement * bookME1D(DQMStore::IBooker &, const char *, const char *)
MonitorElement * ClusterChargePerCMfromTrack
void setLayerFolder(uint32_t rawdetid, const TrackerTopology *tTopo, int32_t layer=0, bool ring_flag=false)
SiStripDetId::ModuleGeometry moduleGeometry(const DetId &id) const
MonitorElement * ClusterChargeCorrOnTrack
Provides a code based selection for trigger and DCS information in order to have no failing filters i...
MonitorElement * ClusterChargeRawOffTrack
data_type const * const_iterator
std::string TrackProducer_
bool trackFilter(const reco::Track &track)
edm::ESHandle< SiStripDetCabling > SiStripDetCabling_
void bookLayerMEs(DQMStore::IBooker &, const uint32_t, std::string &)
MonitorElement * ClusterChargeCorr
MonitorElement * ClusterGain
uint16_t maxIndex() const
auto stripCharges() const -> decltype(cluster() ->amplitudes())
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
MonitorElement * ClusterChargeOffTrack
MonitorElement * ClusterStoNCorr_OnTrack_FECSlotVsFECRing_TECM
MonitorElement * ClusterStoNCorrOnTrack
MonitorElement * ClusterChargePerCMfromOriginOffTrack
bool clusterInfos(SiStripClusterInfo *cluster, const uint32_t detid, enum ClusterFlags flags, bool track_ok, LocalVector LV, const Det2MEs &MEs, const TrackerTopology *tTopo, const SiStripGain *stripGain, const SiStripQuality *stripQuality, const edm::DetSetVector< SiStripDigi > &digilist)
MonitorElement * ClusterPGV
MonitorElement * ClusterChargeCorrThinOnTrack
MonitorElement * nClustersTrendOffTrack
void setDetectorFolder(uint32_t rawdetid, const TrackerTopology *tTopo)
TkHistoMap * tkhisto_NoiseOnTrack
uint32_t rawId() const
get the raw id
edm::ESHandle< TrackerGeometry > tkgeom_
MonitorElement * ClusterCharge
const std::vector< const FedChannelConnection * > & getConnections(uint32_t det_id) const
bool getStatus(edm::Event const &e, edm::EventSetup const &eSetup)
const TrackerGeomDet * idToDetUnit(DetId) const override
Return the pointer to the GeomDetUnit corresponding to a given DetId.
edmNew::DetSet< SiStripCluster >::const_iterator ClusIter
float signalOverNoise() const
MonitorElement * ClusterCount_OnTrack_FECCratevsFECSlot
MonitorElement * ClusterChargeRawOnTrack
MonitorElement * ClusterChargeRaw
vector< ParameterSet > Parameters
MonitorElement * ClusterStoNCorr_OnTrack_TOB
MonitorElement * ClusterGain
edm::EventNumber_t eventNb
TkHistoMap * tkhisto_NumMissingHits
std::unordered_set< const SiStripCluster * > vPSiStripCluster
std::map< std::string, SubDetMEs > SubDetMEsMap
MonitorElement * ClusterChargeOffTrack
static float getStripGain(const uint16_t &strip, const SiStripApvGain::Range &range)
MonitorElement * nClustersOnTrack
ConsumesCollector consumesCollector()
Use a ConsumesCollector to gather consumes information from helper functions.
void fill(uint32_t &detid, float value)
bool accept(const edm::Event &event, const edm::EventSetup &setup)
To be called from analyze/filter() methods.
double pt() const
track transverse momentum
const std::string subdet_tag("SubDet")
MonitorElement * ClusterStoNCorrOnTrack
MonitorElement * bookME2D(DQMStore::IBooker &, const char *, const char *)
MonitorElement * ClusterNoiseOffTrack
MonitorElement * book1D(Args &&...args)
void tag(MonitorElement *, unsigned int)
MonitorElement * ClusterWidthOnTrack
void bookSubDetMEs(DQMStore::IBooker &, std::string &name)
MonitorElement * bookME3D(DQMStore::IBooker &, const char *, const char *)
ClusterRef cluster() const
void dqmBeginRun(const edm::Run &run, const edm::EventSetup &es) override
MonitorElement * ClusterChargePerCMfromOrigin
trackingRecHit_iterator recHitsBegin() const
Iterator to first hit on the track.
MonitorElement * ClusterChargePerCMfromOriginOffTrack
SiStripFolderOrganizer folderOrganizer_
std::string getSubdetid(uint32_t id, const TrackerTopology *tTopo, bool flag_ring)
MonitorElement * ClusterChargePerCMfromTrack
MonitorElement * ClusterChargeOnTrack
MonitorElement * ClusterCount_OnTrack_FECSlotVsFECRing_TOB
MonitorElement * ClusterNoiseOffTrack
edm::EDGetTokenT< edm::DetSetVector< SiStripDigi > > digiToken_
TkHistoMap * tkhisto_ClusterWidthOffTrack
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
iterator end()
Return the off-the-end iterator.
MonitorElement * ClusterChargeCorrOnTrack
MonitorElement * ClusterChargeCorrThickOnTrack
TkHistoMap * tkhisto_NoiseOffTrack
MonitorElement * ClusterCount_OnTrack_FECSlotVsFECRing_TECM
SiStripRecHit2D originalHit() const
Detector identifier class for the strip tracker.
void trackStudyFromTrajectory(edm::Handle< reco::TrackCollection > trackCollectionHandle, const edm::DetSetVector< SiStripDigi > &digilist, const edm::Event &ev, const edm::EventSetup &es)
void bookModMEs(DQMStore::IBooker &, const uint32_t)
MonitorElement * ClusterChargeRawOnTrack
MonitorElement * ClusterWidth
MonitorElement * ClusterChargeOnTrack
TkHistoMap * tkhisto_NumberInactiveHits
void setCurrentFolder(const std::string &fullpath)
TkHistoMap * tkhisto_ClChPerCMfromOrigin
SiStripRecHit2D stereoHit() const
MonitorElement * ClusterStoNCorr_OnTrack_FECCratevsFECSlot
T const * product() const
MonitorElement * book2D(Args &&...args)
MonitorElement * ClusterStoNCorr_OnTrack_FECSlotVsFECRing_TECP
const HitPattern & hitPattern() const
Access the hit pattern, indicating in which Tracker layers the track has hits.
MonitorElement * ClusterWidthOffTrack
std::string createHistoId(std::string description, std::string id_type, uint32_t component_id)
MonitorElement * ClusterPosOnTrack
MonitorElement * ClusterChargePerCMfromTrack
void hitStudy(const edm::Event &ev, const edm::EventSetup &es, const edm::DetSetVector< SiStripDigi > &digilist, const ProjectedSiStripRecHit2D *projhit, const SiStripMatchedRecHit2D *matchedhit, const SiStripRecHit2D *hit2D, const SiStripRecHit1D *hit1D, LocalVector localMomentum, const bool track_ok)
MonitorElement * ClusterPosOffTrack
void RecHitInfo(const T *tkrecHit, LocalVector LV, const edm::DetSetVector< SiStripDigi > &digilist, const edm::Event &ev, const edm::EventSetup &es, bool ok)
MonitorElement * ClusterChargeOffTrack
std::map< std::string, ModMEs > ModMEsMap
MonitorElement * bookMETrend(DQMStore::IBooker &, const char *)
MonitorElement * ClusterPos
void trackStudyFromTrack(edm::Handle< reco::TrackCollection > trackCollectionHandle, const edm::DetSetVector< SiStripDigi > &digilist, const edm::Event &ev, const edm::EventSetup &es)
TkHistoMap * tkhisto_ClChPerCMfromTrack
MonitorElement * ClusterChargeCorrOnTrack
std::pair< std::string, int32_t > GetSubDetAndLayer(const uint32_t &detid, const TrackerTopology *tTopo, bool ring_flag=false)
MonitorElement * ClusterStoNCorr_OnTrack_FECSlotVsFECRing_TOB
int numberOfValidTrackerHits() const
TkHistoMap * tkhisto_NumOnTrack
MonitorElement * ClusterStoNCorr_OnTrack_TIBTID
SiStripRecHit2D monoHit() const
GenericTriggerEventFlag * genTriggerEventFlag_
const uint16_t nApvPairs(uint32_t det_id) const
MonitorElement * ClusterChargeRawOnTrack
MonitorElement * ClusterChargePerCMfromOriginOnTrack
double getBinContent(int binx) const
get content of bin (1-D)
const Range getRange(const uint32_t detID) const
MonitorElement * handleBookMEs(DQMStore::IBooker &, std::string &, std::string &, std::string &, std::string &)
static int position[264][3]
const TrackerGeomDet * idToDet(DetId) const override
MonitorElement * ClusterWidthOnTrack
MonitorElement * ClusterCount_OnTrack_FECSlotVsFECRing_TIBTID
MonitorElement * bookMEProfile(DQMStore::IBooker &, const char *, const char *)
MonitorElement * ClusterGain
TkHistoMap * tkhisto_StoNCorrOnTrack
DetId geographicalId() const
bool clchCMoriginTkHmap_On_
void initRun(const edm::Run &run, const edm::EventSetup &setup)
To be called from beginRun() methods.
MonitorElement * ClusterChargePerCMfromOriginOnTrack
std::string createHistoLayer(std::string description, std::string id_type, std::string path, std::string flag)
Detector det() const
get the detector field from this detid
MonitorElement * book3D(Args &&...args)
MonitorElement * ClusterWidthOffTrack
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
MonitorElement * nClustersOffTrack
void bookRingMEs(DQMStore::IBooker &, const uint32_t, std::string &)
T const * product() const
MonitorElement * ClusterStoNCorrThickOnTrack
MonitorElement * ClusterChargePerCMfromOriginOnTrack
void add(uint32_t &detid, float value)
TkHistoMap * tkhisto_NumberValidHits
bool applyClusterQuality_
edm::InputTag Cluster_src_
void analyze(const edm::Event &, const edm::EventSetup &) override
void trajectoryStudy(const reco::Track &track, const edm::DetSetVector< SiStripDigi > &digilist, const edm::Event &ev, const edm::EventSetup &es, bool track_ok)
const GeomDetUnit * stereoDet() const
MonitorElement * ClusterCount_OnTrack_FECSlotVsFECRing_TECP
TrackingRecHitCollection::base::const_iterator trackingRecHit_iterator
iterator over a vector of reference to TrackingRecHit in the same collection
bool fillControlViewHistos(const edm::Event &ev, const edm::EventSetup &es)
unsigned int tecSide(const DetId &id) const
MonitorElement * ClusterStoNCorr_OnTrack_TECM
MonitorElement * ClusterChargeRawOffTrack
const SiStripApvGain::Range getRange(uint32_t detID) const
edm::EDGetTokenT< edmNew::DetSetVector< SiStripCluster > > clusterToken_
std::map< std::string, LayerMEs > LayerMEsMap
MonitorElement * ClusterChargePerCMfromOriginOffTrack
MonitorElement * ClusterNoiseOnTrack