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
 
 EDProducer (const EDProducer &)=delete
 
bool hasAbilityToProduceInBeginLumis () const final
 
bool hasAbilityToProduceInBeginProcessBlocks () const final
 
bool hasAbilityToProduceInBeginRuns () const final
 
bool hasAbilityToProduceInEndLumis () const final
 
bool hasAbilityToProduceInEndProcessBlocks () const final
 
bool hasAbilityToProduceInEndRuns () const final
 
const EDProduceroperator= (const EDProducer &)=delete
 

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
 
const edm::DetSetVector< PixelDigi > * itdigis_
 
edm::InputTag itPixelDigiSimLinkSrc_
 
const edm::EDGetTokenT< edm::DetSetVector< PixelDigiSimLink > > itPixelDigiSimLinkToken_
 
edm::InputTag itPixelDigiSrc_
 
const edm::EDGetTokenT< edm::DetSetVector< PixelDigi > > itPixelDigiToken_
 
const edm::DetSetVector< PixelDigiSimLink > * itSimLink_
 
std::map< std::string, DigiMEslayerMEs
 
MonitorElementMatchedRZPositionMap
 
MonitorElementMatchedXYPositionMap
 
MonitorElementnSimHitsPerTrack
 
MonitorElementnSimulatedTracks
 
MonitorElementnSimulatedTracksP
 
MonitorElementnSimulatedTracksS
 
MonitorElementnSimVertices
 
const edm::DetSetVector< Phase2TrackerDigi > * otdigis_
 
edm::InputTag otDigiSimLinkSrc_
 
const edm::EDGetTokenT< edm::DetSetVector< PixelDigiSimLink > > otDigiSimLinkToken_
 
edm::InputTag otDigiSrc_
 
const edm::EDGetTokenT< edm::DetSetVector< Phase2TrackerDigi > > otDigiToken_
 
const edm::DetSetVector< PixelDigiSimLink > * otSimLink_
 
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 >
using CacheTypes = CacheContexts< T... >
 
using GlobalCache = typename CacheTypes::GlobalCache
 
using HasAbility = AbilityChecker< T... >
 
using InputProcessBlockCache = typename CacheTypes::InputProcessBlockCache
 
using LuminosityBlockCache = typename CacheTypes::LuminosityBlockCache
 
using LuminosityBlockContext = LuminosityBlockContextT< LuminosityBlockCache, RunCache, GlobalCache >
 
using LuminosityBlockSummaryCache = typename CacheTypes::LuminosityBlockSummaryCache
 
using RunCache = typename CacheTypes::RunCache
 
using RunContext = RunContextT< RunCache, GlobalCache >
 
using RunSummaryCache = typename CacheTypes::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 107 of file Phase2TrackerValidateDigi.cc.

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

References etaCut_, dqm::impl::MonitorElement::Fill(), fillHistogram(), fillITPixelBXInfo(), fillOTBXInfo(), fillSimHitInfo(), iEvent, itdigis_, itPixelDigiSimLinkToken_, itPixelDigiToken_, itSimLink_, layerMEs, matchedSimTrack(), Phase2TrackerValidateDigi::DigiMEs::MissedHitTrackEta, Phase2TrackerValidateDigi::DigiMEs::MissedHitTrackPhi, Phase2TrackerValidateDigi::DigiMEs::MissedHitTrackPt, nSimulatedTracks, nSimulatedTracksP, nSimulatedTracksS, nSimVertices, BeamSpotPI::nTracks, otdigis_, otDigiSimLinkToken_, otDigiToken_, otSimLink_, 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 363 of file Phase2TrackerValidateDigi.cc.

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

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 632 of file Phase2TrackerValidateDigi.cc.

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

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 
102  tTopo_ = &iSetup.getData(topoToken_);
103 }

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

◆ fillHistogram()

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

Definition at line 1020 of file Phase2TrackerValidateDigi.cc.

