CMS 3D CMS Logo

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

#include <Phase2TrackerValidateDigi.h>

Inheritance diagram for Phase2TrackerValidateDigi:
DQMEDAnalyzer edm::stream::EDProducer< edm::GlobalCache< DQMEDAnalyzerGlobalCache >, edm::EndRunProducer, edm::EndLuminosityBlockProducer, edm::Accumulator >

Classes

struct  DigiMEs
 

Public Member Functions

void analyze (const edm::Event &iEvent, const edm::EventSetup &iSetup) override
 
void bookHistograms (DQMStore::IBooker &ibooker, edm::Run const &iRun, edm::EventSetup const &iSetup) override
 
void dqmBeginRun (const edm::Run &iRun, const edm::EventSetup &iSetup) override
 
std::string getHistoId (uint32_t det_id, bool flag)
 
 Phase2TrackerValidateDigi (const edm::ParameterSet &)
 
 ~Phase2TrackerValidateDigi () override
 
- Public Member Functions inherited from DQMEDAnalyzer
void accumulate (edm::Event const &event, edm::EventSetup const &setup) final
 
void beginLuminosityBlock (edm::LuminosityBlock const &lumi, edm::EventSetup const &setup) final
 
void beginRun (edm::Run const &run, edm::EventSetup const &setup) final
 
void beginStream (edm::StreamID id) final
 
 DQMEDAnalyzer ()
 
void endLuminosityBlock (edm::LuminosityBlock const &lumi, edm::EventSetup const &setup) final
 
void endRun (edm::Run const &run, edm::EventSetup const &setup) final
 
virtual bool getCanSaveByLumi ()
 
- Public Member Functions inherited from edm::stream::EDProducer< edm::GlobalCache< DQMEDAnalyzerGlobalCache >, edm::EndRunProducer, edm::EndLuminosityBlockProducer, edm::Accumulator >
 EDProducer ()=default
 
bool hasAbilityToProduceInBeginLumis () const final
 
bool hasAbilityToProduceInBeginProcessBlocks () const final
 
bool hasAbilityToProduceInBeginRuns () const final
 
bool hasAbilityToProduceInEndLumis () const final
 
bool hasAbilityToProduceInEndProcessBlocks () const final
 
bool hasAbilityToProduceInEndRuns () const final
 

Private Member Functions

void bookLayerHistos (DQMStore::IBooker &ibooker, unsigned int det_id, bool flag)
 
void fillHistogram (MonitorElement *th1, MonitorElement *th2, MonitorElement *th3, float val, int primary)
 
void fillHitsPerTrack ()
 
void fillITPixelBXInfo ()
 
void fillOTBXInfo ()
 
int fillSimHitInfo (const edm::Event &iEvent, const SimTrack simTrk)
 
bool findITPixelDigi (unsigned int detid, unsigned int id)
 
bool findOTDigi (unsigned int detid, unsigned int id)
 
unsigned int getSimTrackId (const edm::DetSetVector< PixelDigiSimLink > *simLinks, const DetId &detId, unsigned int &channel)
 
bool isPrimary (const SimTrack &simTrk, const PSimHit &simHit)
 
int matchedSimTrack (edm::Handle< edm::SimTrackContainer > &SimTk, unsigned int simTrkId)
 

Private Attributes

edm::ParameterSet config_
 
const float cval
 
float etaCut_
 
const edm::ESGetToken< TrackerGeometry, TrackerDigiGeometryRecordgeomToken_
 
std::string geomType_
 
const float GeVperElectron
 
edm::Handle< edm::DetSetVector< PixelDigi > > itPixelDigiHandle_
 
edm::InputTag itPixelDigiSimLinkSrc_
 
const edm::EDGetTokenT< edm::DetSetVector< PixelDigiSimLink > > itPixelDigiSimLinkToken_
 
edm::InputTag itPixelDigiSrc_
 
const edm::EDGetTokenT< edm::DetSetVector< PixelDigi > > itPixelDigiToken_
 
edm::Handle< edm::DetSetVector< PixelDigiSimLink > > itPixelSimLinkHandle_
 
std::map< std::string, DigiMEslayerMEs
 
MonitorElementMatchedRZPositionMap
 
MonitorElementMatchedXYPositionMap
 
MonitorElementnSimHitsPerTrack
 
MonitorElementnSimulatedTracks
 
MonitorElementnSimulatedTracksP
 
MonitorElementnSimulatedTracksS
 
MonitorElementnSimVertices
 
edm::Handle< edm::DetSetVector< Phase2TrackerDigi > > otDigiHandle_
 
edm::InputTag otDigiSimLinkSrc_
 
const edm::EDGetTokenT< edm::DetSetVector< PixelDigiSimLink > > otDigiSimLinkToken_
 
edm::InputTag otDigiSrc_
 
const edm::EDGetTokenT< edm::DetSetVector< Phase2TrackerDigi > > otDigiToken_
 
edm::Handle< edm::DetSetVector< PixelDigiSimLink > > otSimLinkHandle_
 
bool pixelFlag_
 
std::vector< edm::InputTagpSimHitSrc_
 
float ptCut_
 
edm::Handle< edm::PSimHitContainersimHits
 
std::vector< edm::EDGetTokenT< edm::PSimHitContainer > > simHitTokens_
 
edm::Handle< edm::SimTrackContainersimTracks
 
edm::InputTag simTrackSrc_
 
const edm::EDGetTokenT< edm::SimTrackContainersimTrackToken_
 
MonitorElementSimulatedRZPositionMap
 
MonitorElementSimulatedTOFEtaMap
 
MonitorElementSimulatedTOFPhiMap
 
MonitorElementSimulatedTOFRMap
 
MonitorElementSimulatedTOFZMap
 
MonitorElementSimulatedTrackEta
 
MonitorElementSimulatedTrackEtaP
 
MonitorElementSimulatedTrackEtaS
 
MonitorElementSimulatedTrackPhi
 
MonitorElementSimulatedTrackPhiP
 
MonitorElementSimulatedTrackPhiS
 
MonitorElementSimulatedTrackPt
 
MonitorElementSimulatedTrackPtP
 
MonitorElementSimulatedTrackPtS
 
MonitorElementSimulatedXYPositionMap
 
edm::InputTag simVertexSrc_
 
const edm::EDGetTokenT< edm::SimVertexContainersimVertexToken_
 
edm::Handle< edm::SimVertexContainersimVertices
 
const TrackerGeometrytkGeom_ = nullptr
 
float tofLowerCut_
 
float tofUpperCut_
 
const edm::ESGetToken< TrackerTopology, TrackerTopologyRcdtopoToken_
 
const TrackerTopologytTopo_ = nullptr
 

Additional Inherited Members

- Public Types inherited from DQMEDAnalyzer
typedef dqm::reco::DQMStore DQMStore
 
typedef dqm::reco::MonitorElement MonitorElement
 
- Public Types inherited from edm::stream::EDProducer< edm::GlobalCache< DQMEDAnalyzerGlobalCache >, edm::EndRunProducer, edm::EndLuminosityBlockProducer, edm::Accumulator >
typedef CacheContexts< T... > CacheTypes
 
typedef CacheTypes::GlobalCache GlobalCache
 
typedef AbilityChecker< T... > HasAbility
 
typedef CacheTypes::LuminosityBlockCache LuminosityBlockCache
 
typedef LuminosityBlockContextT< LuminosityBlockCache, RunCache, GlobalCacheLuminosityBlockContext
 
typedef CacheTypes::LuminosityBlockSummaryCache LuminosityBlockSummaryCache
 
typedef CacheTypes::RunCache RunCache
 
typedef RunContextT< RunCache, GlobalCacheRunContext
 
typedef CacheTypes::RunSummaryCache RunSummaryCache
 
- Static Public Member Functions inherited from DQMEDAnalyzer
static void globalEndJob (DQMEDAnalyzerGlobalCache const *)
 
static void globalEndLuminosityBlockProduce (edm::LuminosityBlock &lumi, edm::EventSetup const &setup, LuminosityBlockContext const *context)
 
static void globalEndRunProduce (edm::Run &run, edm::EventSetup const &setup, RunContext const *context)
 
static std::unique_ptr< DQMEDAnalyzerGlobalCacheinitializeGlobalCache (edm::ParameterSet const &)
 
- Protected Member Functions inherited from DQMEDAnalyzer
uint64_t meId () const
 
- Protected Attributes inherited from DQMEDAnalyzer
edm::EDPutTokenT< DQMTokenlumiToken_
 
edm::EDPutTokenT< DQMTokenrunToken_
 
unsigned int streamId_
 

Detailed Description

Description: Test pixel digis.

Definition at line 29 of file Phase2TrackerValidateDigi.h.

Constructor & Destructor Documentation

◆ Phase2TrackerValidateDigi()

Phase2TrackerValidateDigi::Phase2TrackerValidateDigi ( const edm::ParameterSet iConfig)
explicit

Definition at line 50 of file Phase2TrackerValidateDigi.cc.

51  : config_(iConfig),
52  pixelFlag_(config_.getParameter<bool>("PixelPlotFillingFlag")),
53  geomType_(config_.getParameter<std::string>("GeometryType")),
54  otDigiSrc_(config_.getParameter<edm::InputTag>("OuterTrackerDigiSource")),
55  otDigiSimLinkSrc_(config_.getParameter<edm::InputTag>("OuterTrackerDigiSimLinkSource")),
56  itPixelDigiSrc_(config_.getParameter<edm::InputTag>("InnerPixelDigiSource")),
57  itPixelDigiSimLinkSrc_(config_.getParameter<edm::InputTag>("InnerPixelDigiSimLinkSource")),
58  pSimHitSrc_(config_.getParameter<std::vector<edm::InputTag> >("PSimHitSource")),
59  simTrackSrc_(config_.getParameter<edm::InputTag>("SimTrackSource")),
60  simVertexSrc_(config_.getParameter<edm::InputTag>("SimVertexSource")),
65  simTrackToken_(consumes<edm::SimTrackContainer>(simTrackSrc_)),
66  simVertexToken_(consumes<edm::SimVertexContainer>(simVertexSrc_)),
67  geomToken_(esConsumes<TrackerGeometry, TrackerDigiGeometryRecord, edm::Transition::BeginRun>()),
68  topoToken_(esConsumes<TrackerTopology, TrackerTopologyRcd, edm::Transition::BeginRun>()),
69  GeVperElectron(3.61E-09), // 1 electron(3.61eV, 1keV(277e, mod 9/06 d.k.
70  cval(30.) {
71  for (const auto& itag : pSimHitSrc_)
72  simHitTokens_.push_back(consumes<edm::PSimHitContainer>(itag));
73 
74  etaCut_ = config_.getParameter<double>("EtaCutOff");
75  ptCut_ = config_.getParameter<double>("PtCutOff");
76  tofUpperCut_ = config_.getParameter<double>("TOFUpperCutOff");
77  tofLowerCut_ = config_.getParameter<double>("TOFLowerCutOff");
78 
79  edm::LogInfo("Phase2TrackerValidateDigi") << ">>> Construct Phase2TrackerValidateDigi ";
80 }

References config_, etaCut_, edm::ParameterSet::getParameter(), pSimHitSrc_, ptCut_, simHitTokens_, tofLowerCut_, and tofUpperCut_.

◆ ~Phase2TrackerValidateDigi()

Phase2TrackerValidateDigi::~Phase2TrackerValidateDigi ( )
override

Definition at line 85 of file Phase2TrackerValidateDigi.cc.

85  {
86  // do anything here that needs to be done at desctruction time
87  // (e.g. close files, deallocate resources etc.)
88  edm::LogInfo("Phase2TrackerValidateDigi") << ">>> Destroy Phase2TrackerValidateDigi ";
89 }

Member Function Documentation

◆ analyze()

void Phase2TrackerValidateDigi::analyze ( const edm::Event iEvent,
const edm::EventSetup iSetup 
)
overridevirtual

Reimplemented from DQMEDAnalyzer.

Definition at line 108 of file Phase2TrackerValidateDigi.cc.

