72 : storeNtuple_(iConfig.getParameter<
bool>(
"storeNtuple")),
73 lightNtupleSwitch_(iConfig.getParameter<
bool>(
"isLightNtuple")),
74 useTracksFromRecoVtx_(iConfig.getParameter<
bool>(
"useTracksFromRecoVtx")),
75 vertexZMax_(iConfig.getUntrackedParameter<double>(
"vertexZMax", 99.)),
76 intLumi_(iConfig.getUntrackedParameter<double>(
"intLumi", 0.)),
77 askFirstLayerHit_(iConfig.getParameter<
bool>(
"askFirstLayerHit")),
78 doBPix_(iConfig.getUntrackedParameter<
bool>(
"doBPix",
true)),
79 doFPix_(iConfig.getUntrackedParameter<
bool>(
"doFPix",
true)),
80 ptOfProbe_(iConfig.getUntrackedParameter<double>(
"probePt", 0.)),
81 pOfProbe_(iConfig.getUntrackedParameter<double>(
"probeP", 0.)),
82 etaOfProbe_(iConfig.getUntrackedParameter<double>(
"probeEta", 2.4)),
83 nHitsOfProbe_(iConfig.getUntrackedParameter<double>(
"probeNHits", 0.)),
84 nBins_(iConfig.getUntrackedParameter<
int>(
"numberOfBins", 24)),
85 minPt_(iConfig.getUntrackedParameter<double>(
"minPt", 1.)),
86 maxPt_(iConfig.getUntrackedParameter<double>(
"maxPt", 20.)),
87 debug_(iConfig.getParameter<
bool>(
"Debug")),
88 runControl_(iConfig.getUntrackedParameter<
bool>(
"runControl",
false)),
89 forceBeamSpotContraint_(iConfig.getUntrackedParameter<
bool>(
"forceBeamSpot",
false)) {
95 std::vector<unsigned int> defaultRuns;
96 defaultRuns.push_back(0);
114 if (clusteringAlgorithm ==
"gap") {
118 }
else if (clusteringAlgorithm ==
"DA") {
123 }
else if (clusteringAlgorithm ==
"DA_vect") {
128 throw VertexException(
"PrimaryVertexProducerAlgorithm: unknown clustering algorithm: " + clusteringAlgorithm);
141 auto plot_index = static_cast<PVValHelper::plotVariable>(
i);
142 auto res_index = static_cast<PVValHelper::residualType>(
j);
159 edm::LogVerbatim(
"PrimaryVertexValidation") <<
"######################################";
164 << std::setw(5) << it.second.second <<
") |" << std::endl;
191 toOutput += std::to_string(ptbin);
195 edm::LogVerbatim(
"PrimaryVertexValidation") <<
"######################################\n";
196 edm::LogVerbatim(
"PrimaryVertexValidation") <<
"The pT binning is: [" << toOutput <<
"] \n";
212 using namespace reco;
217 <<
"*********************************************************************************\n"
218 <<
"* The configuration (ptOfProbe > " <<
ptOfProbe_
219 <<
"GeV) is not correctly set for current value of magnetic field \n"
220 <<
"* Switching it to 0. !!! \n"
221 <<
"*********************************************************************************" << std::endl;
229 bool passesRunControl =
false;
233 if (
iEvent.eventAuxiliary().run() == runControlNumber) {
236 <<
" run number: " <<
iEvent.eventAuxiliary().run() <<
" keeping run:" << runControlNumber;
238 passesRunControl =
true;
242 if (!passesRunControl)
275 edm::LogInfo(
"tracker geometry read") <<
"There are: " << pDD->
dets().size() <<
" detectors";
328 double fBfield_ = ((*theB_).field()->inTesla(
GlobalPoint(0., 0., 0.))).
z();
336 if (!trackCollectionHandle.
isValid())
338 auto const&
tracks = *trackCollectionHandle;
358 LogTrace(
"PrimaryVertexValidation") <<
"caught std::exception " << er.
what() << std::endl;
361 std::vector<Vertex> vsorted = *(
vertices);
375 if (vsorted[0].isValid()) {
392 unsigned int vertexCollectionSize = vsorted.size();
395 for (
unsigned int i = 0;
i < vertexCollectionSize;
i++) {
408 double chi2prob = 0.;
410 if (!vsorted.at(0).isFake()) {
413 ntracks =
pv.tracksSize();
414 chi2ndf =
pv.normalizedChi2();
415 chi2prob = TMath::Prob(
pv.chi2(), (
int)
pv.ndof());
422 double pt = (**itrk).pt();
427 double dxyRes = (**itrk).dxy(myVertex);
428 double dzRes = (**itrk).dz(myVertex);
430 double dxy_err = (**itrk).dxyError();
431 double dz_err = (**itrk).dzError();
433 float trackphi = ((**itrk).phi()) * (180 /
M_PI);
434 float tracketa = (**itrk).eta();
443 if (tracketa >= etaF && tracketa < etaL) {
450 if (trackphi >= phiF && trackphi < phiL) {
460 if (tracketa >= etaJ && tracketa < etaK) {
484 if (beamSpotHandle.
isValid()) {
521 const time_t start_time = times.first / 1000000;
523 <<
RunNumber_ <<
" has start time: " << times.first <<
" - " << times.second << std::endl;
525 <<
"human readable time: " << std::asctime(std::gmtime(&start_time)) << std::endl;
539 edm::LogInfo(
"PrimaryVertexValidation") <<
" looping over " << trackCollectionHandle->size() <<
"tracks";
541 h_nTracks->Fill(trackCollectionHandle->size());
547 std::vector<TransientTrack> t_tks;
555 edm::LogInfo(
"PrimaryVertexValidation") <<
"Found: " << t_tks.size() <<
" reconstructed tracks";
572 <<
" looping over: " <<
clusters.size() <<
" clusters from " << t_tks.size() <<
" selected tracks";
581 for (
const auto& iclus :
clusters) {
585 for (
const auto& theTTrack : iclus) {
594 const Track& theTrack = theTTrack.track();
628 int nhitinTIB =
hits.numberOfValidStripTIBHits();
629 int nhitinTOB =
hits.numberOfValidStripTOBHits();
630 int nhitinTID =
hits.numberOfValidStripTIDHits();
631 int nhitinTEC =
hits.numberOfValidStripTECHits();
632 int nhitinBPIX =
hits.numberOfValidPixelBarrelHits();
633 int nhitinFPIX =
hits.numberOfValidPixelEndcapHits();
635 if ((*iHit)->isValid()) {
669 vector<TransientTrack> theFinalTracks;
670 theFinalTracks.clear();
672 for (
const auto& tk : iclus) {
678 theFinalTracks.push_back(tk);
683 if (theFinalTracks.size() > 1) {
685 edm::LogInfo(
"PrimaryVertexValidation") <<
"Transient Track Collection size: " << theFinalTracks.size();
692 theFittedVertex = theFitter->vertex(theFinalTracks,
beamSpot);
694 theFittedVertex = theFitter->vertex(theFinalTracks);
697 double totalTrackWeights = 0;
698 if (theFittedVertex.isValid()) {
699 if (theFittedVertex.hasTrackWeight()) {
700 for (
const auto& theFinalTrack : theFinalTracks) {
702 totalTrackWeights += theFittedVertex.trackWeight(theFinalTrack);
711 theFittedVertex.position().x(), theFittedVertex.position().y(), theFittedVertex.position().z());
725 TMath::Prob(theFittedVertex.totalChiSquared(), (
int)theFittedVertex.degreesOfFreedom());
733 TMath::Prob(theFittedVertex.totalChiSquared(), (
int)theFittedVertex.degreesOfFreedom()));
736 double dxyFromMyVertex = theTrack.
dxy(myVertex);
737 double dzFromMyVertex = theTrack.
dz(myVertex);
740 theFittedVertex.position().x(), theFittedVertex.position().y(), theFittedVertex.position().z());
746 double dz_err =
sqrt(
std::pow(theTrack.
dzError(), 2) + theFittedVertex.positionError().czz());
750 theTTrack,
GlobalVector(theTrack.
px(), theTrack.
py(), theTrack.
pz()), theFittedVertex);
752 double s_ip2dpv_corr = s_ip2dpv.second.value();
753 double s_ip2dpv_err = s_ip2dpv.second.error();
757 theTTrack,
GlobalVector(theTrack.
px(), theTrack.
py(), theTrack.
pz()), theFittedVertex);
759 double s_ip3dpv_corr = s_ip3dpv.second.value();
760 double s_ip3dpv_err = s_ip3dpv.second.error();
764 double ip3d_corr = ip3dpv.second.value();
765 double ip3d_err = ip3dpv.second.error();
773 float my_dx = refPoint.
x() - myVertex.x();
774 float my_dy = refPoint.
y() - myVertex.y();
776 float my_dx2 = cPToVtx.
x() - myVertex.x();
777 float my_dy2 = cPToVtx.
y() - myVertex.y();
779 float my_dxy =
std::sqrt(my_dx * my_dx + my_dy * my_dy);
788 <<
"my_dx:" << my_dx <<
" my_dy:" << my_dy <<
" my_dxy:" << my_dxy <<
" my_dx2:" << my_dx2
789 <<
" my_dy2:" << my_dy2 <<
" d0: " <<
d0 <<
" dxyFromVtx:" << dxyFromMyVertex <<
"\n"
790 <<
" ============================== "
794 <<
"diff3:" << (my_dx - my_dx2) <<
" " << (my_dy - my_dy2) <<
"\n"
814 float trackphi = (theTrack.
phi()) * (180. /
M_PI);
815 float tracketa = theTrack.
eta();
816 float trackpt = theTrack.
pt();
817 float trackp = theTrack.
p();
822 int ladder_num = -1.;
823 int module_num = -1.;
824 int L1BPixHitCount = 0;
827 const DetId& detId =
hit->geographicalId();
828 unsigned int subid = detId.
subdetId();
833 const SiPixelRecHit* prechit = dynamic_cast<const SiPixelRecHit*>(
836 if (clusterProbability > 0) {
853 if (module_num > 0 && ladder_num > 0) {
862 for (
int ipTBin = 0; ipTBin <
nPtBins_; ipTBin++) {
868 <<
" < pT < " <<
mypT_bins_[ipTBin + 1] << std::endl;
870 if (
std::abs(tracketa) < 1.5 && (trackpt >= pTF && trackpt < pTL)) {
881 <<
"passes tight eta cut: " <<
mypT_bins_[ipTBin] << std::endl;
896 if (pixelOcc.first ==
true)
897 edm::LogInfo(
"PrimaryVertexValidation") <<
"has BPIx hits" << std::endl;
898 if (pixelOcc.second ==
true)
899 edm::LogInfo(
"PrimaryVertexValidation") <<
"has FPix hits" << std::endl;
902 if (!
doBPix_ && (pixelOcc.first ==
true))
904 if (!
doFPix_ && (pixelOcc.second ==
true))
932 float dxyRecoV = theTrack.
dz(theRecoVertex);
933 float dzRecoV = theTrack.
dxy(theRecoVertex);
934 float dxysigmaRecoV =
939 double zTrack = (theTTrack.stateAtBeamLine().trackStateAtPCA()).
position().z();
940 double zVertex = theFittedVertex.position().z();
941 double tantheta =
tan((theTTrack.stateAtBeamLine().trackStateAtPCA()).momentum().theta());
944 double restrkz = zTrack -
zVertex;
945 double pulltrkz = (zTrack -
zVertex) / TMath::Sqrt(dz2);
970 n_dxyVsPhi->Fill(trackphi, dxyFromMyVertex / s_ip2dpv_err);
975 n_dxyVsEta->Fill(tracketa, dxyFromMyVertex / s_ip2dpv_err);
978 if (ladder_num > 0 && module_num > 0) {
980 <<
" ladder_num" << ladder_num <<
" module_num" << module_num << std::endl;
991 if (L1BPixHitCount == 1) {
1012 if (tracketa >= etaF && tracketa < etaL) {
1029 if (trackphi >= phiF && trackphi < phiL) {
1049 if (tracketa >= etaJ && tracketa < etaK) {
1064 <<
" myVertex.x()= " << myVertex.x() <<
"\n"
1065 <<
" myVertex.y()= " << myVertex.y() <<
" \n"
1066 <<
" myVertex.z()= " << myVertex.z() <<
" \n"
1067 <<
" theTrack.dz(myVertex)= " << theTrack.
dz(myVertex) <<
" \n"
1068 <<
" zPCA -myVertex.z() = " << (theTrack.
vertex().z() - myVertex.z());
1076 LogTrace(
"PrimaryVertexValidation") <<
"caught std::exception " << er.
what() << std::endl;
1083 edm::LogInfo(
"PrimaryVertexValidation") <<
"Not enough tracks to make a vertex. Returns no vertex info";
1090 edm::LogInfo(
"PrimaryVertexValidation") <<
"Track " <<
i <<
" : pT = " << theTrack.
pt();
1104 if (
hit.dimension() < 2) {
1107 const DetId detId(
hit.geographicalId());
1112 if (dynamic_cast<const SiStripRecHit2D*>(&
hit))
1114 else if (dynamic_cast<const SiStripMatchedRecHit2D*>(&
hit))
1116 else if (dynamic_cast<const ProjectedSiStripRecHit2D*>(&
hit))
1119 edm::LogError(
"UnkownType") <<
"@SUB=AlignmentTrackSelector::isHit2D"
1120 <<
"Tracker hit not in pixel and neither SiStripRecHit2D nor "
1121 <<
"SiStripMatchedRecHit2D nor ProjectedSiStripRecHit2D.";
1126 edm::LogWarning(
"DetectorMismatch") <<
"@SUB=AlignmentTrackSelector::isHit2D"
1127 <<
"Hit not in tracker with 'official' dimension >=2.";
1136 bool hasBPixHits =
false;
1137 bool hasFPixHits =
false;
1140 if (
p.numberOfValidPixelEndcapHits() != 0) {
1143 if (
p.numberOfValidPixelBarrelHits() != 0) {
1147 return std::make_pair(hasBPixHits, hasFPixHits);
1152 using namespace reco;
1154 for (
int i = 0;
i <
p.numberOfAllHits(HitPattern::TRACK_HITS);
i++) {
1155 uint32_t
pattern =
p.getHitPattern(HitPattern::TRACK_HITS,
i);
1169 edm::LogInfo(
"PrimaryVertexValidation") <<
"######################################\n"
1171 <<
"######################################";
1262 TH1F::SetDefaultSumw2(kTRUE);
1265 EventFeatures.
make<TH1F>(
"h_lumiFromConfig",
"luminosity from config;;luminosity of present run", 1, -0.5, 0.5);
1269 "run number from config;;run number (from configuration)",
1278 EventFeatures.
make<TH1I>(
"h_runFromEvent",
"run number from config;;run number (from event)", 1, -0.5, 0.5);
1280 EventFeatures.
make<TH1F>(
"h_nTracks",
"number of tracks per event;n_{tracks}/event;n_{events}", 300, -0.5, 299.5);
1282 EventFeatures.
make<TH1F>(
"h_nClus",
"number of track clusters;n_{clusters}/event;n_{events}", 50, -0.5, 49.5);
1284 "h_nOfflineVertices",
"number of offline reconstructed vertices;n_{vertices}/event;n_{events}", 50, -0.5, 49.5);
1285 h_runNumber = EventFeatures.
make<TH1F>(
"h_runNumber",
"run number;run number;n_{events}", 100000, 250000., 350000.);
1287 "h_xOfflineVertex",
"x-coordinate of offline vertex;x_{vertex};n_{events}", 100, -0.1, 0.1);
1289 "h_yOfflineVertex",
"y-coordinate of offline vertex;y_{vertex};n_{events}", 100, -0.1, 0.1);
1291 "h_zOfflineVertex",
"z-coordinate of offline vertex;z_{vertex};n_{events}", 100, -30., 30.);
1293 "h_xErrOfflineVertex",
"x-coordinate error of offline vertex;err_{x}^{vtx};n_{events}", 100, 0., 0.01);
1295 "h_yErrOfflineVertex",
"y-coordinate error of offline vertex;err_{y}^{vtx};n_{events}", 100, 0., 0.01);
1297 "h_zErrOfflineVertex",
"z-coordinate error of offline vertex;err_{z}^{vtx};n_{events}", 100, 0., 10.);
1298 h_BSx0 = EventFeatures.
make<TH1F>(
"h_BSx0",
"x-coordinate of reco beamspot;x^{BS}_{0};n_{events}", 100, -0.1, 0.1);
1299 h_BSy0 = EventFeatures.
make<TH1F>(
"h_BSy0",
"y-coordinate of reco beamspot;y^{BS}_{0};n_{events}", 100, -0.1, 0.1);
1300 h_BSz0 = EventFeatures.
make<TH1F>(
"h_BSz0",
"z-coordinate of reco beamspot;z^{BS}_{0};n_{events}", 100, -1., 1.);
1302 EventFeatures.
make<TH1F>(
"h_Beamsigmaz",
"z-coordinate beam width;#sigma_{Z}^{beam};n_{events}", 100, 0., 1.);
1304 EventFeatures.
make<TH1F>(
"h_BeamWidthX",
"x-coordinate beam width;#sigma_{X}^{beam};n_{events}", 100, 0., 0.01);
1306 EventFeatures.
make<TH1F>(
"h_BeamWidthY",
"y-coordinate beam width;#sigma_{Y}^{beam};n_{events}", 100, 0., 0.01);
1308 h_etaMax = EventFeatures.
make<TH1F>(
"etaMax",
"etaMax", 1, -0.5, 0.5);
1309 h_pTinfo = EventFeatures.
make<TH1F>(
"pTinfo",
"pTinfo", 3, -1.5, 1.5);
1310 h_pTinfo->GetXaxis()->SetBinLabel(1,
"n. bins");
1311 h_pTinfo->GetXaxis()->SetBinLabel(2,
"pT min");
1312 h_pTinfo->GetXaxis()->SetBinLabel(3,
"pT max");
1314 h_nbins = EventFeatures.
make<TH1F>(
"nbins",
"nbins", 1, -0.5, 0.5);
1315 h_nLadders = EventFeatures.
make<TH1F>(
"nladders",
"n. ladders", 1, -0.5, 0.5);
1320 h_probePt_ = ProbeFeatures.
make<TH1F>(
"h_probePt",
"p_{T} of probe track;track p_{T} (GeV); tracks", 100, 0., 50.);
1322 "h_probePtRebin",
"p_{T} of probe track;track p_{T} (GeV); tracks",
mypT_bins_.size() - 1,
mypT_bins_.data());
1323 h_probeP_ = ProbeFeatures.
make<TH1F>(
"h_probeP",
"momentum of probe track;track p (GeV); tracks", 100, 0., 100.);
1324 h_probeEta_ = ProbeFeatures.
make<TH1F>(
"h_probeEta",
"#eta of the probe track;track #eta;tracks", 54, -2.8, 2.8);
1325 h_probePhi_ = ProbeFeatures.
make<TH1F>(
"h_probePhi",
"#phi of probe track;track #phi (rad);tracks", 100, -3.15, 3.15);
1328 ProbeFeatures.
make<TH2F>(
"h2_probeEtaPhi",
1329 "probe track #phi vs #eta;#eta of probe track;track #phi of probe track (rad); tracks",
1337 "probe track p_{T} vs #eta;#eta of probe track;track p_{T} (GeV); tracks",
1346 ProbeFeatures.
make<TH1F>(
"h_probeChi2",
"#chi^{2} of probe track;track #chi^{2}; tracks", 100, 0., 100.);
1348 "h_probeNormChi2",
" normalized #chi^{2} of probe track;track #chi^{2}/ndof; tracks", 100, 0., 10.);
1350 ProbeFeatures.
make<TH1F>(
"h_probeCharge",
"charge of probe track;track charge Q;tracks", 3, -1.5, 1.5);
1352 ProbeFeatures.
make<TH1F>(
"h_probeQoverP",
"q/p of probe track; track Q/p (GeV^{-1});tracks", 200, -1., 1.);
1354 "h_probedzRecoV",
"d_{z}(V_{offline}) of probe track;track d_{z}(V_{off}) (cm);tracks", 200, -1., 1.);
1356 "h_probedxyRecoV",
"d_{xy}(V_{offline}) of probe track;track d_{xy}(V_{off}) (cm);tracks", 200, -1., 1.);
1358 "h_probedzRefitV",
"d_{z}(V_{refit}) of probe track;track d_{z}(V_{fit}) (cm);tracks", 200, -0.5, 0.5);
1360 "h_probesignIPRefitV",
"ip_{2D}(V_{refit}) of probe track;track ip_{2D}(V_{fit}) (cm);tracks", 200, -1., 1.);
1362 "h_probedxyRefitV",
"d_{xy}(V_{refit}) of probe track;track d_{xy}(V_{fit}) (cm);tracks", 200, -0.5, 0.5);
1365 "h_probez0RefitV",
"z_{0}(V_{refit}) of probe track;track z_{0}(V_{fit}) (cm);tracks", 200, -1., 1.);
1367 "h_probed0RefitV",
"d_{0}(V_{refit}) of probe track;track d_{0}(V_{fit}) (cm);tracks", 200, -1., 1.);
1370 "h_probed3DRefitV",
"d_{3D}(V_{refit}) of probe track;track d_{3D}(V_{fit}) (cm);tracks", 200, 0., 1.);
1372 "h_probeReszRefitV",
"z_{track} -z_{V_{refit}};track res_{z}(V_{refit}) (cm);tracks", 200, -1., 1.);
1375 "h_probeRecoVSigZ",
"Longitudinal DCA Significance (reco);d_{z}(V_{off})/#sigma_{dz};tracks", 100, -8, 8);
1377 "h_probeRecoVSigXY",
"Transverse DCA Significance (reco);d_{xy}(V_{off})/#sigma_{dxy};tracks", 100, -8, 8);
1379 "h_probeRefitVSigZ",
"Longitudinal DCA Significance (refit);d_{z}(V_{fit})/#sigma_{dz};tracks", 100, -8, 8);
1381 "h_probeRefitVSigXY",
"Transverse DCA Significance (refit);d_{xy}(V_{fit})/#sigma_{dxy};tracks", 100, -8, 8);
1383 "h_probeRefitVSig3D",
"3D DCA Significance (refit);d_{3D}/#sigma_{3D};tracks", 100, 0., 20.);
1385 ProbeFeatures.
make<TH1F>(
"h_probeRefitVLogSig3D",
1386 "log_{10}(3D DCA-Significance) (refit);log_{10}(d_{3D}/#sigma_{3D});tracks",
1391 "h_probeRefitVSigResZ",
1392 "Longitudinal residual significance (refit);(z_{track} -z_{V_{fit}})/#sigma_{res_{z}};tracks",
1397 h_probeHits_ = ProbeFeatures.
make<TH1F>(
"h_probeNRechits",
"N_{hits} ;N_{hits} ;tracks", 40, -0.5, 39.5);
1398 h_probeHits1D_ = ProbeFeatures.
make<TH1F>(
"h_probeNRechits1D",
"N_{hits} 1D ;N_{hits} 1D ;tracks", 40, -0.5, 39.5);
1399 h_probeHits2D_ = ProbeFeatures.
make<TH1F>(
"h_probeNRechits2D",
"N_{hits} 2D ;N_{hits} 2D ;tracks", 40, -0.5, 39.5);
1401 ProbeFeatures.
make<TH1F>(
"h_probeNRechitsTIB",
"N_{hits} TIB ;N_{hits} TIB;tracks", 40, -0.5, 39.5);
1403 ProbeFeatures.
make<TH1F>(
"h_probeNRechitsTOB",
"N_{hits} TOB ;N_{hits} TOB;tracks", 40, -0.5, 39.5);
1405 ProbeFeatures.
make<TH1F>(
"h_probeNRechitsTID",
"N_{hits} TID ;N_{hits} TID;tracks", 40, -0.5, 39.5);
1407 ProbeFeatures.
make<TH1F>(
"h_probeNRechitsTEC",
"N_{hits} TEC ;N_{hits} TEC;tracks", 40, -0.5, 39.5);
1409 ProbeFeatures.
make<TH1F>(
"h_probeNRechitsBPIX",
"N_{hits} BPIX;N_{hits} BPIX;tracks", 40, -0.5, 39.5);
1411 ProbeFeatures.
make<TH1F>(
"h_probeNRechitsFPIX",
"N_{hits} FPIX;N_{hits} FPIX;tracks", 40, -0.5, 39.5);
1414 ProbeFeatures.
make<TH1F>(
"h_probeL1Ladder",
"Ladder number (L1 hit); ladder number", 22, -1.5, 20.5);
1416 ProbeFeatures.
make<TH1F>(
"h_probeL1Module",
"Module number (L1 hit); module number", 10, -1.5, 8.5);
1419 "h2_probeLayer1Map",
"Position in Layer 1 of first hit;module number;ladder number", 8, 0.5, 8.5, 12, 0.5, 12.5);
1421 "Position in Layer 1 of first hit;module number;ladder number",
1429 ProbeFeatures.
make<TH1I>(
"h_probeHasBPixL1Overlap",
"n. hits in L1;n. L1-BPix hits;tracks", 5, -0.5, 4.5);
1431 "h_probeL1ClusterProb",
1432 "log_{10}(Cluster Probability) for Layer1 hits;log_{10}(cluster probability); n. Layer1 hits",
1440 "h_fitVtxNtracks",
"N_{trks} used in vertex fit;N^{fit}_{tracks};vertices", 100, -0.5, 99.5);
1442 "h_fitVtxNdof",
"N_{DOF} of vertex fit;N_{DOF} of refit vertex;vertices", 100, -0.5, 99.5);
1444 "h_fitVtxChi2",
"#chi^{2} of vertex fit;vertex #chi^{2};vertices", 100, -0.5, 99.5);
1446 "h_fitVtxChi2ndf",
"#chi^{2}/ndf of vertex fit;vertex #chi^{2}/ndf;vertices", 100, -0.5, 9.5);
1448 "h_fitVtxChi2Prob",
"Prob(#chi^{2},ndf) of vertex fit;Prob(#chi^{2},ndf);vertices", 40, 0., 1.);
1450 "h_fitVtxTrackWeights",
"track weights associated to track;track weights;tracks", 40, 0., 1.);
1452 "h_fitVtxTrackAverageWeight_",
"average track weight per vertex;#LT track weight #GT;vertices", 40, 0., 1.);
1457 RecoVertexFeatures.
make<TH1F>(
"h_recoVtxNtracks",
"N^{vtx}_{trks};N^{vtx}_{trks};vertices", 100, -0.5, 99.5);
1459 RecoVertexFeatures.
make<TH1F>(
"h_recoVtxChi2ndf",
"#chi^{2}/ndf vtx;#chi^{2}/ndf vtx;vertices", 10, -0.5, 9.5);
1461 "h_recoVtxChi2Prob",
"Prob(#chi^{2},ndf);Prob(#chi^{2},ndf);vertices", 40, 0., 1.);
1463 RecoVertexFeatures.
make<TH1F>(
"h_recoVtxSumPt",
"Sum(p^{trks}_{T});Sum(p^{trks}_{T});vertices", 100, 0., 200.);
1628 for (
unsigned int iLadder = 0; iLadder <
nLadders_; iLadder++) {
1629 for (
unsigned int iModule = 0; iModule < 8; iModule++) {
1631 AbsL1Map.
make<TH1F>(Form(
"histo_dxy_ladder%i_module%i", iLadder, iModule),
1632 Form(
"d_{xy} ladder=%i module=%i;d_{xy} [#mum];tracks", iLadder, iModule),
1638 AbsL1Map.
make<TH1F>(Form(
"histo_dz_ladder%i_module%i", iLadder, iModule),
1639 Form(
"d_{z} ladder=%i module=%i;d_{z} [#mum];tracks", iLadder, iModule),
1645 NormL1Map.
make<TH1F>(Form(
"histo_norm_dxy_ladder%i_module%i", iLadder, iModule),
1646 Form(
"d_{xy} ladder=%i module=%i;d_{xy}/#sigma_{d_{xy}};tracks", iLadder, iModule),
1652 NormL1Map.
make<TH1F>(Form(
"histo_norm_dz_ladder%i_module%i", iLadder, iModule),
1653 Form(
"d_{z} ladder=%i module=%i;d_{z}/#sigma_{d_{z}};tracks", iLadder, iModule),
1676 Form(
"histo_dxy_eta_plot%i_phi_plot%i",
i,
j),
1677 Form(
"%.2f<#eta_{tk}<%.2f %.2f#circ<#varphi_{tk}<%.2f#circ;d_{xy};tracks", etaF, etaL, phiF, phiL),
1683 Form(
"histo_dz_eta_plot%i_phi_plot%i",
i,
j),
1684 Form(
"%.2f<#eta_{tk}<%.2f %.2f#circ<#varphi_{tk}<%.2f#circ;d_{z};tracks", etaF, etaL, phiF, phiL),
1690 Form(
"histo_d3D_eta_plot%i_phi_plot%i",
i,
j),
1691 Form(
"%.2f<#eta_{tk}<%.2f %.2f#circ<#varphi_{tk}<%.2f#circ;d_{3D};tracks", etaF, etaL, phiF, phiL),
1697 Form(
"histo_norm_dxy_eta_plot%i_phi_plot%i",
i,
j),
1698 Form(
"%.2f<#eta_{tk}<%.2f %.2f#circ<#varphi_{tk}<%.2f#circ;d_{xy}/#sigma_{d_{xy}};tracks",
1708 Form(
"histo_norm_dz_eta_plot%i_phi_plot%i",
i,
j),
1709 Form(
"%.2f<#eta_{tk}<%.2f %.2f#circ<#varphi_{tk}<%.2f#circ;d_{z}/#sigma_{d_{z}};tracks",
1719 Form(
"histo_norm_d3D_eta_plot%i_phi_plot%i",
i,
j),
1720 Form(
"%.2f<#eta_{tk}<%.2f %.2f#circ<#varphi_{tk}<%.2f#circ;d_{3D}/#sigma_{d_{3D}};tracks",
1736 "d_{xy} vs track #phi;track #phi [rad];track d_{xy}(PV) [#mum]",
1745 "d_{z} vs track #phi;track #phi [rad];track d_{z}(PV) [#mum]",
1755 "d_{xy}/#sigma_{d_{xy}} vs track #phi;track #phi [rad];track d_{xy}(PV)/#sigma_{d_{xy}}",
1764 BiasVsParameter.
make<TH2F>(
"h2_n_dz_vs_phi",
1765 "d_{z}/#sigma_{d_{z}} vs track #phi;track #phi [rad];track d_{z}(PV)/#sigma_{d_{z}}",
1774 "d_{xy} vs track #eta;track #eta;track d_{xy}(PV) [#mum]",
1783 "d_{z} vs track #eta;track #eta;track d_{z}(PV) [#mum]",
1792 BiasVsParameter.
make<TH2F>(
"h2_n_dxy_vs_eta",
1793 "d_{xy}/#sigma_{d_{xy}} vs track #eta;track #eta;track d_{xy}(PV)/#sigma_{d_{xy}}",
1802 "d_{z}/#sigma_{d_{z}} vs track #eta;track #eta;track d_{z}(PV)/#sigma_{d_{z}}",
1825 "#LT d_{xy} #GT vs #phi sector;#varphi (sector) [degrees];#LT d_{xy} #GT [#mum]",
1832 "#sigma_{d_{xy}} vs #phi sector;#varphi (sector) [degrees];#sigma_{d_{xy}} [#mum]",
1839 "#LT d_{z} #GT vs #phi sector;#varphi (sector) [degrees];#LT d_{z} #GT [#mum]",
1846 "#sigma_{d_{z}} vs #phi sector;#varphi (sector) [degrees];#sigma_{d_{z}} [#mum]",
1852 "means_dxy_eta",
"#LT d_{xy} #GT vs #eta sector;#eta (sector);#LT d_{xy} #GT [#mum]",
nBins_,
lowedge,
highedge);
1855 "#sigma_{d_{xy}} vs #eta sector;#eta (sector);#sigma_{d_{xy}} [#mum]",
1861 "means_dz_eta",
"#LT d_{z} #GT vs #eta sector;#eta (sector);#LT d_{z} #GT [#mum]",
nBins_,
lowedge,
highedge);
1864 "widths_dz_eta",
"#sigma_{d_{xy}} vs #eta sector;#eta (sector);#sigma_{d_{z}} [#mum]",
nBins_,
lowedge,
highedge);
1867 "norm_means_dxy_phi",
1868 "#LT d_{xy}/#sigma_{d_{xy}} #GT vs #phi sector;#varphi (sector) [degrees];#LT d_{xy}/#sigma_{d_{xy}} #GT",
1874 "norm_widths_dxy_phi",
1875 "width(d_{xy}/#sigma_{d_{xy}}) vs #phi sector;#varphi (sector) [degrees]; width(d_{xy}/#sigma_{d_{xy}})",
1881 "norm_means_dz_phi",
1882 "#LT d_{z}/#sigma_{d_{z}} #GT vs #phi sector;#varphi (sector) [degrees];#LT d_{z}/#sigma_{d_{z}} #GT",
1888 "norm_widths_dz_phi",
1889 "width(d_{z}/#sigma_{d_{z}}) vs #phi sector;#varphi (sector) [degrees];width(d_{z}/#sigma_{d_{z}})",
1895 "norm_means_dxy_eta",
1896 "#LT d_{xy}/#sigma_{d_{xy}} #GT vs #eta sector;#eta (sector);#LT d_{xy}/#sigma_{d_{z}} #GT",
1902 "norm_widths_dxy_eta",
1903 "width(d_{xy}/#sigma_{d_{xy}}) vs #eta sector;#eta (sector);width(d_{xy}/#sigma_{d_{z}})",
1910 "#LT d_{z}/#sigma_{d_{z}} #GT vs #eta sector;#eta (sector);#LT d_{z}/#sigma_{d_{z}} #GT",
1917 "width(d_{z}/#sigma_{d_{z}}) vs #eta sector;#eta (sector);width(d_{z}/#sigma_{d_{z}})",
1925 "#LT d_{xy} #GT vs pT;p_{T} [GeV];#LT d_{xy} #GT [#mum]",
1930 "#sigma_{d_{xy}} vs pT;p_{T} [GeV];#sigma_{d_{xy}} [#mum]",
1935 "means_dz_pT",
"#LT d_{z} #GT vs pT;p_{T} [GeV];#LT d_{z} #GT [#mum]",
mypT_bins_.size() - 1,
mypT_bins_.data());
1938 "#sigma_{d_{z}} vs pT;p_{T} [GeV];#sigma_{d_{z}} [#mum]",
1944 "#LT d_{xy}/#sigma_{d_{xy}} #GT vs pT;p_{T} [GeV];#LT d_{xy}/#sigma_{d_{xy}} #GT",
1950 "width(d_{xy}/#sigma_{d_{xy}}) vs pT;p_{T} [GeV]; width(d_{xy}/#sigma_{d_{xy}})",
1956 "#LT d_{z}/#sigma_{d_{z}} #GT vs pT;p_{T} [GeV];#LT d_{z}/#sigma_{d_{z}} #GT",
1962 "width(d_{z}/#sigma_{d_{z}}) vs pT;p_{T} [GeV];width(d_{z}/#sigma_{d_{z}})",
1968 "#LT d_{xy} #GT vs p_{T};p_{T}(|#eta|<1.) [GeV];#LT d_{xy} #GT [#mum]",
1974 "#sigma_{d_{xy}} vs p_{T};p_{T}(|#eta|<1.) [GeV];#sigma_{d_{xy}} [#mum]",
1980 "#LT d_{z} #GT vs p_{T};p_{T}(|#eta|<1.) [GeV];#LT d_{z} #GT [#mum]",
1986 "#sigma_{d_{z}} vs p_{T};p_{T}(|#eta|<1.) [GeV];#sigma_{d_{z}} [#mum]",
1991 "norm_means_dxy_pTCentral",
1992 "#LT d_{xy}/#sigma_{d_{xy}} #GT vs p_{T};p_{T}(|#eta|<1.) [GeV];#LT d_{xy}/#sigma_{d_{z}} #GT",
1997 "norm_widths_dxy_pTCentral",
1998 "width(d_{xy}/#sigma_{d_{xy}}) vs p_{T};p_{T}(|#eta|<1.) [GeV];width(d_{xy}/#sigma_{d_{z}})",
2003 "norm_means_dz_pTCentral",
2004 "#LT d_{z}/#sigma_{d_{z}} #GT vs p_{T};p_{T}(|#eta|<1.) [GeV];#LT d_{z}/#sigma_{d_{z}} #GT",
2009 "norm_widths_dz_pTCentral",
2010 "width(d_{z}/#sigma_{d_{z}}) vs p_{T};p_{T}(|#eta|<1.) [GeV];width(d_{z}/#sigma_{d_{z}})",
2017 "#LT d_{xy} #GT map;#eta (sector);#varphi (sector) [degrees]",
2026 "#LT d_{z} #GT map;#eta (sector);#varphi (sector) [degrees]",
2035 "#LT d_{xy}/#sigma_{d_{xy}} #GT map;#eta (sector);#varphi (sector) [degrees]",
2044 "#LT d_{z}/#sigma_{d_{z}} #GT map;#eta (sector);#varphi (sector) [degrees]",
2053 "#sigma_{d_{xy}} map;#eta (sector);#varphi (sector) [degrees]",
2062 "#sigma_{d_{z}} map;#eta (sector);#varphi (sector) [degrees]",
2072 "width(d_{xy}/#sigma_{d_{xy}}) map;#eta (sector);#varphi (sector) [degrees]",
2081 "width(d_{z}/#sigma_{d_{z}}) map;#eta (sector);#varphi (sector) [degrees]",
2093 "Median of d_{xy} vs #phi sector;#varphi (sector) [degrees];#mu_{1/2}(d_{xy}) [#mum]",
2100 "Median absolute deviation of d_{xy} vs #phi sector;#varphi (sector) [degrees];MAD(d_{xy}) [#mum]",
2107 "Median of d_{z} vs #phi sector;#varphi (sector) [degrees];#mu_{1/2}(d_{z}) [#mum]",
2114 "Median absolute deviation of d_{z} vs #phi sector;#varphi (sector) [degrees];MAD(d_{z}) [#mum]",
2121 "Median of d_{xy} vs #eta sector;#eta (sector);#mu_{1/2}(d_{xy}) [#mum]",
2128 "Median absolute deviation of d_{xy} vs #eta sector;#eta (sector);MAD(d_{xy}) [#mum]",
2135 "Median of d_{z} vs #eta sector;#eta (sector);#mu_{1/2}(d_{z}) [#mum]",
2142 "Median absolute deviation of d_{z} vs #eta sector;#eta (sector);MAD(d_{z}) [#mum]",
2148 "norm_medians_dxy_phi",
2149 "Median of d_{xy}/#sigma_{d_{xy}} vs #phi sector;#varphi (sector) [degrees];#mu_{1/2}(d_{xy}/#sigma_{d_{xy}})",
2155 "Median absolute deviation of d_{xy}/#sigma_{d_{xy}} vs #phi "
2156 "sector;#varphi (sector) [degrees]; MAD(d_{xy}/#sigma_{d_{xy}})",
2162 "norm_medians_dz_phi",
2163 "Median of d_{z}/#sigma_{d_{z}} vs #phi sector;#varphi (sector) [degrees];#mu_{1/2}(d_{z}/#sigma_{d_{z}})",
2169 "Median absolute deviation of d_{z}/#sigma_{d_{z}} vs #phi sector;#varphi "
2170 "(sector) [degrees];MAD(d_{z}/#sigma_{d_{z}})",
2176 "norm_medians_dxy_eta",
2177 "Median of d_{xy}/#sigma_{d_{xy}} vs #eta sector;#eta (sector);#mu_{1/2}(d_{xy}/#sigma_{d_{z}})",
2183 "norm_MADs_dxy_eta",
2184 "Median absolute deviation of d_{xy}/#sigma_{d_{xy}} vs #eta sector;#eta (sector);MAD(d_{xy}/#sigma_{d_{z}})",
2190 "norm_medians_dz_eta",
2191 "Median of d_{z}/#sigma_{d_{z}} vs #eta sector;#eta (sector);#mu_{1/2}(d_{z}/#sigma_{d_{z}})",
2198 "Median absolute deviation of d_{z}/#sigma_{d_{z}} vs #eta sector;#eta (sector);MAD(d_{z}/#sigma_{d_{z}})",
2247 Form(
"histo_dxy_eta_plot%i_phi_plot%i",
i,
j),
2248 Form(
"%.2f<#eta_{tk}<%.2f %.2f#circ<#varphi_{tk}<%.2f#circ;d_{xy} [#mum];tracks", etaF, etaL, phiF, phiL),
2254 Form(
"histo_dxy_eta_plot%i_phi_plot%i",
i,
j),
2255 Form(
"%.2f<#eta_{tk}<%.2f %.2f#circ<#varphi_{tk}<%.2f#circ;d_{z} [#mum];tracks", etaF, etaL, phiF, phiL),
2261 Form(
"histo_norm_dxy_eta_plot%i_phi_plot%i",
i,
j),
2262 Form(
"%.2f<#eta_{tk}<%.2f %.2f#circ<#varphi_{tk}<%.2f#circ;d_{xy}/#sigma_{d_{xy}};tracks",
2272 Form(
"histo_norm_dxy_eta_plot%i_phi_plot%i",
i,
j),
2273 Form(
"%.2f<#eta_{tk}<%.2f %.2f#circ<#varphi_{tk}<%.2f#circ;d_{z}/#sigma_{d_{z}};tracks",
2297 MeanBiasTrendsDir.
make<TH1F>(
"means_dxy_phi",
2298 "#LT d_{xy} #GT vs #phi sector;#varphi (sector) [degrees];#LT d_{xy} #GT [#mum]",
2305 "#sigma_{d_{xy}} vs #phi sector;#varphi (sector) [degrees];#sigma_{d_{xy}} [#mum]",
2311 MeanBiasTrendsDir.
make<TH1F>(
"means_dz_phi",
2312 "#LT d_{z} #GT vs #phi sector;#varphi (sector) [degrees];#LT d_{z} #GT [#mum]",
2318 WidthBiasTrendsDir.
make<TH1F>(
"widths_dz_phi",
2319 "#sigma_{d_{z}} vs #phi sector;#varphi (sector) [degrees];#sigma_{d_{z}} [#mum]",
2325 "means_dxy_eta",
"#LT d_{xy} #GT vs #eta sector;#eta (sector);#LT d_{xy} #GT [#mum]",
nBins_,
lowedge,
highedge);
2328 WidthBiasTrendsDir.
make<TH1F>(
"widths_dxy_eta",
2329 "#sigma_{d_{xy}} vs #eta sector;#eta (sector);#sigma_{d_{xy}} [#mum]",
2335 "means_dz_eta",
"#LT d_{z} #GT vs #eta sector;#eta (sector);#LT d_{z} #GT [#mum]",
nBins_,
lowedge,
highedge);
2338 WidthBiasTrendsDir.
make<TH1F>(
"widths_dz_eta",
2339 "#sigma_{d_{xy}} vs #eta sector;#eta (sector);#sigma_{d_{z}} [#mum]",
2345 "norm_means_dxy_phi",
2346 "#LT d_{xy}/#sigma_{d_{xy}} #GT vs #phi sector;#varphi (sector) [degrees];#LT d_{xy}/#sigma_{d_{xy}} #GT",
2352 "norm_widths_dxy_phi",
2353 "width(d_{xy}/#sigma_{d_{xy}}) vs #phi sector;#varphi (sector) [degrees]; width(d_{xy}/#sigma_{d_{xy}})",
2359 "norm_means_dz_phi",
2360 "#LT d_{z}/#sigma_{d_{z}} #GT vs #phi sector;#varphi (sector) [degrees];#LT d_{z}/#sigma_{d_{z}} #GT",
2366 "norm_widths_dz_phi",
2367 "width(d_{z}/#sigma_{d_{z}}) vs #phi sector;#varphi (sector) [degrees];width(d_{z}/#sigma_{d_{z}})",
2373 "norm_means_dxy_eta",
2374 "#LT d_{xy}/#sigma_{d_{xy}} #GT vs #eta sector;#eta (sector);#LT d_{xy}/#sigma_{d_{z}} #GT",
2380 "norm_widths_dxy_eta",
2381 "width(d_{xy}/#sigma_{d_{xy}}) vs #eta sector;#eta (sector);width(d_{xy}/#sigma_{d_{z}})",
2387 "norm_means_dz_eta",
2388 "#LT d_{z}/#sigma_{d_{z}} #GT vs #eta sector;#eta (sector);#LT d_{z}/#sigma_{d_{z}} #GT",
2394 "norm_widths_dz_eta",
2395 "width(d_{z}/#sigma_{d_{z}}) vs #eta sector;#eta (sector);width(d_{z}/#sigma_{d_{z}})",
2403 "#LT d_{xy} #GT map;#eta (sector);#varphi (sector) [degrees]",
2412 "#LT d_{z} #GT map;#eta (sector);#varphi (sector) [degrees]",
2421 Mean2DBiasMapsDir.
make<TH2F>(
"norm_means_dxy_map",
2422 "#LT d_{xy}/#sigma_{d_{xy}} #GT map;#eta (sector);#varphi (sector) [degrees]",
2431 Mean2DBiasMapsDir.
make<TH2F>(
"norm_means_dz_map",
2432 "#LT d_{z}/#sigma_{d_{z}} #GT map;#eta (sector);#varphi (sector) [degrees]",
2441 "#sigma_{d_{xy}} map;#eta (sector);#varphi (sector) [degrees]",
2450 "#sigma_{d_{z}} map;#eta (sector);#varphi (sector) [degrees]",
2459 Width2DBiasMapsDir.
make<TH2F>(
"norm_widths_dxy_map",
2460 "width(d_{xy}/#sigma_{d_{xy}}) map;#eta (sector);#varphi (sector) [degrees]",
2469 Width2DBiasMapsDir.
make<TH2F>(
"norm_widths_dz_map",
2470 "width(d_{z}/#sigma_{d_{z}}) map;#eta (sector);#varphi (sector) [degrees]",
2482 "Median of d_{xy} vs #phi sector;#varphi (sector) [degrees];#mu_{1/2}(d_{xy}) [#mum]",
2489 "Median absolute deviation of d_{xy} vs #phi sector;#varphi (sector) [degrees];MAD(d_{xy}) [#mum]",
2496 "Median of d_{z} vs #phi sector;#varphi (sector) [degrees];#mu_{1/2}(d_{z}) [#mum]",
2503 "Median absolute deviation of d_{z} vs #phi sector;#varphi (sector) [degrees];MAD(d_{z}) [#mum]",
2509 MedianBiasTrendsDir.
make<TH1F>(
"medians_dxy_eta",
2510 "Median of d_{xy} vs #eta sector;#eta (sector);#mu_{1/2}(d_{xy}) [#mum]",
2517 "Median absolute deviation of d_{xy} vs #eta sector;#eta (sector);MAD(d_{xy}) [#mum]",
2523 MedianBiasTrendsDir.
make<TH1F>(
"medians_dz_eta",
2524 "Median of d_{z} vs #eta sector;#eta (sector);#mu_{1/2}(d_{z}) [#mum]",
2530 MADBiasTrendsDir.
make<TH1F>(
"MADs_dz_eta",
2531 "Median absolute deviation of d_{z} vs #eta sector;#eta (sector);MAD(d_{z}) [#mum]",
2537 "norm_medians_dxy_phi",
2538 "Median of d_{xy}/#sigma_{d_{xy}} vs #phi sector;#varphi (sector) [degrees];#mu_{1/2}(d_{xy}/#sigma_{d_{xy}})",
2544 "Median absolute deviation of d_{xy}/#sigma_{d_{xy}} vs #phi "
2545 "sector;#varphi (sector) [degrees]; MAD(d_{xy}/#sigma_{d_{xy}})",
2551 "norm_medians_dz_phi",
2552 "Median of d_{z}/#sigma_{d_{z}} vs #phi sector;#varphi (sector) [degrees];#mu_{1/2}(d_{z}/#sigma_{d_{z}})",
2558 "Median absolute deviation of d_{z}/#sigma_{d_{z}} vs #phi "
2559 "sector;#varphi (sector) [degrees];MAD(d_{z}/#sigma_{d_{z}})",
2565 "norm_medians_dxy_eta",
2566 "Median of d_{xy}/#sigma_{d_{xy}} vs #eta sector;#eta (sector);#mu_{1/2}(d_{xy}/#sigma_{d_{z}})",
2572 "norm_MADs_dxy_eta",
2573 "Median absolute deviation of d_{xy}/#sigma_{d_{xy}} vs #eta sector;#eta (sector);MAD(d_{xy}/#sigma_{d_{z}})",
2579 "norm_medians_dz_eta",
2580 "Median of d_{z}/#sigma_{d_{z}} vs #eta sector;#eta (sector);#mu_{1/2}(d_{z}/#sigma_{d_{z}})",
2587 "Median absolute deviation of d_{z}/#sigma_{d_{z}} vs #eta sector;#eta (sector);MAD(d_{z}/#sigma_{d_{z}})",
2601 unsigned int count = 1;
2613 edm::LogInfo(
"PrimaryVertexValidation") <<
"######################################\n"
2614 <<
"# PrimaryVertexValidation::endJob()\n"
2615 <<
"# Number of analyzed events: " <<
Nevt_ <<
"\n"
2616 <<
"######################################";
2621 "means_dxy_modZ",
"#LT d_{xy} #GT vs modZ;module number (Z);#LT d_{xy} #GT [#mum]",
nModZ_, 0.,
nModZ_);
2624 "widths_dxy_modZ",
"#sigma_{d_{xy}} vs modZ;module number (Z);#sigma_{d_{xy}} [#mum]",
nModZ_, 0.,
nModZ_);
2627 "means_dz_modZ",
"#LT d_{z} #GT vs modZ;module number (Z);#LT d_{z} #GT [#mum]",
nModZ_, 0.,
nModZ_);
2630 "widths_dz_modZ",
"#sigma_{d_{z}} vs modZ;module number (Z);#sigma_{d_{z}} [#mum]",
nModZ_, 0.,
nModZ_);
2633 "#LT d_{xy} #GT vs ladder;ladder number (#phi);#LT d_{xy} #GT [#mum]",
2640 "#sigma_{d_{xy}} vs ladder;ladder number (#phi);#sigma_{d_{xy}} [#mum]",
2646 "means_dz_ladder",
"#LT d_{z} #GT vs ladder;ladder number (#phi);#LT d_{z} #GT [#mum]",
nLadders_, 0.,
nLadders_);
2650 "#sigma_{d_{z}} vs ladder;ladder number (#phi);#sigma_{d_{z}} [#mum]",
2656 "norm_means_dxy_modZ",
2657 "#LT d_{xy}/#sigma_{d_{xy}} #GT vs modZ;module number (Z);#LT d_{xy}/#sigma_{d_{xy}} #GT",
2663 "norm_widths_dxy_modZ",
2664 "width(d_{xy}/#sigma_{d_{xy}}) vs modZ;module number (Z); width(d_{xy}/#sigma_{d_{xy}})",
2671 "#LT d_{z}/#sigma_{d_{z}} #GT vs modZ;module number (Z);#LT d_{z}/#sigma_{d_{z}} #GT",
2678 "width(d_{z}/#sigma_{d_{z}}) vs pT;module number (Z);width(d_{z}/#sigma_{d_{z}})",
2684 "norm_means_dxy_ladder",
2685 "#LT d_{xy}/#sigma_{d_{xy}} #GT vs ladder;ladder number (#phi);#LT d_{xy}/#sigma_{d_{z}} #GT",
2691 "norm_widths_dxy_ladder",
2692 "width(d_{xy}/#sigma_{d_{xy}}) vs ladder;ladder number (#phi);width(d_{xy}/#sigma_{d_{z}})",
2698 "norm_means_dz_ladder",
2699 "#LT d_{z}/#sigma_{d_{z}} #GT vs ladder;ladder number (#phi);#LT d_{z}/#sigma_{d_{z}} #GT",
2705 "norm_widths_dz_ladder",
2706 "width(d_{z}/#sigma_{d_{z}}) vs ladder;ladder number (#phi);width(d_{z}/#sigma_{d_{z}})",
2714 "#LT d_{xy} #GT map;module number [z];ladder number [#varphi]",
2723 "#LT d_{z} #GT map;module number [z];ladder number [#varphi]",
2733 "#LT d_{xy}/#sigma_{d_{xy}} #GT map;module number [z];ladder number [#varphi]",
2742 "#LT d_{z}/#sigma_{d_{z}} #GT map;module number [z];ladder number [#varphi]",
2751 "#sigma_{d_{xy}} map;module number [z];ladder number [#varphi]",
2760 "#sigma_{d_{z}} map;module number [z];ladder number [#varphi]",
2770 "width(d_{xy}/#sigma_{d_{xy}}) map;module number [z];ladder number [#varphi]",
2780 "width(d_{z}/#sigma_{d_{z}}) map;module number [z];ladder number [#varphi]",
2979 bool isOn = (average_current > 2000.);
2982 return ((isOn && !is0T) || (!isOn && is0T));
3061 TH1F* residualsPlot[100],
3067 char phibincenter[129];
3069 sprintf(phibincenter,
"%.f", (phiBins[
i] + phiBins[
i + 1]) / 2.);
3071 char etabincenter[129];
3079 trendPlot->SetBinContent(
i + 1, mean_);
3080 trendPlot->SetBinError(
i + 1, meanErr_);
3086 trendPlot->SetBinContent(
i + 1, width_);
3087 trendPlot->SetBinError(
i + 1, widthErr_);
3093 trendPlot->SetBinContent(
i + 1, median_);
3094 trendPlot->SetBinError(
i + 1, medianErr_);
3100 trendPlot->SetBinContent(
i + 1, mad_);
3101 trendPlot->SetBinError(
i + 1, madErr_);
3106 <<
"fillTrendPlot() " << fitPar_ <<
" unknown estimator!" << std::endl;
3110 if (var_.find(
"eta") != std::string::npos) {
3111 trendPlot->GetXaxis()->SetBinLabel(
i + 1, etabincenter);
3112 }
else if (var_.find(
"phi") != std::string::npos) {
3113 trendPlot->GetXaxis()->SetBinLabel(
i + 1, phibincenter);
3116 <<
"fillTrendPlot() " << var_ <<
" unknown track parameter!" << std::endl;
3123 std::vector<TH1F*>&
h,
3128 for (
auto iterator =
h.begin(); iterator !=
h.end(); iterator++) {
3134 float mean_ = myFit.first.value();
3135 float meanErr_ = myFit.first.error();
3136 trendPlot->SetBinContent(
bin, mean_);
3137 trendPlot->SetBinError(
bin, meanErr_);
3141 float width_ = myFit.second.value();
3142 float widthErr_ = myFit.second.error();
3143 trendPlot->SetBinContent(
bin, width_);
3144 trendPlot->SetBinError(
bin, widthErr_);
3150 trendPlot->SetBinContent(
bin, median_);
3151 trendPlot->SetBinError(
bin, medianErr_);
3157 trendPlot->SetBinContent(
bin, mad_);
3158 trendPlot->SetBinError(
bin, madErr_);
3163 <<
"fillTrendPlotByIndex() " << fitPar_ <<
" unknown estimator!" << std::endl;
3167 char bincenter[129];
3171 trendPlot->GetXaxis()->SetBinLabel(
bin, bincenter);
3174 sprintf(bincenter,
"%.f", (phiBins[
bin - 1] + phiBins[
bin]) / 2.);
3175 trendPlot->GetXaxis()->SetBinLabel(
bin, bincenter);
3185 TH1F* residualsMapPlot[100][100],
3191 for (
int i = 0;
i < nYBins_; ++
i) {
3192 char phibincenter[129];
3194 sprintf(phibincenter,
"%.f", (phiBins[
i] + phiBins[
i + 1]) / 2.);
3196 if (nXBins_ == nYBins_) {
3197 trendMap->GetYaxis()->SetBinLabel(
i + 1, phibincenter);
3200 for (
int j = 0;
j < nXBins_; ++
j) {
3201 char etabincenter[129];
3206 if (nXBins_ == nYBins_) {
3207 trendMap->GetXaxis()->SetBinLabel(
j + 1, etabincenter);
3215 trendMap->SetBinContent(
j + 1,
i + 1, mean_);
3216 trendMap->SetBinError(
j + 1,
i + 1, meanErr_);
3222 trendMap->SetBinContent(
j + 1,
i + 1, width_);
3223 trendMap->SetBinError(
j + 1,
i + 1, widthErr_);
3229 trendMap->SetBinContent(
j + 1,
i + 1, median_);
3230 trendMap->SetBinError(
j + 1,
i + 1, medianErr_);
3236 trendMap->SetBinContent(
j + 1,
i + 1, mad_);
3237 trendMap->SetBinError(
j + 1,
i + 1, madErr_);
3241 edm::LogWarning(
"PrimaryVertexValidation:") <<
" fillMap() " << fitPar_ <<
" unknown estimator!" << std::endl;
3251 if (
a.tracksSize() !=
b.tracksSize())
3252 return a.tracksSize() >
b.tracksSize() ?
true :
false;
3254 return a.chi2() <
b.chi2() ?
true :
false;
3267 double vzErr = 0.0, vxErr = 0.0, vyErr = 0.0;
3268 vtxPoint =
vertex.position();
3273 double dxy = 0.0,
dz = 0.0, dxysigma = 0.0, dzsigma = 0.0;
3276 dxysigma =
sqrt(
track.d0Error() *
track.d0Error() + vxErr * vyErr);
3277 dzsigma =
sqrt(
track.dzError() *
track.dzError() + vzErr * vzErr);
3285 if (
track.ptError() /
track.pt() > ptErrMax_)
3295 TH1F::SetDefaultSumw2(kTRUE);
3297 std::map<std::string, TH1*>
h;
3302 h[
"pseudorapidity_" +
type] =
3303 dir.make<TH1F>((
"rapidity_" +
type).c_str(),
"track pseudorapidity; track #eta; tracks", 100, -3., 3.);
3304 h[
"z0_" +
type] =
dir.make<TH1F>((
"z0_" +
type).c_str(),
"track z_{0};track z_{0} (cm);tracks", 80, -40., 40.);
3305 h[
"phi_" +
type] =
dir.make<TH1F>((
"phi_" +
type).c_str(),
"track #phi; track #phi;tracks", 80, -
M_PI,
M_PI);
3306 h[
"eta_" +
type] =
dir.make<TH1F>((
"eta_" +
type).c_str(),
"track #eta; track #eta;tracks", 80, -4., 4.);
3307 h[
"pt_" +
type] =
dir.make<TH1F>((
"pt_" +
type).c_str(),
"track p_{T}; track p_{T} [GeV];tracks", 100, 0., 20.);
3308 h[
"p_" +
type] =
dir.make<TH1F>((
"p_" +
type).c_str(),
"track p; track p [GeV];tracks", 100, 0., 20.);
3309 h[
"found_" +
type] =
3310 dir.make<TH1F>((
"found_" +
type).c_str(),
"n. found hits;n^{found}_{hits};tracks", 30, 0., 30.);
3311 h[
"lost_" +
type] =
dir.make<TH1F>((
"lost_" +
type).c_str(),
"n. lost hits;n^{lost}_{hits};tracks", 20, 0., 20.);
3312 h[
"nchi2_" +
type] =
3313 dir.make<TH1F>((
"nchi2_" +
type).c_str(),
"normalized track #chi^{2};track #chi^{2}/ndf;tracks", 100, 0., 20.);
3314 h[
"rstart_" +
type] =
dir.make<TH1F>(
3315 (
"rstart_" +
type).c_str(),
"track start radius; track innermost radius r (cm);tracks", 100, 0., 20.);
3316 h[
"expectedInner_" +
type] =
dir.make<TH1F>(
3317 (
"expectedInner_" +
type).c_str(),
"n. expected inner hits;n^{expected}_{inner};tracks", 10, 0., 10.);
3318 h[
"expectedOuter_" +
type] =
dir.make<TH1F>(
3319 (
"expectedOuter_" +
type).c_str(),
"n. expected outer hits;n^{expected}_{outer};tracks ", 10, 0., 10.);
3320 h[
"logtresxy_" +
type] =
3321 dir.make<TH1F>((
"logtresxy_" +
type).c_str(),
3322 "log10(track r-#phi resolution/#mum);log10(track r-#phi resolution/#mum);tracks",
3326 h[
"logtresz_" +
type] =
dir.make<TH1F>((
"logtresz_" +
type).c_str(),
3327 "log10(track z resolution/#mum);log10(track z resolution/#mum);tracks",
3331 h[
"tpullxy_" +
type] =
3332 dir.make<TH1F>((
"tpullxy_" +
type).c_str(),
"track r-#phi pull;pull_{r-#phi};tracks", 100, -10., 10.);
3333 h[
"tpullz_" +
type] =
3334 dir.make<TH1F>((
"tpullz_" +
type).c_str(),
"track r-z pull;pull_{r-z};tracks", 100, -50., 50.);
3335 h[
"tlogDCAxy_" +
type] =
dir.make<TH1F>(
3336 (
"tlogDCAxy_" +
type).c_str(),
"track log_{10}(DCA_{r-#phi});track log_{10}(DCA_{r-#phi});tracks", 200, -5., 3.);
3337 h[
"tlogDCAz_" +
type] =
dir.make<TH1F>(
3338 (
"tlogDCAz_" +
type).c_str(),
"track log_{10}(DCA_{r-z});track log_{10}(DCA_{r-z});tracks", 200, -5., 5.);
3339 h[
"lvseta_" +
type] =
dir.make<TH2F>(
3340 (
"lvseta_" +
type).c_str(),
"cluster length vs #eta;track #eta;cluster length", 60, -3., 3., 20, 0., 20);
3341 h[
"lvstanlambda_" +
type] =
dir.make<TH2F>((
"lvstanlambda_" +
type).c_str(),
3342 "cluster length vs tan #lambda; tan#lambda;cluster length",
3349 h[
"restrkz_" +
type] =
3350 dir.make<TH1F>((
"restrkz_" +
type).c_str(),
"z-residuals (track vs vertex);res_{z} (cm);tracks", 200, -5., 5.);
3351 h[
"restrkzvsphi_" +
type] =
dir.make<TH2F>((
"restrkzvsphi_" +
type).c_str(),
3352 "z-residuals (track - vertex) vs track #phi;track #phi;res_{z} (cm)",
3359 h[
"restrkzvseta_" +
type] =
dir.make<TH2F>((
"restrkzvseta_" +
type).c_str(),
3360 "z-residuals (track - vertex) vs track #eta;track #eta;res_{z} (cm)",
3367 h[
"pulltrkzvsphi_" +
type] =
3368 dir.make<TH2F>((
"pulltrkzvsphi_" +
type).c_str(),
3369 "normalized z-residuals (track - vertex) vs track #phi;track #phi;res_{z}/#sigma_{res_{z}}",
3376 h[
"pulltrkzvseta_" +
type] =
3377 dir.make<TH2F>((
"pulltrkzvseta_" +
type).c_str(),
3378 "normalized z-residuals (track - vertex) vs track #eta;track #eta;res_{z}/#sigma_{res_{z}}",
3385 h[
"pulltrkz_" +
type] =
dir.make<TH1F>((
"pulltrkz_" +
type).c_str(),
3386 "normalized z-residuals (track vs vertex);res_{z}/#sigma_{res_{z}};tracks",
3390 h[
"sigmatrkz0_" +
type] =
dir.make<TH1F>(
3391 (
"sigmatrkz0_" +
type).c_str(),
"z-resolution (excluding beam);#sigma^{trk}_{z_{0}} (cm);tracks", 100, 0., 5.);
3392 h[
"sigmatrkz_" +
type] =
dir.make<TH1F>(
3393 (
"sigmatrkz_" +
type).c_str(),
"z-resolution (including beam);#sigma^{trk}_{z} (cm);tracks", 100, 0., 5.);
3394 h[
"nbarrelhits_" +
type] =
dir.make<TH1F>(
3395 (
"nbarrelhits_" +
type).c_str(),
"number of pixel barrel hits;n. hits Barrel Pixel;tracks", 10, 0., 10.);
3396 h[
"nbarrelLayers_" +
type] =
dir.make<TH1F>(
3397 (
"nbarrelLayers_" +
type).c_str(),
"number of pixel barrel layers;n. layers Barrel Pixel;tracks", 10, 0., 10.);
3398 h[
"nPxLayers_" +
type] =
dir.make<TH1F>(
3399 (
"nPxLayers_" +
type).c_str(),
"number of pixel layers (barrel+endcap);n. Pixel layers;tracks", 10, 0., 10.);
3400 h[
"nSiLayers_" +
type] =
3401 dir.make<TH1F>((
"nSiLayers_" +
type).c_str(),
"number of Tracker layers;n. Tracker layers;tracks", 20, 0., 20.);
3402 h[
"trackAlgo_" +
type] =
3403 dir.make<TH1F>((
"trackAlgo_" +
type).c_str(),
"track algorithm;track algo;tracks", 30, 0., 30.);
3404 h[
"trackQuality_" +
type] =
3405 dir.make<TH1F>((
"trackQuality_" +
type).c_str(),
"track quality;track quality;tracks", 7, -1., 6.);
3415 unsigned int theNOfBins,
3418 bool isNormalized) {
3419 TH1F::SetDefaultSumw2(kTRUE);
3431 std::vector<TH1F*>
h;
3432 h.reserve(theNOfBins);
3434 if (theNOfBins == 0) {
3436 <<
"bookResidualsHistogram() The number of bins cannot be identically 0" << std::endl;
3447 for (
unsigned int i = 0;
i < theNOfBins;
i++) {
3449 ? Form(
"%s vs %s - bin %i (%f < %s < %f);%s %s;tracks",
3458 : Form(
"%s vs %s - bin %i;%s %s;tracks",
3465 TH1F* htemp =
dir.make<TH1F>(
3466 Form(
"histo_%s_%s_plot%i", s_resType.c_str(), s_varType.c_str(),
i),
3487 using namespace reco;
3500 double d0Error =
tt->track().d0Error();
3509 double dzError =
tt->track().dzError();
3529 double z = (
tt->stateAtBeamLine().trackStateAtPCA()).
position().z();
3530 double tantheta =
tan((
tt->stateAtBeamLine().trackStateAtPCA()).momentum().theta());
3531 double dz2 =
pow(
tt->track().dzError(), 2) +
wxy2_ /
pow(tantheta, 2);
3544 double kappa = -0.002998 * fBfield_ *
tt->track().qoverp() /
cos(
tt->track().theta());
3547 double s0 = (
x1 *
cos(
tt->track().phi()) +
y1 *
sin(
tt->track().phi())) /
q;
3561 PVValHelper::fill(
h,
"nbarrelLayers_" + ttype,
tt->track().hitPattern().pixelBarrelLayersWithMeasurement());
3562 PVValHelper::fill(
h,
"nPxLayers_" + ttype,
tt->track().hitPattern().pixelLayersWithMeasurement());
3563 PVValHelper::fill(
h,
"nSiLayers_" + ttype,
tt->track().hitPattern().trackerLayersWithMeasurement());
3565 h,
"expectedInner_" + ttype,
tt->track().hitPattern().numberOfLostHits(HitPattern::MISSING_INNER_HITS));
3567 h,
"expectedOuter_" + ttype,
tt->track().hitPattern().numberOfLostHits(HitPattern::MISSING_OUTER_HITS));
3572 int longesthit = 0, nbarrel = 0;
3573 for (
auto const&
hit :
tt->track().recHits()) {
3582 if (clust->sizeY() - longesthit > 0)
3583 longesthit = clust->sizeY();
3584 if (clust->sizeY() > 20.) {