1021  {
1022  if (th1)
1023  th1->Fill(val);
1024  if (th2 && primary == 1)
1025  th2->Fill(val);
1026  if (th3 && primary != 1)
1027  th3->Fill(val);
1028 }

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 955 of file Phase2TrackerValidateDigi.cc.

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

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

Referenced by analyze().

◆ fillOTBXInfo()

void Phase2TrackerValidateDigi::fillOTBXInfo ( )
private

Definition at line 919 of file Phase2TrackerValidateDigi.cc.

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

References edm::DetSetVector< T >::begin(), Phase2TrackerValidateDigi::DigiMEs::BunchXTimeBin, l1GtPatternGenerator_cfi::bx, edm::DetSetVector< T >::end(), dqm::impl::MonitorElement::Fill(), flag_, Phase2TrackerValidateDigi::DigiMEs::FractionOfOOTDigis, getHistoId(), TrackerTopology::getOTLayerNumber(), crabWrapper::key, phase1PixelTopology::layer, layerMEs, otSimLink_, 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 192 of file Phase2TrackerValidateDigi.cc.

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

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(), 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_, 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 343 of file Phase2TrackerValidateDigi.cc.

343  {
344  bool matched = false;
346  if (DSVIter != itdigis_->end()) {
347  for (edm::DetSet<PixelDigi>::const_iterator di = DSVIter->begin(); di != DSVIter->end(); di++) {
348  int col = di->column(); // column
349  int row = di->row(); // row
350  unsigned int channel = PixelDigi::pixelToChannel(row, col);
351  unsigned int simTkId = getSimTrackId(itSimLink_, detid, channel);
352  if (simTkId == id) {
353  matched = true;
354  break;
355  }
356  }
357  }
358  return matched;
359 }

References edm::DetSetVector< T >::begin(), cuy::col, edm::DetSetVector< T >::end(), edm::DetSetVector< T >::find(), getSimTrackId(), itdigis_, itSimLink_, muonTagProbeFilters_cff::matched, and PixelDigi::pixelToChannel().

Referenced by fillSimHitInfo().

◆ findOTDigi()

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

Definition at line 326 of file Phase2TrackerValidateDigi.cc.

326  {
327  bool matched = false;
329  if (DSVIter != otdigis_->end()) {
330  for (edm::DetSet<Phase2TrackerDigi>::const_iterator di = DSVIter->begin(); di != DSVIter->end(); di++) {
331  int col = di->column(); // column
332  int row = di->row(); // row
333  unsigned int channel = Phase2TrackerDigi::pixelToChannel(row, col);
334  unsigned int simTkId = getSimTrackId(otSimLink_, detid, channel);
335  if (simTkId == id) {
336  matched = true;
337  break;
338  }
339  }
340  }
341  return matched;
342 }

References edm::DetSetVector< T >::begin(), cuy::col, edm::DetSetVector< T >::end(), edm::DetSetVector< T >::find(), getSimTrackId(), muonTagProbeFilters_cff::matched, otdigis_, otSimLink_, and Phase2TrackerDigi::pixelToChannel().

Referenced by fillSimHitInfo().

◆ getHistoId()

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

Definition at line 1050 of file Phase2TrackerValidateDigi.cc.

1050  {
1051  if (flag)
1052  return phase2tkutil::getITHistoId(det_id, tTopo_);
1053  else
1054  return phase2tkutil::getOTHistoId(det_id, tTopo_);
1055 }

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 898 of file Phase2TrackerValidateDigi.cc.

900  {
902 
903  unsigned int simTrkId(0);
904  if (isearch == simLinks->end())
905  return simTrkId;
906 
907  edm::DetSet<PixelDigiSimLink> link_detset = (*simLinks)[detId];
908  // Loop over DigiSimLink in this det unit
909  int iSimLink = 0;
910  for (edm::DetSet<PixelDigiSimLink>::const_iterator it = link_detset.data.begin(); it != link_detset.data.end();
911  it++, iSimLink++) {
912  if (channel == it->channel()) {
913  simTrkId = it->SimTrackId();
914  break;
915  }
916  }
917  return simTrkId;
918 }

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 1006 of file Phase2TrackerValidateDigi.cc.