108  {
109  // Get digis
111  iEvent.getByToken(otDigiToken_, otDigiHandle_);
112 
113  // DigiSimLink
116 
117  // SimTrack
118  iEvent.getByToken(simTrackToken_, simTracks);
119 
120  // SimVertex
121  iEvent.getByToken(simVertexToken_, simVertices);
122 
123  // Fil # of SIM Vertices@
124  nSimVertices->Fill((*simVertices).size());
125  // Loop over Sim Tracks and Fill relevant histograms
126  int nTracks = 0;
127  int nTracksP = 0;
128  int nTracksS = 0;
129  for (edm::SimTrackContainer::const_iterator simTrkItr = simTracks->begin(); simTrkItr != simTracks->end();
130  ++simTrkItr) {
131  if (simTrkItr->charge() == 0)
132  continue;
133  int vtxIndex = simTrkItr->vertIndex();
134  int vtxParent = -1;
135  if (vtxIndex > 0) {
136  SimVertex vtx = (*simVertices)[vtxIndex];
137  if (!vtx.noParent()) {
138  int trkId = vtx.parentIndex();
139  vtxParent = (*simTracks)[matchedSimTrack(simTracks, trkId)].vertIndex();
140  }
141  }
142  int simTk_type = -1;
143  if (vtxIndex == 0 || vtxParent == 0)
144  simTk_type = 1;
145  else
146  simTk_type = 0;
147  nTracks++;
148  if (simTk_type == 1)
149  nTracksP++;
150  else
151  nTracksS++;
152 
153  float simTk_pt = simTrkItr->momentum().pt();
154  float simTk_eta = simTrkItr->momentum().eta();
155  float simTk_phi = simTrkItr->momentum().phi();
156 
157  if (fabs(simTk_eta) < etaCut_)
159  if (simTk_pt > ptCut_)
161  if (fabs(simTk_eta) < etaCut_ && simTk_pt > ptCut_)
163 
164  // initialize
165  for (auto& it : layerMEs) {
166  it.second.nDigis = 0;
167  it.second.nHits = 0;
168  }
169  fillSimHitInfo(iEvent, (*simTrkItr));
170 
171  int nHitCutoff = 2;
172  if (pixelFlag_)
173  nHitCutoff = 1;
174  for (auto& it : layerMEs) {
175  DigiMEs& local_mes = it.second;
176  if (it.second.nHits < nHitCutoff) {
177  if (std::fabs(simTk_eta) < 1.0)
178  local_mes.MissedHitTrackPt->Fill(simTk_pt);
179  if (simTk_pt > ptCut_ && std::fabs(simTk_eta) < 1.0)
180  local_mes.MissedHitTrackEta->Fill(simTk_eta);
181  if (std::fabs(simTk_eta) < 1.0 && simTk_pt > ptCut_)
182  local_mes.MissedHitTrackPhi->Fill(simTk_phi);
183  }
184  }
185  }
187  nSimulatedTracksP->Fill(nTracksP);
188  nSimulatedTracksS->Fill(nTracksS);
189  if (pixelFlag_)
191  else
192  fillOTBXInfo();
193 }

References etaCut_, dqm::impl::MonitorElement::Fill(), fillHistogram(), fillITPixelBXInfo(), fillOTBXInfo(), fillSimHitInfo(), iEvent, itPixelDigiHandle_, itPixelDigiSimLinkToken_, itPixelDigiToken_, itPixelSimLinkHandle_, layerMEs, matchedSimTrack(), Phase2TrackerValidateDigi::DigiMEs::MissedHitTrackEta, Phase2TrackerValidateDigi::DigiMEs::MissedHitTrackPhi, Phase2TrackerValidateDigi::DigiMEs::MissedHitTrackPt, nSimulatedTracks, nSimulatedTracksP, nSimulatedTracksS, nSimVertices, BeamSpotPI::nTracks, otDigiHandle_, otDigiSimLinkToken_, otDigiToken_, otSimLinkHandle_, pixelFlag_, ptCut_, simTracks, simTrackToken_, SimulatedTrackEta, SimulatedTrackEtaP, SimulatedTrackEtaS, SimulatedTrackPhi, SimulatedTrackPhiP, SimulatedTrackPhiS, SimulatedTrackPt, SimulatedTrackPtP, SimulatedTrackPtS, simVertexToken_, simVertices, and extraflags_cff::vtx.

◆ bookHistograms()

void Phase2TrackerValidateDigi::bookHistograms ( DQMStore::IBooker ibooker,
edm::Run const &  iRun,
edm::EventSetup const &  iSetup 
)
overridevirtual

Implements DQMEDAnalyzer.

Definition at line 371 of file Phase2TrackerValidateDigi.cc.

373  {
374  std::string top_folder = config_.getParameter<std::string>("TopFolderName");
375  std::stringstream folder_name;
376 
377  ibooker.cd();
378  folder_name << top_folder << "/"
379  << "SimTrackInfo";
380  ibooker.setCurrentFolder(folder_name.str());
381 
382  edm::LogInfo("Phase2TrackerValidateDigi") << " Booking Histograms in : " << folder_name.str();
383  std::stringstream HistoName;
384 
385  HistoName.str("");
386  HistoName << "NumberOfSimulatedTracks";
387  nSimulatedTracks = ibooker.book1D(HistoName.str(), HistoName.str(), 501, -0.5, 500.5);
388 
389  HistoName.str("");
390  HistoName << "NumberOfSimulatedTracksP";
391  nSimulatedTracksP = ibooker.book1D(HistoName.str(), HistoName.str(), 501, -0.5, 500.5);
392 
393  HistoName.str("");
394  HistoName << "NumberOfSimulatedTracksS";
395  nSimulatedTracksS = ibooker.book1D(HistoName.str(), HistoName.str(), 501, -0.5, 500.5);
396 
397  HistoName.str("");
398  HistoName << "NumberOfSimulatedVertices";
399  nSimVertices = ibooker.book1D(HistoName.str(), HistoName.str(), 101, -0.5, 100.5);
400 
402  HistoName.str("");
403  HistoName << "SimulatedTrackPt";
404  if (Parameters.getParameter<bool>("switch"))
405  SimulatedTrackPt = ibooker.book1D(HistoName.str(),
406  HistoName.str(),
407  Parameters.getParameter<int32_t>("Nbins"),
408  Parameters.getParameter<double>("xmin"),
409  Parameters.getParameter<double>("xmax"));
410  else
411  SimulatedTrackPt = nullptr;
412  /*
413  HistoName.str("");
414  HistoName << "SimulatedTrackPt";
415  SimulatedTrackPt = ibooker.book1D(HistoName.str(),HistoName.str(),
416  Parameters.getParameter<int32_t>("Nbins"),
417  Parameters.getParameter<double>("xmin"),
418  Parameters.getParameter<double>("xmax");*/
419  HistoName.str("");
420  HistoName << "SimulatedTrackPtP";
421  if (Parameters.getParameter<bool>("switch"))
422  SimulatedTrackPtP = ibooker.book1D(HistoName.str(),
423  HistoName.str(),
424  Parameters.getParameter<int32_t>("Nbins"),
425  Parameters.getParameter<double>("xmin"),
426  Parameters.getParameter<double>("xmax"));
427  else
428  SimulatedTrackPtP = nullptr;
429  HistoName.str("");
430  HistoName << "SimulatedTrackPtS";
431  if (Parameters.getParameter<bool>("switch"))
432  SimulatedTrackPtS = ibooker.book1D(HistoName.str(),
433  HistoName.str(),
434  Parameters.getParameter<int32_t>("Nbins"),
435  Parameters.getParameter<double>("xmin"),
436  Parameters.getParameter<double>("xmax"));
437  else
438  SimulatedTrackPtS = nullptr;
439 
441  HistoName.str("");
442  HistoName << "SimulatedTrackEta";
443  if (Parameters.getParameter<bool>("switch"))
444  SimulatedTrackEta = ibooker.book1D(HistoName.str(),
445  HistoName.str(),
446  Parameters.getParameter<int32_t>("Nbins"),
447  Parameters.getParameter<double>("xmin"),
448  Parameters.getParameter<double>("xmax"));
449  else
450  SimulatedTrackEta = nullptr;
451  HistoName.str("");
452  HistoName << "SimulatedTrackEtaP";
453  if (Parameters.getParameter<bool>("switch"))
454  SimulatedTrackEtaP = ibooker.book1D(HistoName.str(),
455  HistoName.str(),
456  Parameters.getParameter<int32_t>("Nbins"),
457  Parameters.getParameter<double>("xmin"),
458  Parameters.getParameter<double>("xmax"));
459  else
460  SimulatedTrackEtaP = nullptr;
461  HistoName.str("");
462  HistoName << "SimulatedTrackEtaS";
463  if (Parameters.getParameter<bool>("switch"))
464  SimulatedTrackEtaS = ibooker.book1D(HistoName.str(),
465  HistoName.str(),
466  Parameters.getParameter<int32_t>("Nbins"),
467  Parameters.getParameter<double>("xmin"),
468  Parameters.getParameter<double>("xmax"));
469  else
470  SimulatedTrackEtaS = nullptr;
471 
473  HistoName.str("");
474  HistoName << "SimulatedTrackPhi";
475  if (Parameters.getParameter<bool>("switch"))
476  SimulatedTrackPhi = ibooker.book1D(HistoName.str(),
477  HistoName.str(),
478  Parameters.getParameter<int32_t>("Nbins"),
479  Parameters.getParameter<double>("xmin"),
480  Parameters.getParameter<double>("xmax"));
481  else
482  SimulatedTrackPhi = nullptr;
483 
484  HistoName.str("");
485  HistoName << "SimulatedTrackPhiP";
486  if (Parameters.getParameter<bool>("switch"))
487  SimulatedTrackPhiP = ibooker.book1D(HistoName.str(),
488  HistoName.str(),
489  Parameters.getParameter<int32_t>("Nbins"),
490  Parameters.getParameter<double>("xmin"),
491  Parameters.getParameter<double>("xmax"));
492  else
493  SimulatedTrackPhiP = nullptr;
494 
495  HistoName.str("");
496  HistoName << "SimulatedTrackPhiS";
497  if (Parameters.getParameter<bool>("switch"))
498  SimulatedTrackPhiS = ibooker.book1D(HistoName.str(),
499  HistoName.str(),
500  Parameters.getParameter<int32_t>("Nbins"),
501  Parameters.getParameter<double>("xmin"),
502  Parameters.getParameter<double>("xmax"));
503  else
504  SimulatedTrackPhiS = nullptr;
505 
506  Parameters = config_.getParameter<edm::ParameterSet>("XYPositionMapH");
507  HistoName.str("");
508  HistoName << "SimulatedXPosVsYPos";
509  if (Parameters.getParameter<bool>("switch"))
510  SimulatedXYPositionMap = ibooker.book2D(HistoName.str(),
511  HistoName.str(),
512  Parameters.getParameter<int32_t>("Nxbins"),
513  Parameters.getParameter<double>("xmin"),
514  Parameters.getParameter<double>("xmax"),
515  Parameters.getParameter<int32_t>("Nybins"),
516  Parameters.getParameter<double>("ymin"),
517  Parameters.getParameter<double>("ymax"));
518  else
519  SimulatedXYPositionMap = nullptr;
520 
521  Parameters = config_.getParameter<edm::ParameterSet>("RZPositionMapH");
522  HistoName.str("");
523  HistoName << "SimulatedRPosVsZPos";
524  if (Parameters.getParameter<bool>("switch"))
525  SimulatedRZPositionMap = ibooker.book2D(HistoName.str(),
526  HistoName.str(),
527  Parameters.getParameter<int32_t>("Nxbins"),
528  Parameters.getParameter<double>("xmin"),
529  Parameters.getParameter<double>("xmax"),
530  Parameters.getParameter<int32_t>("Nybins"),
531  Parameters.getParameter<double>("ymin"),
532  Parameters.getParameter<double>("ymax"));
533  else
534  SimulatedRZPositionMap = nullptr;
535 
536  //add TOF maps
538  HistoName.str("");
539  HistoName << "SimulatedTOFVsEta";
540  if (Parameters.getParameter<bool>("switch"))
541  SimulatedTOFEtaMap = ibooker.book2D(HistoName.str(),
542  HistoName.str(),
543  Parameters.getParameter<int32_t>("Nxbins"),
544  Parameters.getParameter<double>("xmin"),
545  Parameters.getParameter<double>("xmax"),
546  Parameters.getParameter<int32_t>("Nybins"),
547  Parameters.getParameter<double>("ymin"),
548  Parameters.getParameter<double>("ymax"));
549  else
550  SimulatedTOFEtaMap = nullptr;
552  HistoName.str("");
553  HistoName << "SimulatedTOFVsPhi";
554  if (Parameters.getParameter<bool>("switch"))
555  SimulatedTOFPhiMap = ibooker.book2D(HistoName.str(),
556  HistoName.str(),
557  Parameters.getParameter<int32_t>("Nxbins"),
558  Parameters.getParameter<double>("xmin"),
559  Parameters.getParameter<double>("xmax"),
560  Parameters.getParameter<int32_t>("Nybins"),
561  Parameters.getParameter<double>("ymin"),
562  Parameters.getParameter<double>("ymax"));
563  else
564  SimulatedTOFPhiMap = nullptr;
566  HistoName.str("");
567  HistoName << "SimulatedTOFVsR";
568  if (Parameters.getParameter<bool>("switch"))
569  SimulatedTOFRMap = ibooker.book2D(HistoName.str(),
570  HistoName.str(),
571  Parameters.getParameter<int32_t>("Nxbins"),
572  Parameters.getParameter<double>("xmin"),
573  Parameters.getParameter<double>("xmax"),
574  Parameters.getParameter<int32_t>("Nybins"),
575  Parameters.getParameter<double>("ymin"),
576  Parameters.getParameter<double>("ymax"));
577  else
578  SimulatedTOFRMap = nullptr;
580  HistoName.str("");
581  HistoName << "SimulatedTOFVsZ";
582  if (Parameters.getParameter<bool>("switch"))
583  SimulatedTOFZMap = ibooker.book2D(HistoName.str(),
584  HistoName.str(),
585  Parameters.getParameter<int32_t>("Nxbins"),
586  Parameters.getParameter<double>("xmin"),
587  Parameters.getParameter<double>("xmax"),
588  Parameters.getParameter<int32_t>("Nybins"),
589  Parameters.getParameter<double>("ymin"),
590  Parameters.getParameter<double>("ymax"));
591  else
592  SimulatedTOFZMap = nullptr;
593 
594  edm::ESWatcher<TrackerDigiGeometryRecord> theTkDigiGeomWatcher;
595  if (theTkDigiGeomWatcher.check(iSetup)) {
596  for (auto const& det_u : tkGeom_->detUnits()) {
597  unsigned int detId_raw = det_u->geographicalId().rawId();
598  bookLayerHistos(ibooker, detId_raw, pixelFlag_);
599  }
600  }
601  ibooker.cd();
602  folder_name.str("");
603  folder_name << top_folder << "/"
604  << "DigiMonitor";
605  ibooker.setCurrentFolder(folder_name.str());
606 
607  Parameters = config_.getParameter<edm::ParameterSet>("XYPositionMapH");
608  HistoName.str("");
609  HistoName << "MatchedSimXPosVsYPos";
610  if (Parameters.getParameter<bool>("switch"))
611  MatchedXYPositionMap = ibooker.book2D(HistoName.str(),
612  HistoName.str(),
613  Parameters.getParameter<int32_t>("Nxbins"),
614  Parameters.getParameter<double>("xmin"),
615  Parameters.getParameter<double>("xmax"),
616  Parameters.getParameter<int32_t>("Nybins"),
617  Parameters.getParameter<double>("ymin"),
618  Parameters.getParameter<double>("ymax"));
619  else
620  MatchedXYPositionMap = nullptr;
621 
622  Parameters = config_.getParameter<edm::ParameterSet>("RZPositionMapH");
623  HistoName.str("");
624  HistoName << "MatchedSimRPosVsZPos";
625  if (Parameters.getParameter<bool>("switch"))
626  MatchedRZPositionMap = ibooker.book2D(HistoName.str(),
627  HistoName.str(),
628  Parameters.getParameter<int32_t>("Nxbins"),
629  Parameters.getParameter<double>("xmin"),
630  Parameters.getParameter<double>("xmax"),
631  Parameters.getParameter<int32_t>("Nybins"),
632  Parameters.getParameter<double>("ymin"),
633  Parameters.getParameter<double>("ymax"));
634  else
635  MatchedRZPositionMap = nullptr;
636 }

References dqm::implementation::IBooker::book1D(), dqm::implementation::IBooker::book2D(), bookLayerHistos(), dqm::implementation::NavigatorBase::cd(), edm::ESWatcher< T >::check(), config_, TrackerGeometry::detUnits(), fed_dqm_sourceclient-live_cfg::folder_name, edm::ParameterSet::getParameter(), MatchedRZPositionMap, MatchedXYPositionMap, nSimulatedTracks, nSimulatedTracksP, nSimulatedTracksS, nSimVertices, pixelFlag_, dqm::implementation::NavigatorBase::setCurrentFolder(), SimulatedRZPositionMap, SimulatedTOFEtaMap, SimulatedTOFPhiMap, SimulatedTOFRMap, SimulatedTOFZMap, SimulatedTrackEta, SimulatedTrackEtaP, SimulatedTrackEtaS, SimulatedTrackPhi, SimulatedTrackPhiP, SimulatedTrackPhiS, SimulatedTrackPt, SimulatedTrackPtP, SimulatedTrackPtS, SimulatedXYPositionMap, AlCaHLTBitMon_QueryRunRegistry::string, and tkGeom_.

◆ bookLayerHistos()

void Phase2TrackerValidateDigi::bookLayerHistos ( DQMStore::IBooker ibooker,
unsigned int  det_id,
bool  flag 
)
private

Definition at line 640 of file Phase2TrackerValidateDigi.cc.

640  {
641  int layer;
642  if (flag)
644  else
645  layer = tTopo_->getOTLayerNumber(det_id);
646 
647  if (layer < 0)
648  return;
649 
650  std::string key = getHistoId(det_id, flag);
651  std::map<std::string, DigiMEs>::iterator pos = layerMEs.find(key);
652  if (pos == layerMEs.end()) {
653  std::string top_folder = config_.getParameter<std::string>("TopFolderName");
654  std::stringstream folder_name;
655 
656  //For endCap: P-type sensors are present only upto ring 10 for discs 1&2 (TEDD-1) and upto ring 7 for discs 3,4&5 (TEDD-2)
657  bool isPStypeModForTEDD_1 =
658  (!pixelFlag_ && layer > 100 && tTopo_->tidWheel(det_id) < 3 && tTopo_->tidRing(det_id) <= 10) ? true : false;
659  bool isPStypeModForTEDD_2 =
660  (!pixelFlag_ && layer > 100 && tTopo_->tidWheel(det_id) >= 3 && tTopo_->tidRing(det_id) <= 7) ? true : false;
661 
662  bool isPtypeSensor =
663  (flag || (layer < 4 || (layer > 6 && (isPStypeModForTEDD_1 || isPStypeModForTEDD_2)))) ? true : false;
664 
665  ibooker.cd();
666  ibooker.setCurrentFolder(top_folder + "/DigiMonitor/" + key);
667  edm::LogInfo("Phase2TrackerValidateDigi") << " Booking Histograms in : " << key;
668 
669  std::ostringstream HistoName;
670  DigiMEs local_mes;
671 
673  HistoName.str("");
674  HistoName << "SimTrackPt";
675  if (Parameters.getParameter<bool>("switch"))
676  local_mes.SimTrackPt = ibooker.book1D(HistoName.str(),
677  HistoName.str(),
678  Parameters.getParameter<int32_t>("Nbins"),
679  Parameters.getParameter<double>("xmin"),
680  Parameters.getParameter<double>("xmax"));
681  else
682  local_mes.SimTrackPt = nullptr;
683  HistoName.str("");
684  HistoName << "MatchedTrackPt";
685  if (Parameters.getParameter<bool>("switch"))
686  local_mes.MatchedTrackPt = ibooker.book1D(HistoName.str(),
687  HistoName.str(),
688  Parameters.getParameter<int32_t>("Nbins"),
689  Parameters.getParameter<double>("xmin"),
690  Parameters.getParameter<double>("xmax"));
691  else
692  local_mes.MatchedTrackPt = nullptr;
693  HistoName.str("");
694  HistoName << "MissedHitTrackPt";
695  if (Parameters.getParameter<bool>("switch"))
696  local_mes.MissedHitTrackPt = ibooker.book1D(HistoName.str(),
697  HistoName.str(),
698  Parameters.getParameter<int32_t>("Nbins"),
699  Parameters.getParameter<double>("xmin"),
700  Parameters.getParameter<double>("xmax"));
701  else
702  local_mes.MissedHitTrackPt = nullptr;
703  HistoName.str("");
704  HistoName << "MissedDigiTrackPt";
705  if (Parameters.getParameter<bool>("switch"))
706  local_mes.MissedDigiTrackPt = ibooker.book1D(HistoName.str(),
707  HistoName.str(),
708  Parameters.getParameter<int32_t>("Nbins"),
709  Parameters.getParameter<double>("xmin"),
710  Parameters.getParameter<double>("xmax"));
711  else
712  local_mes.MissedDigiTrackPt = nullptr;
713 
715  HistoName.str("");
716  HistoName << "SimTrackEta";
717  if (Parameters.getParameter<bool>("switch"))
718  local_mes.SimTrackEta = ibooker.book1D(HistoName.str(),
719  HistoName.str(),
720  Parameters.getParameter<int32_t>("Nbins"),
721  Parameters.getParameter<double>("xmin"),
722  Parameters.getParameter<double>("xmax"));
723  else
724  local_mes.SimTrackEta = nullptr;
725  HistoName.str("");
726  HistoName << "MatchedTrackEta";
727  if (Parameters.getParameter<bool>("switch"))
728  local_mes.MatchedTrackEta = ibooker.book1D(HistoName.str(),
729  HistoName.str(),
730  Parameters.getParameter<int32_t>("Nbins"),
731  Parameters.getParameter<double>("xmin"),
732  Parameters.getParameter<double>("xmax"));
733  else
734  local_mes.MatchedTrackEta = nullptr;
735  HistoName.str("");
736  HistoName << "MissedHitTrackEta";
737  if (Parameters.getParameter<bool>("switch"))
738  local_mes.MissedHitTrackEta = ibooker.book1D(HistoName.str(),
739  HistoName.str(),
740  Parameters.getParameter<int32_t>("Nbins"),
741  Parameters.getParameter<double>("xmin"),
742  Parameters.getParameter<double>("xmax"));
743  else
744  local_mes.MissedHitTrackEta = nullptr;
745  HistoName.str("");
746  HistoName << "MissedDigiTrackEta";
747  if (Parameters.getParameter<bool>("switch"))
748  local_mes.MissedDigiTrackEta = ibooker.book1D(HistoName.str(),
749  HistoName.str(),
750  Parameters.getParameter<int32_t>("Nbins"),
751  Parameters.getParameter<double>("xmin"),
752  Parameters.getParameter<double>("xmax"));
753  else
754  local_mes.MissedDigiTrackEta = nullptr;
755 
757  HistoName.str("");
758  HistoName << "SimTrackPhi";
759  if (Parameters.getParameter<bool>("switch"))
760  local_mes.SimTrackPhi = ibooker.book1D(HistoName.str(),
761  HistoName.str(),
762  Parameters.getParameter<int32_t>("Nbins"),
763  Parameters.getParameter<double>("xmin"),
764  Parameters.getParameter<double>("xmax"));
765  else
766  local_mes.SimTrackPhi = nullptr;
767  HistoName.str("");
768  HistoName << "MatchedTrackPhi";
769  if (Parameters.getParameter<bool>("switch"))
770  local_mes.MatchedTrackPhi = ibooker.book1D(HistoName.str(),
771  HistoName.str(),
772  Parameters.getParameter<int32_t>("Nbins"),
773  Parameters.getParameter<double>("xmin"),
774  Parameters.getParameter<double>("xmax"));
775  else
776  local_mes.MatchedTrackPhi = nullptr;
777  HistoName.str("");
778  HistoName << "MissedHitTrackPhi";
779  if (Parameters.getParameter<bool>("switch"))
780  local_mes.MissedHitTrackPhi = ibooker.book1D(HistoName.str(),
781  HistoName.str(),
782  Parameters.getParameter<int32_t>("Nbins"),
783  Parameters.getParameter<double>("xmin"),
784  Parameters.getParameter<double>("xmax"));
785  else
786  local_mes.MissedHitTrackPhi = nullptr;
787  HistoName.str("");
788  HistoName << "MissedDigiTrackPhi";
789  if (Parameters.getParameter<bool>("switch"))
790  local_mes.MissedDigiTrackPhi = ibooker.book1D(HistoName.str(),
791  HistoName.str(),
792  Parameters.getParameter<int32_t>("Nbins"),
793  Parameters.getParameter<double>("xmin"),
794  Parameters.getParameter<double>("xmax"));
795  else
796  local_mes.MissedDigiTrackPhi = nullptr;
797 
799  if (!flag) {
800  HistoName.str("");
801  HistoName << "MatchedSimHitElossS";
802  if (Parameters.getParameter<bool>("switch"))
803  local_mes.MatchedSimHitElossS = ibooker.book1D(HistoName.str(),
804  HistoName.str(),
805  Parameters.getParameter<int32_t>("Nbins"),
806  Parameters.getParameter<double>("xmin"),
807  Parameters.getParameter<double>("xmax"));
808  else
809  local_mes.MatchedSimHitElossS = nullptr;
810  HistoName.str("");
811  HistoName << "MissedDigiSimHitElossS";
812  if (Parameters.getParameter<bool>("switch"))
813  local_mes.MissedDigiSimHitElossS = ibooker.book1D(HistoName.str(),
814  HistoName.str(),
815  Parameters.getParameter<int32_t>("Nbins"),
816  Parameters.getParameter<double>("xmin"),
817  Parameters.getParameter<double>("xmax"));
818  else
819  local_mes.MissedDigiSimHitElossS = nullptr;
820  }
821  if (isPtypeSensor) {
822  HistoName.str("");
823  HistoName << "MatchedSimHitElossP";
824  if (Parameters.getParameter<bool>("switch"))
825  local_mes.MatchedSimHitElossP = ibooker.book1D(HistoName.str(),
826  HistoName.str(),
827  Parameters.getParameter<int32_t>("Nbins"),
828  Parameters.getParameter<double>("xmin"),
829  Parameters.getParameter<double>("xmax"));
830  else
831  local_mes.MatchedSimHitElossP = nullptr;
832  HistoName.str("");
833  HistoName << "MissedDigiSimHitElossP";
834  if (Parameters.getParameter<bool>("switch"))
835  local_mes.MissedDigiSimHitElossP = ibooker.book1D(HistoName.str(),
836  HistoName.str(),
837  Parameters.getParameter<int32_t>("Nbins"),
838  Parameters.getParameter<double>("xmin"),
839  Parameters.getParameter<double>("xmax"));
840  else
841  local_mes.MissedDigiSimHitElossP = nullptr;
842  }
844  HistoName.str("");
845  HistoName << "SimHitDx";
846  if (Parameters.getParameter<bool>("switch"))
847  local_mes.SimHitDx = ibooker.book1D(HistoName.str(),
848  HistoName.str(),
849  Parameters.getParameter<int32_t>("Nbins"),
850  Parameters.getParameter<double>("xmin"),
851  Parameters.getParameter<double>("xmax"));
852  else
853  local_mes.SimHitDx = nullptr;
854 
856  HistoName.str("");
857  HistoName << "SimHitDy";
858  if (Parameters.getParameter<bool>("switch"))
859  local_mes.SimHitDy = ibooker.book1D(HistoName.str(),
860  HistoName.str(),
861  Parameters.getParameter<int32_t>("Nbins"),
862  Parameters.getParameter<double>("xmin"),
863  Parameters.getParameter<double>("xmax"));
864  else
865  local_mes.SimHitDy = nullptr;
866 
868  HistoName.str("");
869  HistoName << "SimHitDz";
870  if (Parameters.getParameter<bool>("switch"))
871  local_mes.SimHitDz = ibooker.book1D(HistoName.str(),
872  HistoName.str(),
873  Parameters.getParameter<int32_t>("Nbins"),
874  Parameters.getParameter<double>("xmin"),
875  Parameters.getParameter<double>("xmax"));
876  else
877  local_mes.SimHitDz = nullptr;
878 
879  HistoName.str("");
880  HistoName << "BunchXingWindow";
881  local_mes.BunchXTimeBin = ibooker.book1D(HistoName.str(), HistoName.str(), 8, -5.5, 2.5);
882 
883  HistoName.str("");
884  HistoName << "FractionOfOOTPUDigi";
885  local_mes.FractionOfOOTDigis = ibooker.bookProfile(HistoName.str(), HistoName.str(), 8, -5.5, 2.5, 0., 1.0, "s");
886 
887  HistoName.str("");
888  HistoName << "MissedDigiLocalXPosvsYPos";
889  local_mes.MissedDigiLocalXposVsYPos =
890  ibooker.book2D(HistoName.str(), HistoName.str(), 130, -6.5, 6.5, 130, -6.5, 6.5);
891 
893  HistoName.str("");
894  HistoName << "MissedDigiTimeWindow";
895  if (Parameters.getParameter<bool>("switch"))
896  local_mes.MissedDigiTimeWindow = ibooker.book1D(HistoName.str(), HistoName.str(), 100, -0.5, 49.5);
897  else
898  local_mes.MissedDigiTimeWindow = nullptr;
899  local_mes.nDigis = 0;
900  layerMEs.insert(std::make_pair(key, local_mes));
901  }
902 }