1006  {
1007  bool retval = false;
1008  unsigned int trkId = simTrk.trackId();
1009  if (trkId != simHit.trackId())
1010  return retval;
1011  int vtxIndex = simTrk.vertIndex();
1012  int ptype = simHit.processType();
1013  if ((vtxIndex == 0) && (ptype == 0))
1014  retval = true;
1015  return retval;
1016 }

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 994 of file Phase2TrackerValidateDigi.cc.

994  {
995  edm::SimTrackContainer sim_tracks = (*SimTk.product());
996  for (unsigned int it = 0; it < sim_tracks.size(); it++) {
997  if (sim_tracks[it].trackId() == simTrkId) {
998  return it;
999  }
1000  }
1001  return -1;
1002 }

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 153 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 147 of file Phase2TrackerValidateDigi.h.

Referenced by dqmBeginRun().

◆ geomType_

std::string Phase2TrackerValidateDigi::geomType_
private

Definition at line 123 of file Phase2TrackerValidateDigi.h.

◆ GeVperElectron

const float Phase2TrackerValidateDigi::GeVperElectron
private

Definition at line 152 of file Phase2TrackerValidateDigi.h.

Referenced by fillSimHitInfo().

◆ itdigis_

const edm::DetSetVector<PixelDigi>* Phase2TrackerValidateDigi::itdigis_
private

Definition at line 142 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and findITPixelDigi().

◆ itPixelDigiSimLinkSrc_

edm::InputTag Phase2TrackerValidateDigi::itPixelDigiSimLinkSrc_
private

Definition at line 128 of file Phase2TrackerValidateDigi.h.

◆ itPixelDigiSimLinkToken_

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

Definition at line 136 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ itPixelDigiSrc_

edm::InputTag Phase2TrackerValidateDigi::itPixelDigiSrc_
private

Definition at line 127 of file Phase2TrackerValidateDigi.h.

◆ itPixelDigiToken_

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

Definition at line 135 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ itSimLink_

const edm::DetSetVector<PixelDigiSimLink>* Phase2TrackerValidateDigi::itSimLink_
private

Definition at line 140 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().

◆ otdigis_

const edm::DetSetVector<Phase2TrackerDigi>* Phase2TrackerValidateDigi::otdigis_
private

Definition at line 141 of file Phase2TrackerValidateDigi.h.

Referenced by analyze(), and findOTDigi().

◆ otDigiSimLinkSrc_

edm::InputTag Phase2TrackerValidateDigi::otDigiSimLinkSrc_
private

Definition at line 126 of file Phase2TrackerValidateDigi.h.

◆ otDigiSimLinkToken_

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

Definition at line 134 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ otDigiSrc_

edm::InputTag Phase2TrackerValidateDigi::otDigiSrc_
private

Definition at line 125 of file Phase2TrackerValidateDigi.h.

◆ otDigiToken_

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

Definition at line 133 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ otSimLink_

const edm::DetSetVector<PixelDigiSimLink>* Phase2TrackerValidateDigi::otSimLink_
private

Definition at line 139 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 129 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 143 of file Phase2TrackerValidateDigi.h.

Referenced by fillSimHitInfo(), and Phase2TrackerValidateDigi().

◆ simTracks

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

Definition at line 145 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ simTrackSrc_

edm::InputTag Phase2TrackerValidateDigi::simTrackSrc_
private

Definition at line 130 of file Phase2TrackerValidateDigi.h.

◆ simTrackToken_

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

Definition at line 137 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 131 of file Phase2TrackerValidateDigi.h.

◆ simVertexToken_

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

Definition at line 138 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ simVertices

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

Definition at line 146 of file Phase2TrackerValidateDigi.h.

Referenced by analyze().

◆ tkGeom_

const TrackerGeometry* Phase2TrackerValidateDigi::tkGeom_ = nullptr
private