References dqm::implementation::IBooker::book1D(), dqm::implementation::IBooker::book2D(), dqm::implementation::IBooker::bookProfile(), Phase2TrackerValidateDigi::DigiMEs::BunchXTimeBin, dqm::implementation::NavigatorBase::cd(), config_, RemoveAddSevLevel::flag, fed_dqm_sourceclient-live_cfg::folder_name, Phase2TrackerValidateDigi::DigiMEs::FractionOfOOTDigis, getHistoId(), TrackerTopology::getITPixelLayerNumber(), TrackerTopology::getOTLayerNumber(), edm::ParameterSet::getParameter(), crabWrapper::key, phase1PixelTopology::layer, layerMEs, Phase2TrackerValidateDigi::DigiMEs::MatchedSimHitElossP, Phase2TrackerValidateDigi::DigiMEs::MatchedSimHitElossS, Phase2TrackerValidateDigi::DigiMEs::MatchedTrackEta, Phase2TrackerValidateDigi::DigiMEs::MatchedTrackPhi, Phase2TrackerValidateDigi::DigiMEs::MatchedTrackPt, Phase2TrackerValidateDigi::DigiMEs::MissedDigiLocalXposVsYPos, Phase2TrackerValidateDigi::DigiMEs::MissedDigiSimHitElossP, Phase2TrackerValidateDigi::DigiMEs::MissedDigiSimHitElossS, Phase2TrackerValidateDigi::DigiMEs::MissedDigiTimeWindow, Phase2TrackerValidateDigi::DigiMEs::MissedDigiTrackEta, Phase2TrackerValidateDigi::DigiMEs::MissedDigiTrackPhi, Phase2TrackerValidateDigi::DigiMEs::MissedDigiTrackPt, Phase2TrackerValidateDigi::DigiMEs::MissedHitTrackEta, Phase2TrackerValidateDigi::DigiMEs::MissedHitTrackPhi, Phase2TrackerValidateDigi::DigiMEs::MissedHitTrackPt, Phase2TrackerValidateDigi::DigiMEs::nDigis, pixelFlag_, dqm::implementation::NavigatorBase::setCurrentFolder(), Phase2TrackerValidateDigi::DigiMEs::SimHitDx, Phase2TrackerValidateDigi::DigiMEs::SimHitDy, Phase2TrackerValidateDigi::DigiMEs::SimHitDz, Phase2TrackerValidateDigi::DigiMEs::SimTrackEta, Phase2TrackerValidateDigi::DigiMEs::SimTrackPhi, Phase2TrackerValidateDigi::DigiMEs::SimTrackPt, AlCaHLTBitMon_QueryRunRegistry::string, TrackerTopology::tidRing(), TrackerTopology::tidWheel(), funct::true, and tTopo_.

Referenced by bookHistograms().

◆ dqmBeginRun()

void Phase2TrackerValidateDigi::dqmBeginRun ( const edm::Run iRun,
const edm::EventSetup iSetup 
)
overridevirtual

Reimplemented from DQMEDAnalyzer.

Definition at line 92 of file Phase2TrackerValidateDigi.cc.

92  {
93  edm::ESWatcher<TrackerDigiGeometryRecord> theTkDigiGeomWatcher;
95  if (theTkDigiGeomWatcher.check(iSetup)) {
96  geomHandle = iSetup.getHandle(geomToken_);
97  }
98  if (!geomHandle.isValid())
99  return;
100  tkGeom_ = &(*geomHandle);
101 
103  tTopo_ = tTopoHandle.product();
104 }

References edm::ESWatcher< T >::check(), geomToken_, edm::EventSetup::getHandle(), edm::ESHandleBase::isValid(), edm::ESHandle< T >::product(), tkGeom_, topoToken_, and tTopo_.

◆ fillHistogram()

void Phase2TrackerValidateDigi::fillHistogram ( MonitorElement th1,
MonitorElement th2,
MonitorElement th3,
float  val,
int  primary 
)
private

Definition at line 1028 of file Phase2TrackerValidateDigi.cc.

1029  {
1030  if (th1)
1031  th1->Fill(val);
1032  if (th2 && primary == 1)
1033  th2->Fill(val);
1034  if (th3 && primary != 1)
1035  th3->Fill(val);
1036 }

References dqm::impl::MonitorElement::Fill(), and heppy_batch::val.

Referenced by analyze().

◆ fillHitsPerTrack()

void Phase2TrackerValidateDigi::fillHitsPerTrack ( )
private

◆ fillITPixelBXInfo()

void Phase2TrackerValidateDigi::fillITPixelBXInfo ( )
private

Definition at line 963 of file Phase2TrackerValidateDigi.cc.

963  {
965  for (typename edm::DetSetVector<PixelDigiSimLink>::const_iterator DSViter = links->begin(); DSViter != links->end();
966  DSViter++) {
967  unsigned int rawid = DSViter->id;
968  DetId detId(rawid);
969  if (DetId(detId).det() != DetId::Detector::Tracker)
970  continue;
971  int layer = tTopo_->getITPixelLayerNumber(rawid);
972  if (layer < 0)
973  continue;
974  bool flag_ = true;
975  std::string key = getHistoId(rawid, flag_);
976  std::map<std::string, DigiMEs>::iterator pos = layerMEs.find(key);
977  if (pos == layerMEs.end())
978  continue;
979  DigiMEs& local_mes = pos->second;
980  int tot_digi = 0;
981  std::map<int, float> bxMap;
982  for (typename edm::DetSet<PixelDigiSimLink>::const_iterator di = DSViter->begin(); di != DSViter->end(); di++) {
983  tot_digi++;
984  int bx = di->eventId().bunchCrossing();
985  std::map<int, float>::iterator ic = bxMap.find(bx);
986  if (ic == bxMap.end())
987  bxMap[bx] = 1.0;
988  else
989  bxMap[bx] += 1.0;
990  }
991  for (const auto& v : bxMap) {
992  if (tot_digi) {
993  local_mes.BunchXTimeBin->Fill(v.first, v.second);
994  local_mes.FractionOfOOTDigis->Fill(v.first, v.second / tot_digi);
995  }
996  }
997  }
998 }

References Phase2TrackerValidateDigi::DigiMEs::BunchXTimeBin, l1GtPatternGenerator_cfi::bx, dqm::impl::MonitorElement::Fill(), flag_, Phase2TrackerValidateDigi::DigiMEs::FractionOfOOTDigis, getHistoId(), TrackerTopology::getITPixelLayerNumber(), itPixelSimLinkHandle_, crabWrapper::key, phase1PixelTopology::layer, layerMEs, electronStore::links, edm::Handle< T >::product(), AlCaHLTBitMon_QueryRunRegistry::string, align::Tracker, tTopo_, and findQualityFiles::v.

Referenced by analyze().

◆ fillOTBXInfo()

void Phase2TrackerValidateDigi::fillOTBXInfo ( )
private

Definition at line 927 of file Phase2TrackerValidateDigi.cc.

927  {
929  for (typename edm::DetSetVector<PixelDigiSimLink>::const_iterator DSViter = links->begin(); DSViter != links->end();
930  DSViter++) {
931  unsigned int rawid = DSViter->id;
932  DetId detId(rawid);
933  if (DetId(detId).det() != DetId::Detector::Tracker)
934  continue;
935  int layer = tTopo_->getOTLayerNumber(rawid);
936  if (layer < 0)
937  continue;
938  bool flag_ = false;
939  std::string key = getHistoId(rawid, flag_);
940  std::map<std::string, DigiMEs>::iterator pos = layerMEs.find(key);
941  if (pos == layerMEs.end())
942  continue;
943  DigiMEs& local_mes = pos->second;
944  int tot_digi = 0;
945  std::map<int, float> bxMap;
946  for (typename edm::DetSet<PixelDigiSimLink>::const_iterator di = DSViter->begin(); di != DSViter->end(); di++) {
947  tot_digi++;
948  int bx = di->eventId().bunchCrossing();
949  std::map<int, float>::iterator ic = bxMap.find(bx);
950  if (ic == bxMap.end())
951  bxMap[bx] = 1.0;
952  else
953  bxMap[bx] += 1.0;
954  }
955  for (const auto& v : bxMap) {
956  if (tot_digi) {
957  local_mes.BunchXTimeBin->Fill(v.first, v.second);
958  local_mes.FractionOfOOTDigis->Fill(v.first, v.second / tot_digi);
959  }
960  }
961  }
962 }

References Phase2TrackerValidateDigi::DigiMEs::BunchXTimeBin, l1GtPatternGenerator_cfi::bx, dqm::impl::MonitorElement::Fill(), flag_, Phase2TrackerValidateDigi::DigiMEs::FractionOfOOTDigis, getHistoId(), TrackerTopology::getOTLayerNumber(), crabWrapper::key, phase1PixelTopology::layer, layerMEs, electronStore::links, otSimLinkHandle_, edm::Handle< T >::product(), AlCaHLTBitMon_QueryRunRegistry::string, align::Tracker, tTopo_, and findQualityFiles::v.

Referenced by analyze().

◆ fillSimHitInfo()

int Phase2TrackerValidateDigi::fillSimHitInfo ( const edm::Event iEvent,
const SimTrack  simTrk 
)
private

Definition at line 195 of file Phase2TrackerValidateDigi.cc.

195  {
196  int totalHits = 0;
197 
198  unsigned int id = simTrk.trackId();
199  for (const auto& itoken : simHitTokens_) {
201  iEvent.getByToken(itoken, simHitHandle);
202  if (!simHitHandle.isValid())
203  continue;
204  const edm::PSimHitContainer& simHits = (*simHitHandle.product());
205  for (edm::PSimHitContainer::const_iterator isim = simHits.begin(); isim != simHits.end(); ++isim) {
206  if ((*isim).trackId() != id)
207  continue;
208  const PSimHit& simHit = (*isim);
209 
210  if (!isPrimary(simTrk, simHit))
211  continue;
212 
213  unsigned int rawid = (*isim).detUnitId();
214  int layer;
215  if (pixelFlag_)
217  else
218  layer = tTopo_->getOTLayerNumber(rawid);
219  if (layer < 0)
220  continue;
222  auto pos = layerMEs.find(key);
223  if (pos == layerMEs.end())
224  continue;
225  DigiMEs& local_mes = pos->second;
226 
227  const DetId detId(rawid);
228  float dZ = (*isim).entryPoint().z() - (*isim).exitPoint().z();
229  if (fabs(dZ) <= 0.01)
230  continue;
231 
232  if (DetId(detId).det() != DetId::Detector::Tracker)
233  continue;
234 
235  const GeomDet* geomDet = tkGeom_->idToDet(detId);
236  if (!geomDet)
237  continue;
238  Global3DPoint pdPos = geomDet->surface().toGlobal(isim->localPosition());
239 
240  if (((*isim).tof() - pdPos.mag() / cval) < tofLowerCut_ || ((*isim).tof() - pdPos.mag() / cval) > tofUpperCut_)
241  continue;
242 
244  SimulatedXYPositionMap->Fill(pdPos.x() * 10., pdPos.y() * 10.);
246  SimulatedRZPositionMap->Fill(pdPos.z() * 10., std::hypot(pdPos.x(), pdPos.y()) * 10.);
247 
248  const TrackerGeomDet* geomDetUnit(tkGeom_->idToDetUnit(detId));
249  const Phase2TrackerGeomDetUnit* tkDetUnit = dynamic_cast<const Phase2TrackerGeomDetUnit*>(geomDetUnit);
250  int nColumns = tkDetUnit->specificTopology().ncolumns();
251 
252  float pt = simTrk.momentum().pt();
253  float eta = simTrk.momentum().eta();
254  float phi = simTrk.momentum().phi();
255  totalHits++;
256  pos->second.nHits++;
257 
258  if (local_mes.SimHitDx)
259  local_mes.SimHitDx->Fill(std::fabs((*isim).entryPoint().x() - (*isim).exitPoint().x()));
260  if (local_mes.SimHitDy)
261  local_mes.SimHitDy->Fill(std::fabs((*isim).entryPoint().y() - (*isim).exitPoint().y()));
262  if (local_mes.SimHitDz)
263  local_mes.SimHitDz->Fill(std::fabs((*isim).entryPoint().z() - (*isim).exitPoint().z()));
264 
265  if (SimulatedTOFEtaMap)
266  SimulatedTOFEtaMap->Fill(pdPos.eta(), (*isim).timeOfFlight());
267  if (SimulatedTOFPhiMap)
268  SimulatedTOFPhiMap->Fill(pdPos.phi(), (*isim).timeOfFlight());
269  if (SimulatedTOFRMap)
270  SimulatedTOFRMap->Fill(std::hypot(pdPos.x(), pdPos.y()), (*isim).timeOfFlight());
271  if (SimulatedTOFZMap)
272  SimulatedTOFZMap->Fill(pdPos.z(), (*isim).timeOfFlight());
273 
274  bool digiFlag;
275 
276  if (pixelFlag_)
277  digiFlag = findITPixelDigi(rawid, id);
278  else
279  digiFlag = findOTDigi(rawid, id);
280 
281  if (fabs(eta) < etaCut_) {
282  if (local_mes.SimTrackPt)
283  local_mes.SimTrackPt->Fill(pt);
284  if (digiFlag && local_mes.MatchedTrackPt)
285  local_mes.MatchedTrackPt->Fill(pt);
286  else if (local_mes.MissedDigiTrackPt)
287  local_mes.MissedDigiTrackPt->Fill(pt);
288  }
289  if (pt > ptCut_) {
290  if (local_mes.SimTrackEta)
291  local_mes.SimTrackEta->Fill(eta);
292  if (digiFlag && local_mes.MatchedTrackEta)
293  local_mes.MatchedTrackEta->Fill(eta);
294  else if (local_mes.MissedDigiTrackEta)
295  local_mes.MissedDigiTrackEta->Fill(eta);
296  }
297  if (fabs(eta) < etaCut_ && pt > ptCut_) {
298  if (local_mes.SimTrackPhi)
299  local_mes.SimTrackPhi->Fill(phi);
300  if (digiFlag && local_mes.MatchedTrackPhi)
301  local_mes.MatchedTrackPhi->Fill(phi);
302  else if (local_mes.MissedDigiTrackPhi)
303  local_mes.MissedDigiTrackPhi->Fill(phi);
304  }
305  if (digiFlag) {
306  pos->second.nDigis++;
308  MatchedRZPositionMap->Fill(pdPos.z() * 10., std::hypot(pdPos.x(), pdPos.y()) * 10.);
310  MatchedXYPositionMap->Fill(pdPos.x() * 10., pdPos.y() * 10.);
311  if (nColumns <= 2 && local_mes.MatchedSimHitElossS)
312  local_mes.MatchedSimHitElossS->Fill((*isim).energyLoss() / GeVperElectron);
313  else if (local_mes.MatchedSimHitElossP)
314  local_mes.MatchedSimHitElossP->Fill((*isim).energyLoss() / GeVperElectron);
315  } else {
316  if (local_mes.MissedDigiLocalXposVsYPos)
317  local_mes.MissedDigiLocalXposVsYPos->Fill((*isim).localPosition().x(), (*isim).localPosition().y());
318  if (local_mes.MissedDigiTimeWindow)
319  local_mes.MissedDigiTimeWindow->Fill(std::fabs((*isim).timeOfFlight() - pdPos.mag() / cval));
320  if (nColumns <= 2 && local_mes.MissedDigiSimHitElossS)
321  local_mes.MissedDigiSimHitElossS->Fill((*isim).energyLoss() / GeVperElectron);
322  else if (local_mes.MissedDigiSimHitElossP)
323  local_mes.MissedDigiSimHitElossP->Fill((*isim).energyLoss() / GeVperElectron);
324  }
325  }
326  }
327  return totalHits;
328 }

References cval, PVValHelper::eta, PV3DBase< T, PVType, FrameType >::eta(), etaCut_, dqm::impl::MonitorElement::Fill(), findITPixelDigi(), findOTDigi(), getHistoId(), TrackerTopology::getITPixelLayerNumber(), TrackerTopology::getOTLayerNumber(), GeVperElectron, triggerObjects_cff::id, TrackerGeometry::idToDet(), TrackerGeometry::idToDetUnit(), iEvent, isPrimary(), edm::HandleBase::isValid(), crabWrapper::key, phase1PixelTopology::layer, layerMEs, PV3DBase< T, PVType, FrameType >::mag(), MatchedRZPositionMap, Phase2TrackerValidateDigi::DigiMEs::MatchedSimHitElossP, Phase2TrackerValidateDigi::DigiMEs::MatchedSimHitElossS, Phase2TrackerValidateDigi::DigiMEs::MatchedTrackEta, Phase2TrackerValidateDigi::DigiMEs::MatchedTrackPhi, Phase2TrackerValidateDigi::DigiMEs::MatchedTrackPt, MatchedXYPositionMap, Phase2TrackerValidateDigi::DigiMEs::MissedDigiLocalXposVsYPos, Phase2TrackerValidateDigi::DigiMEs::MissedDigiSimHitElossP, Phase2TrackerValidateDigi::DigiMEs::MissedDigiSimHitElossS, Phase2TrackerValidateDigi::DigiMEs::MissedDigiTimeWindow, Phase2TrackerValidateDigi::DigiMEs::MissedDigiTrackEta, Phase2TrackerValidateDigi::DigiMEs::MissedDigiTrackPhi, Phase2TrackerValidateDigi::DigiMEs::MissedDigiTrackPt, CoreSimTrack::momentum(), phi, PV3DBase< T, PVType, FrameType >::phi(), pixelFlag_, edm::Handle< T >::product(), DiDispStaMuonMonitor_cfi::pt, ptCut_, rpcPointValidation_cfi::simHit, Phase2TrackerValidateDigi::DigiMEs::SimHitDx, Phase2TrackerValidateDigi::DigiMEs::SimHitDy, Phase2TrackerValidateDigi::DigiMEs::SimHitDz, simHits, simHitTokens_, Phase2TrackerValidateDigi::DigiMEs::SimTrackEta, Phase2TrackerValidateDigi::DigiMEs::SimTrackPhi, Phase2TrackerValidateDigi::DigiMEs::SimTrackPt, SimulatedRZPositionMap, SimulatedTOFEtaMap, SimulatedTOFPhiMap, SimulatedTOFRMap, SimulatedTOFZMap, SimulatedXYPositionMap, AlCaHLTBitMon_QueryRunRegistry::string, GeomDet::surface(), tkGeom_, tofLowerCut_, tofUpperCut_, Surface::toGlobal(), align::Tracker, CoreSimTrack::trackId(), tTopo_, PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), and PV3DBase< T, PVType, FrameType >::z().

Referenced by analyze().

◆ findITPixelDigi()

bool Phase2TrackerValidateDigi::findITPixelDigi ( unsigned int  detid,
unsigned int  id 
)
private