Definition at line 149 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 148 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:57
Phase2TrackerValidateDigi::GeVperElectron
const float GeVperElectron
Definition: Phase2TrackerValidateDigi.h:152
edm::DetSetVector< Phase2TrackerDigi >
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:898
Phase2TrackerValidateDigi::MatchedRZPositionMap
MonitorElement * MatchedRZPositionMap
Definition: Phase2TrackerValidateDigi.h:89
Phase2TrackerValidateDigi::getHistoId
std::string getHistoId(uint32_t det_id, bool flag)
Definition: Phase2TrackerValidateDigi.cc:1050
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:994
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:143
cuy.col
col
Definition: cuy.py:1009
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:192
edm::DetSetVector::begin
iterator begin()
Return an iterator to the first DetSet.
Definition: DetSetVector.h:314
Phase2TrackerValidateDigi::simVertexSrc_
edm::InputTag simVertexSrc_
Definition: Phase2TrackerValidateDigi.h:131
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
TrackerTopology::tidRing
unsigned int tidRing(const DetId &id) const
Definition: TrackerTopology.h:218
Phase2TrackerValidateDigi::cval
const float cval
Definition: Phase2TrackerValidateDigi.h:153
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:123
Phase2TrackerValidateDigi::tkGeom_
const TrackerGeometry * tkGeom_
Definition: Phase2TrackerValidateDigi.h:149
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:343
Phase2TrackerValidateDigi::SimulatedTOFRMap
MonitorElement * SimulatedTOFRMap
Definition: Phase2TrackerValidateDigi.h:93
Phase2TrackerValidateDigi::simVertexToken_
const edm::EDGetTokenT< edm::SimVertexContainer > simVertexToken_
Definition: Phase2TrackerValidateDigi.h:138
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:148
PVValHelper::eta
Definition: PVValidationHelpers.h:70
rpcPointValidation_cfi.simHit
simHit
Definition: rpcPointValidation_cfi.py:24
Phase2TrackerValidateDigi::otDigiSrc_
edm::InputTag otDigiSrc_
Definition: Phase2TrackerValidateDigi.h:125
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:1006
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:120
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:919
Phase2TrackerValidateDigi::simTrackToken_
const edm::EDGetTokenT< edm::SimTrackContainer > simTrackToken_
Definition: Phase2TrackerValidateDigi.h:137
PixelDigi::pixelToChannel
static int pixelToChannel(int row, int col)
Definition: PixelDigi.h:75
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:122
Phase2TrackerValidateDigi::itSimLink_
const edm::DetSetVector< PixelDigiSimLink > * itSimLink_
Definition: Phase2TrackerValidateDigi.h:140
phase1PixelTopology::layer
constexpr std::array< uint8_t, layerIndexSize > layer
Definition: phase1PixelTopology.h:99
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:955
Phase2TrackerValidateDigi::SimulatedTrackEta
MonitorElement * SimulatedTrackEta
Definition: Phase2TrackerValidateDigi.h:74
Phase2TrackerValidateDigi::otDigiToken_
const edm::EDGetTokenT< edm::DetSetVector< Phase2TrackerDigi > > otDigiToken_
Definition: Phase2TrackerValidateDigi.h:133
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:126
PV3DBase::eta
T eta() const
Definition: PV3DBase.h:73
Phase2TrackerValidateDigi::simTrackSrc_
edm::InputTag simTrackSrc_
Definition: Phase2TrackerValidateDigi.h:130
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:135
Phase2TrackerValidateDigi::pSimHitSrc_
std::vector< edm::InputTag > pSimHitSrc_
Definition: Phase2TrackerValidateDigi.h:129
Phase2TrackerValidateDigi::itPixelDigiSimLinkToken_
const edm::EDGetTokenT< edm::DetSetVector< PixelDigiSimLink > > itPixelDigiSimLinkToken_
Definition: Phase2TrackerValidateDigi.h:136
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::bookLayerHistos
void bookLayerHistos(DQMStore::IBooker &ibooker, unsigned int det_id, bool flag)
Definition: Phase2TrackerValidateDigi.cc:632
edm::ESHandleBase::isValid
bool isValid() const
Definition: ESHandle.h:44
Phase2TrackerValidateDigi::SimulatedTrackPhi
MonitorElement * SimulatedTrackPhi
Definition: Phase2TrackerValidateDigi.h:75
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
Phase2TrackerValidateDigi::nSimulatedTracksS
MonitorElement * nSimulatedTracksS
Definition: Phase2TrackerValidateDigi.h:69
edm::EventSetup::getData
bool getData(T &iHolder) const
Definition: EventSetup.h:127
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:150
Phase2TrackerValidateDigi::itdigis_
const edm::DetSetVector< PixelDigi > * itdigis_
Definition: Phase2TrackerValidateDigi.h:142
Phase2TrackerValidateDigi::simVertices
edm::Handle< edm::SimVertexContainer > simVertices
Definition: Phase2TrackerValidateDigi.h:146
heppy_batch.val
val
Definition: heppy_batch.py:351
Phase2TrackerValidateDigi::otdigis_
const edm::DetSetVector< Phase2TrackerDigi > * otdigis_
Definition: Phase2TrackerValidateDigi.h:141
Phase2TrackerValidateDigi::otSimLink_
const edm::DetSetVector< PixelDigiSimLink > * otSimLink_
Definition: Phase2TrackerValidateDigi.h:139
phase2tkutil::getITHistoId
std::string getITHistoId(uint32_t det_id, const TrackerTopology *tTopo)
Definition: TrackerPhase2DQMUtil.cc:2
Phase2TrackerValidateDigi::simHits
edm::Handle< edm::PSimHitContainer > simHits
Definition: Phase2TrackerValidateDigi.h:144
extraflags_cff.vtx
vtx
Definition: extraflags_cff.py:19
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
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:1020
Phase2TrackerValidateDigi::itPixelDigiSimLinkSrc_
edm::InputTag itPixelDigiSimLinkSrc_
Definition: Phase2TrackerValidateDigi.h:128
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:119
PSimHit
Definition: PSimHit.h:15
Phase2TrackerValidateDigi::SimulatedXYPositionMap
MonitorElement * SimulatedXYPositionMap
Definition: Phase2TrackerValidateDigi.h:85
Parameters
vector< ParameterSet > Parameters
Definition: HLTMuonPlotter.cc:25
Phase2TrackerValidateDigi::otDigiSimLinkToken_
const edm::EDGetTokenT< edm::DetSetVector< PixelDigiSimLink > > otDigiSimLinkToken_
Definition: Phase2TrackerValidateDigi.h:134
crabWrapper.key
key
Definition: crabWrapper.py:19
Phase2TrackerValidateDigi::findOTDigi
bool findOTDigi(unsigned int detid, unsigned int id)
Definition: Phase2TrackerValidateDigi.cc:326
Phase2TrackerValidateDigi::itPixelDigiSrc_
edm::InputTag itPixelDigiSrc_
Definition: Phase2TrackerValidateDigi.h:127
edm::InputTag
Definition: InputTag.h:15
flag_
struct @715 flag_
PV3DBase::phi
Geom::Phi< T > phi() const
Definition: PV3DBase.h:66
Phase2TrackerValidateDigi::simTracks
edm::Handle< edm::SimTrackContainer > simTracks
Definition: Phase2TrackerValidateDigi.h:145
Phase2TrackerValidateDigi::geomToken_
const edm::ESGetToken< TrackerGeometry, TrackerDigiGeometryRecord > geomToken_
Definition: Phase2TrackerValidateDigi.h:147
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:117
Phase2TrackerValidateDigi::tofUpperCut_
float tofUpperCut_
Definition: Phase2TrackerValidateDigi.h:99
edm::DetSet::const_iterator
collection_type::const_iterator const_iterator
Definition: DetSet.h:31