Definition at line 348 of file Phase2TrackerValidateDigi.cc.

348  {
349  bool matched = false;
352 
353  edm::DetSetVector<PixelDigi>::const_iterator DSVIter = digis->find(detid);
354  if (DSVIter != digis->end()) {
355  for (edm::DetSet<PixelDigi>::const_iterator di = DSVIter->begin(); di != DSVIter->end(); di++) {
356  int col = di->column(); // column
357  int row = di->row(); // row
358  unsigned int channel = PixelDigi::pixelToChannel(row, col);
359  unsigned int simTkId = getSimTrackId(links, detid, channel);
360  if (simTkId == id) {
361  matched = true;
362  break;
363  }
364  }
365  }
366  return matched;
367 }

References edm::DetSetVector< T >::begin(), cuy::col, edm::DetSetVector< T >::end(), edm::DetSetVector< T >::find(), getSimTrackId(), itPixelDigiHandle_, itPixelSimLinkHandle_, electronStore::links, muonTagProbeFilters_cff::matched, PixelDigi::pixelToChannel(), and edm::Handle< T >::product().

Referenced by fillSimHitInfo().

◆ findOTDigi()

bool Phase2TrackerValidateDigi::findOTDigi ( unsigned int  detid,
unsigned int  id 
)
private

Definition at line 329 of file Phase2TrackerValidateDigi.cc.

329  {
330  bool matched = false;
334  if (DSVIter != digis->end()) {
335  for (edm::DetSet<Phase2TrackerDigi>::const_iterator di = DSVIter->begin(); di != DSVIter->end(); di++) {
336  int col = di->column(); // column
337  int row = di->row(); // row
338  unsigned int channel = Phase2TrackerDigi::pixelToChannel(row, col);
339  unsigned int simTkId = getSimTrackId(links, detid, channel);
340  if (simTkId == id) {
341  matched = true;
342  break;
343  }
344  }
345  }
346  return matched;
347 }

References edm::DetSetVector< T >::begin(), cuy::col, edm::DetSetVector< T >::end(), edm::DetSetVector< T >::find(), getSimTrackId(), electronStore::links, muonTagProbeFilters_cff::matched, otDigiHandle_, otSimLinkHandle_, Phase2TrackerDigi::pixelToChannel(), and edm::Handle< T >::product().

Referenced by fillSimHitInfo().

◆ getHistoId()

std::string Phase2TrackerValidateDigi::getHistoId ( uint32_t  det_id,
bool  flag 
)

Definition at line 1058 of file Phase2TrackerValidateDigi.cc.

1058  {
1059  if (flag)
1060  return phase2tkutil::getITHistoId(det_id, tTopo_);
1061  else
1062  return phase2tkutil::getOTHistoId(det_id, tTopo_);
1063 }

References RemoveAddSevLevel::flag, phase2tkutil::getITHistoId(), phase2tkutil::getOTHistoId(), and tTopo_.

Referenced by bookLayerHistos(), fillITPixelBXInfo(), fillOTBXInfo(), and fillSimHitInfo().

◆ getSimTrackId()

unsigned int Phase2TrackerValidateDigi::getSimTrackId ( const edm::DetSetVector< PixelDigiSimLink > *  simLinks,
const DetId detId,
unsigned int &  channel 
)
private

Definition at line 906 of file Phase2TrackerValidateDigi.cc.

908  {
910 
911  unsigned int simTrkId(0);
912  if (isearch == simLinks->end())
913  return simTrkId;
914 
915  edm::DetSet<PixelDigiSimLink> link_detset = (*simLinks)[detId];
916  // Loop over DigiSimLink in this det unit
917  int iSimLink = 0;
918  for (edm::DetSet<PixelDigiSimLink>::const_iterator it = link_detset.data.begin(); it != link_detset.data.end();
919  it++, iSimLink++) {
920  if (channel == it->channel()) {
921  simTrkId = it->SimTrackId();
922  break;
923  }
924  }
925  return simTrkId;
926 }

References edm::DetSet< T >::data, edm::DetSetVector< T >::end(), and edm::DetSetVector< T >::find().

Referenced by findITPixelDigi(), and findOTDigi().

◆ isPrimary()

bool Phase2TrackerValidateDigi::isPrimary ( const SimTrack simTrk,
const PSimHit simHit 
)
private

Definition at line 1014 of file Phase2TrackerValidateDigi.cc.

1014  {
1015  bool retval = false;
1016  unsigned int trkId = simTrk.trackId();
1017  if (trkId != simHit.trackId())
1018  return retval;
1019  int vtxIndex = simTrk.vertIndex();
1020  int ptype = simHit.processType();
1021  if ((vtxIndex == 0) && (ptype == 0))
1022  retval = true;
1023  return retval;
1024 }

References OfflineHarvestingSequence_cosmic::ptype, rpcPointValidation_cfi::simHit, CoreSimTrack::trackId(), and SimTrack::vertIndex().

Referenced by fillSimHitInfo().

◆ matchedSimTrack()

int Phase2TrackerValidateDigi::matchedSimTrack ( edm::Handle< edm::SimTrackContainer > &  SimTk,
unsigned int  simTrkId 
)
private

Definition at line 1002 of file Phase2TrackerValidateDigi.cc.

1002  {
1003  edm::SimTrackContainer sim_tracks = (*SimTk.product());
1004  for (unsigned int it = 0; it < sim_tracks.size(); it++) {
1005  if (sim_tracks[it].trackId() == simTrkId) {
1006  return it;
1007  }
1008  }
1009  return -1;
1010 }

References edm::Handle< T >::product().

Referenced by analyze().

Member Data Documentation

◆ config_

edm::ParameterSet Phase2TrackerValidateDigi::config_
private

◆ cval

const float Phase2TrackerValidateDigi::cval
private

Definition at line 152 of file Phase2TrackerValidateDigi.h.

Referenced by fillSimHitInfo().

◆ etaCut_

float Phase2TrackerValidateDigi::etaCut_
private

Definition at line 97 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), fillSimHitInfo(), and Phase2TrackerValidateDigi().

◆ geomToken_

const edm::ESGetToken<TrackerGeometry, TrackerDigiGeometryRecord> Phase2TrackerValidateDigi::geomToken_
private

Definition at line 146 of file Phase2TrackerValidateDigi.h.

Referenced by dqmBeginRun().

◆ geomType_

std::string Phase2TrackerValidateDigi::geomType_
private

Definition at line 121 of file Phase2TrackerValidateDigi.h.

◆ GeVperElectron

const float Phase2TrackerValidateDigi::GeVperElectron
private

Definition at line 151 of file Phase2TrackerValidateDigi.h.

Referenced by fillSimHitInfo().

◆ itPixelDigiHandle_

edm::Handle<edm::DetSetVector<PixelDigi> > Phase2TrackerValidateDigi::itPixelDigiHandle_
private

Definition at line 139 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and findITPixelDigi().

◆ itPixelDigiSimLinkSrc_

edm::InputTag Phase2TrackerValidateDigi::itPixelDigiSimLinkSrc_
private

Definition at line 126 of file Phase2TrackerValidateDigi.h.

◆ itPixelDigiSimLinkToken_

const edm::EDGetTokenT<edm::DetSetVector<PixelDigiSimLink> > Phase2TrackerValidateDigi::itPixelDigiSimLinkToken_
private

Definition at line 134 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ itPixelDigiSrc_

edm::InputTag Phase2TrackerValidateDigi::itPixelDigiSrc_
private

Definition at line 125 of file Phase2TrackerValidateDigi.h.

◆ itPixelDigiToken_

const edm::EDGetTokenT<edm::DetSetVector<PixelDigi> > Phase2TrackerValidateDigi::itPixelDigiToken_
private

Definition at line 133 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ itPixelSimLinkHandle_

edm::Handle<edm::DetSetVector<PixelDigiSimLink> > Phase2TrackerValidateDigi::itPixelSimLinkHandle_
private

Definition at line 141 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), fillITPixelBXInfo(), and findITPixelDigi().

◆ layerMEs

std::map<std::string, DigiMEs> Phase2TrackerValidateDigi::layerMEs
private

◆ MatchedRZPositionMap

MonitorElement* Phase2TrackerValidateDigi::MatchedRZPositionMap
private

Definition at line 89 of file Phase2TrackerValidateDigi.h.

Referenced by bookHistograms(), and fillSimHitInfo().

◆ MatchedXYPositionMap

MonitorElement* Phase2TrackerValidateDigi::MatchedXYPositionMap
private

Definition at line 88 of file Phase2TrackerValidateDigi.h.

Referenced by bookHistograms(), and fillSimHitInfo().

◆ nSimHitsPerTrack

MonitorElement* Phase2TrackerValidateDigi::nSimHitsPerTrack
private

Definition at line 96 of file Phase2TrackerValidateDigi.h.

◆ nSimulatedTracks

MonitorElement* Phase2TrackerValidateDigi::nSimulatedTracks
private

Definition at line 67 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and bookHistograms().

◆ nSimulatedTracksP

MonitorElement* Phase2TrackerValidateDigi::nSimulatedTracksP
private

Definition at line 68 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and bookHistograms().

◆ nSimulatedTracksS

MonitorElement* Phase2TrackerValidateDigi::nSimulatedTracksS
private

Definition at line 69 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and bookHistograms().

◆ nSimVertices

MonitorElement* Phase2TrackerValidateDigi::nSimVertices
private

Definition at line 71 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and bookHistograms().

◆ otDigiHandle_

edm::Handle<edm::DetSetVector<Phase2TrackerDigi> > Phase2TrackerValidateDigi::otDigiHandle_
private

Definition at line 140 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and findOTDigi().

◆ otDigiSimLinkSrc_

edm::InputTag Phase2TrackerValidateDigi::otDigiSimLinkSrc_
private

Definition at line 124 of file Phase2TrackerValidateDigi.h.

◆ otDigiSimLinkToken_

const edm::EDGetTokenT<edm::DetSetVector<PixelDigiSimLink> > Phase2TrackerValidateDigi::otDigiSimLinkToken_
private

Definition at line 132 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ otDigiSrc_

edm::InputTag Phase2TrackerValidateDigi::otDigiSrc_
private

Definition at line 123 of file Phase2TrackerValidateDigi.h.

◆ otDigiToken_

const edm::EDGetTokenT<edm::DetSetVector<Phase2TrackerDigi> > Phase2TrackerValidateDigi::otDigiToken_
private

Definition at line 131 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ otSimLinkHandle_

edm::Handle<edm::DetSetVector<PixelDigiSimLink> > Phase2TrackerValidateDigi::otSimLinkHandle_
private

Definition at line 142 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), fillOTBXInfo(), and findOTDigi().

◆ pixelFlag_

bool Phase2TrackerValidateDigi::pixelFlag_
private

◆ pSimHitSrc_

std::vector<edm::InputTag> Phase2TrackerValidateDigi::pSimHitSrc_
private

Definition at line 127 of file Phase2TrackerValidateDigi.h.

Referenced by Phase2TrackerValidateDigi().

◆ ptCut_

float Phase2TrackerValidateDigi::ptCut_
private

Definition at line 98 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), fillSimHitInfo(), and Phase2TrackerValidateDigi().

◆ simHits

edm::Handle<edm::PSimHitContainer> Phase2TrackerValidateDigi::simHits
private

◆ simHitTokens_

std::vector<edm::EDGetTokenT<edm::PSimHitContainer> > Phase2TrackerValidateDigi::simHitTokens_
private

Definition at line 137 of file Phase2TrackerValidateDigi.h.

Referenced by fillSimHitInfo(), and Phase2TrackerValidateDigi().

◆ simTracks

edm::Handle<edm::SimTrackContainer> Phase2TrackerValidateDigi::simTracks
private

Definition at line 144 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ simTrackSrc_

edm::InputTag Phase2TrackerValidateDigi::simTrackSrc_
private

Definition at line 128 of file Phase2TrackerValidateDigi.h.

◆ simTrackToken_

const edm::EDGetTokenT<edm::SimTrackContainer> Phase2TrackerValidateDigi::simTrackToken_
private

Definition at line 135 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ SimulatedRZPositionMap

MonitorElement* Phase2TrackerValidateDigi::SimulatedRZPositionMap
private

Definition at line 86 of file Phase2TrackerValidateDigi.h.

Referenced by bookHistograms(), and fillSimHitInfo().

◆ SimulatedTOFEtaMap

MonitorElement* Phase2TrackerValidateDigi::SimulatedTOFEtaMap
private

Definition at line 91 of file Phase2TrackerValidateDigi.h.

Referenced by bookHistograms(), and fillSimHitInfo().

◆ SimulatedTOFPhiMap

MonitorElement* Phase2TrackerValidateDigi::SimulatedTOFPhiMap
private

Definition at line 92 of file Phase2TrackerValidateDigi.h.

Referenced by bookHistograms(), and fillSimHitInfo().

◆ SimulatedTOFRMap

MonitorElement* Phase2TrackerValidateDigi::SimulatedTOFRMap
private

Definition at line 93 of file Phase2TrackerValidateDigi.h.

Referenced by bookHistograms(), and fillSimHitInfo().

◆ SimulatedTOFZMap

MonitorElement* Phase2TrackerValidateDigi::SimulatedTOFZMap
private

Definition at line 94 of file Phase2TrackerValidateDigi.h.

Referenced by bookHistograms(), and fillSimHitInfo().

◆ SimulatedTrackEta

MonitorElement* Phase2TrackerValidateDigi::SimulatedTrackEta
private

Definition at line 74 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and bookHistograms().

◆ SimulatedTrackEtaP

MonitorElement* Phase2TrackerValidateDigi::SimulatedTrackEtaP
private

Definition at line 78 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and bookHistograms().

◆ SimulatedTrackEtaS

MonitorElement* Phase2TrackerValidateDigi::SimulatedTrackEtaS
private

Definition at line 82 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and bookHistograms().

◆ SimulatedTrackPhi

MonitorElement* Phase2TrackerValidateDigi::SimulatedTrackPhi
private

Definition at line 75 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and bookHistograms().

◆ SimulatedTrackPhiP

MonitorElement* Phase2TrackerValidateDigi::SimulatedTrackPhiP
private

Definition at line 79 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and bookHistograms().

◆ SimulatedTrackPhiS

MonitorElement* Phase2TrackerValidateDigi::SimulatedTrackPhiS
private

Definition at line 83 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and bookHistograms().

◆ SimulatedTrackPt

MonitorElement* Phase2TrackerValidateDigi::SimulatedTrackPt
private

Definition at line 73 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and bookHistograms().

◆ SimulatedTrackPtP

MonitorElement* Phase2TrackerValidateDigi::SimulatedTrackPtP
private

Definition at line 77 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and bookHistograms().

◆ SimulatedTrackPtS

MonitorElement* Phase2TrackerValidateDigi::SimulatedTrackPtS
private

Definition at line 81 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and bookHistograms().

◆ SimulatedXYPositionMap

MonitorElement* Phase2TrackerValidateDigi::SimulatedXYPositionMap
private

Definition at line 85 of file Phase2TrackerValidateDigi.h.

Referenced by bookHistograms(), and fillSimHitInfo().

◆ simVertexSrc_

edm::InputTag Phase2TrackerValidateDigi::simVertexSrc_
private

Definition at line 129 of file Phase2TrackerValidateDigi.h.

◆ simVertexToken_

const edm::EDGetTokenT<edm::SimVertexContainer> Phase2TrackerValidateDigi::simVertexToken_
private

Definition at line 136 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ simVertices

edm::Handle<edm::SimVertexContainer> Phase2TrackerValidateDigi::simVertices
private

Definition at line 145 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ tkGeom_

const TrackerGeometry* Phase2TrackerValidateDigi::tkGeom_ = nullptr
private

Definition at line 148 of file Phase2TrackerValidateDigi.h.

Referenced by bookHistograms(), dqmBeginRun(), and fillSimHitInfo().

◆ tofLowerCut_

float Phase2TrackerValidateDigi::tofLowerCut_
private

Definition at line 100 of file Phase2TrackerValidateDigi.h.

Referenced by fillSimHitInfo(), and Phase2TrackerValidateDigi().

◆ tofUpperCut_

float Phase2TrackerValidateDigi::tofUpperCut_
private

Definition at line 99 of file Phase2TrackerValidateDigi.h.

Referenced by fillSimHitInfo(), and Phase2TrackerValidateDigi().

◆ topoToken_

const edm::ESGetToken<TrackerTopology, TrackerTopologyRcd> Phase2TrackerValidateDigi::topoToken_
private

Definition at line 147 of file Phase2TrackerValidateDigi.h.

Referenced by dqmBeginRun().

◆ tTopo_

const TrackerTopology* Phase2TrackerValidateDigi::tTopo_ = nullptr
private
muonTagProbeFilters_cff.matched
matched
Definition: muonTagProbeFilters_cff.py:62
TrackerGeometry::idToDet
const TrackerGeomDet * idToDet(DetId) const override
Definition: TrackerGeometry.cc:193
edm::ESWatcher::check
bool check(const edm::EventSetup &iSetup)
Definition: ESWatcher.h:52
edm::ESHandle::product
T const * product() const
Definition: ESHandle.h:86
Phase2TrackerValidateDigi::GeVperElectron
const float GeVperElectron
Definition: Phase2TrackerValidateDigi.h:151
edm::DetSetVector
Definition: DetSetVector.h:61
CoreSimTrack::momentum
const math::XYZTLorentzVectorD & momentum() const
Definition: CoreSimTrack.h:19
Phase2TrackerValidateDigi::getSimTrackId
unsigned int getSimTrackId(const edm::DetSetVector< PixelDigiSimLink > *simLinks, const DetId &detId, unsigned int &channel)
Definition: Phase2TrackerValidateDigi.cc:906
Phase2TrackerValidateDigi::MatchedRZPositionMap
MonitorElement * MatchedRZPositionMap
Definition: Phase2TrackerValidateDigi.h:89
Phase2TrackerValidateDigi::getHistoId
std::string getHistoId(uint32_t det_id, bool flag)
Definition: Phase2TrackerValidateDigi.cc:1058
SimVertex
Definition: SimVertex.h:5
GeomDet
Definition: GeomDet.h:27
edm::Handle::product
T const * product() const
Definition: Handle.h:70
edm::ESWatcher< TrackerDigiGeometryRecord >
edm::DetSetVector::end
iterator end()
Return the off-the-end iterator.
Definition: DetSetVector.h:325
Phase2TrackerValidateDigi::matchedSimTrack
int matchedSimTrack(edm::Handle< edm::SimTrackContainer > &SimTk, unsigned int simTrkId)
Definition: Phase2TrackerValidateDigi.cc:1002
PV3DBase::x
T x() const
Definition: PV3DBase.h:59
edm::DetSet
Definition: DetSet.h:23
DiDispStaMuonMonitor_cfi.pt
pt
Definition: DiDispStaMuonMonitor_cfi.py:39
Phase2TrackerValidateDigi::SimulatedTrackPtP
MonitorElement * SimulatedTrackPtP
Definition: Phase2TrackerValidateDigi.h:77
TrackerTopology::getITPixelLayerNumber
int getITPixelLayerNumber(const DetId &id) const
Definition: TrackerTopology.cc:436
TrackerTopology::getOTLayerNumber
int getOTLayerNumber(const DetId &id) const
Definition: TrackerTopology.cc:421
Phase2TrackerValidateDigi::simHitTokens_
std::vector< edm::EDGetTokenT< edm::PSimHitContainer > > simHitTokens_
Definition: Phase2TrackerValidateDigi.h:137
cuy.col
col
Definition: cuy.py:1010
pos
Definition: PixelAliasList.h:18
l1GtPatternGenerator_cfi.bx
bx
Definition: l1GtPatternGenerator_cfi.py:18
TrackerGeomDet
Definition: TrackerGeomDet.h:6
dqm::implementation::NavigatorBase::setCurrentFolder
virtual void setCurrentFolder(std::string const &fullpath)
Definition: DQMStore.cc:32
OfflineHarvestingSequence_cosmic.ptype
ptype
Definition: OfflineHarvestingSequence_cosmic.py:7
Phase2TrackerValidateDigi::fillSimHitInfo
int fillSimHitInfo(const edm::Event &iEvent, const SimTrack simTrk)
Definition: Phase2TrackerValidateDigi.cc:195
Phase2TrackerValidateDigi::otDigiHandle_
edm::Handle< edm::DetSetVector< Phase2TrackerDigi > > otDigiHandle_
Definition: Phase2TrackerValidateDigi.h:140
edm::DetSetVector::begin
iterator begin()
Return an iterator to the first DetSet.
Definition: DetSetVector.h:314
Phase2TrackerValidateDigi::simVertexSrc_
edm::InputTag simVertexSrc_
Definition: Phase2TrackerValidateDigi.h:129
edm::LogInfo
Log< level::Info, false > LogInfo
Definition: MessageLogger.h:125
Phase2TrackerValidateDigi::tofLowerCut_
float tofLowerCut_
Definition: Phase2TrackerValidateDigi.h:100
findQualityFiles.v
v
Definition: findQualityFiles.py:179
BeamSpotPI::nTracks
Definition: BeamSpotPayloadInspectorHelper.h:42
edm::Handle< edm::PSimHitContainer >
Phase2TrackerValidateDigi::itPixelDigiHandle_
edm::Handle< edm::DetSetVector< PixelDigi > > itPixelDigiHandle_
Definition: Phase2TrackerValidateDigi.h:139
TrackerTopology::tidRing
unsigned int tidRing(const DetId &id) const
Definition: TrackerTopology.h:218
Phase2TrackerValidateDigi::cval
const float cval
Definition: Phase2TrackerValidateDigi.h:152
TrackerTopology::tidWheel
unsigned int tidWheel(const DetId &id) const
Definition: TrackerTopology.h:201
Phase2TrackerDigi::pixelToChannel
static PackedDigiType pixelToChannel(unsigned int row, unsigned int col)
Definition: Phase2TrackerDigi.h:43
Phase2TrackerValidateDigi::SimulatedTOFZMap
MonitorElement * SimulatedTOFZMap
Definition: Phase2TrackerValidateDigi.h:94
align::Tracker
Definition: StructureType.h:70
TrackerGeometry::idToDetUnit
const TrackerGeomDet * idToDetUnit(DetId) const override
Return the pointer to the GeomDetUnit corresponding to a given DetId.
Definition: TrackerGeometry.cc:183
PV3DBase::z
T z() const
Definition: PV3DBase.h:61
Phase2TrackerValidateDigi::geomType_
std::string geomType_
Definition: Phase2TrackerValidateDigi.h:121
Phase2TrackerValidateDigi::tkGeom_
const TrackerGeometry * tkGeom_
Definition: Phase2TrackerValidateDigi.h:148
DetId
Definition: DetId.h:17
GeomDet::surface
const Plane & surface() const
The nominal surface of the GeomDet.
Definition: GeomDet.h:37
Phase2TrackerValidateDigi::SimulatedTOFPhiMap
MonitorElement * SimulatedTOFPhiMap
Definition: Phase2TrackerValidateDigi.h:92
Phase2TrackerValidateDigi::findITPixelDigi
bool findITPixelDigi(unsigned int detid, unsigned int id)
Definition: Phase2TrackerValidateDigi.cc:348
Phase2TrackerValidateDigi::SimulatedTOFRMap
MonitorElement * SimulatedTOFRMap
Definition: Phase2TrackerValidateDigi.h:93
Phase2TrackerValidateDigi::simVertexToken_
const edm::EDGetTokenT< edm::SimVertexContainer > simVertexToken_
Definition: Phase2TrackerValidateDigi.h:136
TrackerGeometry::detUnits
const DetContainer & detUnits() const override
Returm a vector of all GeomDet.
Definition: TrackerGeometry.h:61
Phase2TrackerValidateDigi::topoToken_
const edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > topoToken_
Definition: Phase2TrackerValidateDigi.h:147
PVValHelper::eta
Definition: PVValidationHelpers.h:70
rpcPointValidation_cfi.simHit
simHit
Definition: rpcPointValidation_cfi.py:24
Phase2TrackerValidateDigi::otDigiSrc_
edm::InputTag otDigiSrc_
Definition: Phase2TrackerValidateDigi.h:123
Phase2TrackerValidateDigi::SimulatedTrackPhiP
MonitorElement * SimulatedTrackPhiP
Definition: Phase2TrackerValidateDigi.h:79
PixelGeomDetUnit
Definition: PixelGeomDetUnit.h:15
dqm::impl::MonitorElement::Fill
void Fill(long long x)
Definition: MonitorElement.h:290
Phase2TrackerValidateDigi::isPrimary
bool isPrimary(const SimTrack &simTrk, const PSimHit &simHit)
Definition: Phase2TrackerValidateDigi.cc:1014
Surface::toGlobal
GlobalPoint toGlobal(const Point2DBase< Scalar, LocalTag > lp) const
Definition: Surface.h:79
Phase2TrackerValidateDigi::layerMEs
std::map< std::string, DigiMEs > layerMEs
Definition: Phase2TrackerValidateDigi.h:118
edm::ESHandle< TrackerGeometry >
Phase2TrackerValidateDigi::nSimVertices
MonitorElement * nSimVertices
Definition: Phase2TrackerValidateDigi.h:71
dqm::implementation::NavigatorBase::cd
virtual void cd()
Definition: DQMStore.cc:29
Phase2TrackerValidateDigi::SimulatedTrackPtS
MonitorElement * SimulatedTrackPtS
Definition: Phase2TrackerValidateDigi.h:81
dqm::implementation::IBooker::bookProfile
MonitorElement * bookProfile(TString const &name, TString const &title, int nchX, double lowX, double highX, int, double lowY, double highY, char const *option="s", FUNC onbooking=NOOP())
Definition: DQMStore.h:322
Phase2TrackerValidateDigi::fillOTBXInfo
void fillOTBXInfo()
Definition: Phase2TrackerValidateDigi.cc:927
Phase2TrackerValidateDigi::simTrackToken_
const edm::EDGetTokenT< edm::SimTrackContainer > simTrackToken_
Definition: Phase2TrackerValidateDigi.h:135
PixelDigi::pixelToChannel
static int pixelToChannel(int row, int col)
Definition: PixelDigi.h:71
Point3DBase< float, GlobalTag >
Phase2TrackerValidateDigi::SimulatedRZPositionMap
MonitorElement * SimulatedRZPositionMap
Definition: Phase2TrackerValidateDigi.h:86
Phase2TrackerValidateDigi::nSimulatedTracks
MonitorElement * nSimulatedTracks
Definition: Phase2TrackerValidateDigi.h:67
Phase2TrackerValidateDigi::pixelFlag_
bool pixelFlag_
Definition: Phase2TrackerValidateDigi.h:120
phase1PixelTopology::layer
constexpr std::array< uint8_t, layerIndexSize > layer
Definition: phase1PixelTopology.h:99
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
Phase2TrackerValidateDigi::SimulatedTrackEtaP
MonitorElement * SimulatedTrackEtaP
Definition: Phase2TrackerValidateDigi.h:78
Phase2TrackerValidateDigi::MatchedXYPositionMap
MonitorElement * MatchedXYPositionMap
Definition: Phase2TrackerValidateDigi.h:88
funct::true
true
Definition: Factorize.h:173
Phase2TrackerValidateDigi::SimulatedTOFEtaMap
MonitorElement * SimulatedTOFEtaMap
Definition: Phase2TrackerValidateDigi.h:91
Phase2TrackerValidateDigi::fillITPixelBXInfo
void fillITPixelBXInfo()
Definition: Phase2TrackerValidateDigi.cc:963
Phase2TrackerValidateDigi::SimulatedTrackEta
MonitorElement * SimulatedTrackEta
Definition: Phase2TrackerValidateDigi.h:74
Phase2TrackerValidateDigi::otDigiToken_
const edm::EDGetTokenT< edm::DetSetVector< Phase2TrackerDigi > > otDigiToken_
Definition: Phase2TrackerValidateDigi.h:131
edm::ParameterSet
Definition: ParameterSet.h:47
Phase2TrackerValidateDigi::SimulatedTrackPhiS
MonitorElement * SimulatedTrackPhiS
Definition: Phase2TrackerValidateDigi.h:83
Phase2TrackerValidateDigi::SimulatedTrackEtaS
MonitorElement * SimulatedTrackEtaS
Definition: Phase2TrackerValidateDigi.h:82
edm::DetSetVector::const_iterator
collection_type::const_iterator const_iterator
Definition: DetSetVector.h:102
fed_dqm_sourceclient-live_cfg.folder_name
folder_name
Definition: fed_dqm_sourceclient-live_cfg.py:42
Phase2TrackerValidateDigi::otDigiSimLinkSrc_
edm::InputTag otDigiSimLinkSrc_
Definition: Phase2TrackerValidateDigi.h:124
PV3DBase::eta
T eta() const
Definition: PV3DBase.h:73
Phase2TrackerValidateDigi::simTrackSrc_
edm::InputTag simTrackSrc_
Definition: Phase2TrackerValidateDigi.h:128
PV3DBase::y
T y() const
Definition: PV3DBase.h:60
edm::DetSetVector::find
iterator find(det_id_type id)
Definition: DetSetVector.h:264
iEvent
int iEvent
Definition: GenABIO.cc:224
Phase2TrackerValidateDigi::itPixelDigiToken_
const edm::EDGetTokenT< edm::DetSetVector< PixelDigi > > itPixelDigiToken_
Definition: Phase2TrackerValidateDigi.h:133
Phase2TrackerValidateDigi::pSimHitSrc_
std::vector< edm::InputTag > pSimHitSrc_
Definition: Phase2TrackerValidateDigi.h:127
Phase2TrackerValidateDigi::itPixelDigiSimLinkToken_
const edm::EDGetTokenT< edm::DetSetVector< PixelDigiSimLink > > itPixelDigiSimLinkToken_
Definition: Phase2TrackerValidateDigi.h:134
cscdqm::HistoName
std::string HistoName
Definition: CSCDQM_HistoDef.h:32
edm::EventSetup::getHandle
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
Definition: EventSetup.h:155
Phase2TrackerValidateDigi::nSimulatedTracksP
MonitorElement * nSimulatedTracksP
Definition: Phase2TrackerValidateDigi.h:68
Phase2TrackerValidateDigi::otSimLinkHandle_
edm::Handle< edm::DetSetVector< PixelDigiSimLink > > otSimLinkHandle_
Definition: Phase2TrackerValidateDigi.h:142
Phase2TrackerValidateDigi::bookLayerHistos
void bookLayerHistos(DQMStore::IBooker &ibooker, unsigned int det_id, bool flag)
Definition: Phase2TrackerValidateDigi.cc:640
edm::ESHandleBase::isValid
bool isValid() const
Definition: ESHandle.h:44
Phase2TrackerValidateDigi::SimulatedTrackPhi
MonitorElement * SimulatedTrackPhi
Definition: Phase2TrackerValidateDigi.h:75
Phase2TrackerValidateDigi::nSimulatedTracksS
MonitorElement * nSimulatedTracksS
Definition: Phase2TrackerValidateDigi.h:69
CoreSimTrack::trackId
unsigned int trackId() const
Definition: CoreSimTrack.h:31
DDAxes::phi
PV3DBase::mag
T mag() const
Definition: PV3DBase.h:64
Phase2TrackerValidateDigi::ptCut_
float ptCut_
Definition: Phase2TrackerValidateDigi.h:98
Phase2TrackerValidateDigi::tTopo_
const TrackerTopology * tTopo_
Definition: Phase2TrackerValidateDigi.h:149
Phase2TrackerValidateDigi::simVertices
edm::Handle< edm::SimVertexContainer > simVertices
Definition: Phase2TrackerValidateDigi.h:145
heppy_batch.val
val
Definition: heppy_batch.py:351
phase2tkutil::getITHistoId
std::string getITHistoId(uint32_t det_id, const TrackerTopology *tTopo)
Definition: TrackerPhase2DQMUtil.cc:2
flag_
struct @697 flag_
Phase2TrackerValidateDigi::simHits
edm::Handle< edm::PSimHitContainer > simHits
Definition: Phase2TrackerValidateDigi.h:143
extraflags_cff.vtx
vtx
Definition: extraflags_cff.py:18
edm::SimTrackContainer
std::vector< SimTrack > SimTrackContainer
Definition: SimTrackContainer.h:12
triggerObjects_cff.id
id
Definition: triggerObjects_cff.py:29
dqm::implementation::IBooker::book2D
MonitorElement * book2D(TString const &name, TString const &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, FUNC onbooking=NOOP())
Definition: DQMStore.h:177
electronStore.links
links
Definition: electronStore.py:149
Phase2TrackerValidateDigi::itPixelSimLinkHandle_
edm::Handle< edm::DetSetVector< PixelDigiSimLink > > itPixelSimLinkHandle_
Definition: Phase2TrackerValidateDigi.h:141
edm::DetSet::data
collection_type data
Definition: DetSet.h:80
SimTrack::vertIndex
int vertIndex() const
index of the vertex in the Event container (-1 if no vertex)
Definition: SimTrack.h:33
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
Phase2TrackerValidateDigi::fillHistogram
void fillHistogram(MonitorElement *th1, MonitorElement *th2, MonitorElement *th3, float val, int primary)
Definition: Phase2TrackerValidateDigi.cc:1028
Phase2TrackerValidateDigi::itPixelDigiSimLinkSrc_
edm::InputTag itPixelDigiSimLinkSrc_
Definition: Phase2TrackerValidateDigi.h:126
Phase2TrackerValidateDigi::etaCut_
float etaCut_
Definition: Phase2TrackerValidateDigi.h:97
edm::PSimHitContainer
std::vector< PSimHit > PSimHitContainer
Definition: PSimHitContainer.h:11
Phase2TrackerValidateDigi::SimulatedTrackPt
MonitorElement * SimulatedTrackPt
Definition: Phase2TrackerValidateDigi.h:73
Phase2TrackerValidateDigi::config_
edm::ParameterSet config_
Definition: Phase2TrackerValidateDigi.h:117
PSimHit
Definition: PSimHit.h:15
Phase2TrackerValidateDigi::SimulatedXYPositionMap
MonitorElement * SimulatedXYPositionMap
Definition: Phase2TrackerValidateDigi.h:85
edm::HandleBase::isValid
bool isValid() const
Definition: HandleBase.h:70
Parameters
vector< ParameterSet > Parameters
Definition: HLTMuonPlotter.cc:25
Phase2TrackerValidateDigi::otDigiSimLinkToken_
const edm::EDGetTokenT< edm::DetSetVector< PixelDigiSimLink > > otDigiSimLinkToken_
Definition: Phase2TrackerValidateDigi.h:132
crabWrapper.key
key
Definition: crabWrapper.py:19
Phase2TrackerValidateDigi::findOTDigi
bool findOTDigi(unsigned int detid, unsigned int id)
Definition: Phase2TrackerValidateDigi.cc:329
Phase2TrackerValidateDigi::itPixelDigiSrc_
edm::InputTag itPixelDigiSrc_
Definition: Phase2TrackerValidateDigi.h:125
edm::InputTag
Definition: InputTag.h:15
PV3DBase::phi
Geom::Phi< T > phi() const
Definition: PV3DBase.h:66
Phase2TrackerValidateDigi::simTracks
edm::Handle< edm::SimTrackContainer > simTracks
Definition: Phase2TrackerValidateDigi.h:144
Phase2TrackerValidateDigi::geomToken_
const edm::ESGetToken< TrackerGeometry, TrackerDigiGeometryRecord > geomToken_
Definition: Phase2TrackerValidateDigi.h:146
phase2tkutil::getOTHistoId
std::string getOTHistoId(uint32_t det_id, const TrackerTopology *tTopo)
Definition: TrackerPhase2DQMUtil.cc:25
dqm::implementation::IBooker::book1D
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
Definition: DQMStore.h:98
RemoveAddSevLevel.flag
flag
Definition: RemoveAddSevLevel.py:116
Phase2TrackerValidateDigi::tofUpperCut_
float tofUpperCut_
Definition: Phase2TrackerValidateDigi.h:99
edm::DetSet::const_iterator
collection_type::const_iterator const_iterator
Definition: DetSet.h:31