CMS 3D CMS Logo

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
List of all members | Public Member Functions | Private Member Functions | Private Attributes
DTRecHitQuality Class Reference

#include <DTRecHitQuality.h>

Inheritance diagram for DTRecHitQuality:
DQMGlobalEDAnalyzer< dtrechit::Histograms > DQMGlobalEDAnalyzerBase< dtrechit::Histograms, Args... > edm::global::EDProducer< edm::RunCache< dtrechit::Histograms >, edm::EndRunProducer, edm::Accumulator, Args... > edm::global::EDProducerBase edm::ProducerBase edm::EDConsumerBase edm::ProductRegistryHelper

Public Member Functions

 DTRecHitQuality (const edm::ParameterSet &pset)
 Constructor. More...
 
- Public Member Functions inherited from DQMGlobalEDAnalyzer< dtrechit::Histograms >
virtual void dqmEndRun (edm::Run const &, edm::EventSetup const &, dtrechit::Histograms const &) const
 
void globalEndRunProduce (edm::Run &run, edm::EventSetup const &setup) const final
 
- Public Member Functions inherited from DQMGlobalEDAnalyzerBase< dtrechit::Histograms, Args... >
void accumulate (edm::StreamID id, edm::Event const &event, edm::EventSetup const &setup) const final
 
virtual void dqmBeginRun (edm::Run const &, edm::EventSetup const &, dtrechit::Histograms &) const
 
 DQMGlobalEDAnalyzerBase ()
 
std::shared_ptr< dtrechit::HistogramsglobalBeginRun (edm::Run const &run, edm::EventSetup const &setup) const final
 
void globalEndRun (edm::Run const &, edm::EventSetup const &) const final
 
- Public Member Functions inherited from edm::global::EDProducer< edm::RunCache< dtrechit::Histograms >, edm::EndRunProducer, edm::Accumulator, Args... >
 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
 
EDProduceroperator= (const EDProducer &)=delete
 
bool wantsGlobalLuminosityBlocks () const final
 
bool wantsGlobalRuns () const final
 
bool wantsInputProcessBlocks () const final
 
bool wantsProcessBlocks () const final
 
bool wantsStreamLuminosityBlocks () const final
 
bool wantsStreamRuns () const final
 
- Public Member Functions inherited from edm::global::EDProducerBase
 EDProducerBase ()
 
ModuleDescription const & moduleDescription () const
 
 ~EDProducerBase () override
 
- Public Member Functions inherited from edm::ProducerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
std::vector< edm::ProductResolverIndex > const & indiciesForPutProducts (BranchType iBranchType) const
 
 ProducerBase ()
 
std::vector< edm::ProductResolverIndex > const & putTokenIndexToProductResolverIndex () const
 
std::vector< bool > const & recordProvenanceList () const
 
void registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &)
 
std::function< void(BranchDescription const &)> registrationCallback () const
 used by the fwk to register list of products More...
 
void resolvePutIndicies (BranchType iBranchType, ModuleToResolverIndicies const &iIndicies, std::string const &moduleLabel)
 
TypeLabelList const & typeLabelList () const
 used by the fwk to register the list of products of this module More...
 
 ~ProducerBase () noexcept(false) override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase &&)=default
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
ESProxyIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESProxyIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex > const & esGetTokenRecordIndicesVector (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector< ProductResolverIndexAndSkipBit > const & itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Private Member Functions

void bookHistograms (DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &, dtrechit::Histograms &) const override
 Book the DQM plots. More...
 
template<typename type >
void compute (const DTGeometry *dtGeom, const std::map< DTWireId, std::vector< PSimHit >> &simHitsPerWire, const std::map< DTWireId, std::vector< type >> &recHitsPerWire, dtrechit::Histograms const &histograms, int step) const
 
void dqmAnalyze (edm::Event const &, edm::EventSetup const &, dtrechit::Histograms const &) const override
 Perform the real analysis. More...
 
template<typename type >
const typefindBestRecHit (const DTLayer *layer, const DTWireId &wireId, const std::vector< type > &recHits, float simHitDist) const
 
std::map< DTWireId, std::vector< DTRecHit1DPair > > map1DRecHitsPerWire (const DTRecHitCollection *dt1DRecHitPairs) const
 
std::map< DTWireId, std::vector< DTRecHit1D > > map1DRecHitsPerWire (const DTRecSegment2DCollection *segment2Ds) const
 
std::map< DTWireId, std::vector< DTRecHit1D > > map1DRecHitsPerWire (const DTRecSegment4DCollection *segment4Ds) const
 
float recHitDistFromWire (const DTRecHit1D &recHit, const DTLayer *layer) const
 
float recHitDistFromWire (const DTRecHit1DPair &hitPair, const DTLayer *layer) const
 
float recHitPositionError (const DTRecHit1D &recHit) const
 
float recHitPositionError (const DTRecHit1DPair &recHit) const
 
float simHitDistFromFE (const DTLayer *layer, const DTWireId &wireId, const PSimHit &hit) const
 
float simHitDistFromWire (const DTLayer *layer, const DTWireId &wireId, const PSimHit &hit) const
 
float simHitImpactAngle (const DTLayer *layer, const DTWireId &wireId, const PSimHit &hit) const
 

Private Attributes

bool debug_
 
bool doall_
 
bool doStep1_
 
bool doStep2_
 
bool doStep3_
 
bool local_
 
edm::InputTag recHitLabel_
 
edm::EDGetTokenT< DTRecHitCollectionrecHitToken_
 
edm::InputTag segment2DLabel_
 
edm::EDGetTokenT< DTRecSegment2DCollectionsegment2DToken_
 
edm::InputTag segment4DLabel_
 
edm::EDGetTokenT< DTRecSegment4DCollectionsegment4DToken_
 
edm::InputTag simHitLabel_
 
edm::EDGetTokenT< edm::PSimHitContainersimHitToken_
 

Additional Inherited Members

- Public Types inherited from DQMGlobalEDAnalyzerBase< dtrechit::Histograms, Args... >
typedef dqm::reco::DQMStore DQMStore
 
typedef dqm::reco::MonitorElement MonitorElement
 
- Public Types inherited from edm::global::EDProducerBase
typedef EDProducerBase ModuleType
 
- Public Types inherited from edm::ProducerBase
using ModuleToResolverIndicies = std::unordered_multimap< std::string, std::tuple< edm::TypeID const *, const char *, edm::ProductResolverIndex > >
 
typedef ProductRegistryHelper::TypeLabelList TypeLabelList
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::global::EDProducerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 
- Protected Member Functions inherited from DQMGlobalEDAnalyzerBase< dtrechit::Histograms, Args... >
uint64_t meId (edm::Run const &run) const
 
- Protected Member Functions inherited from edm::ProducerBase
template<class ProductType >
BranchAliasSetterT< ProductType > produces ()
 declare what type of product will make and with which optional label More...
 
template<typename ProductType , BranchType B>
BranchAliasSetterT< ProductType > produces ()
 
template<typename ProductType , Transition B>
BranchAliasSetterT< ProductType > produces ()
 
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
template<BranchType B>
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
template<Transition B>
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
template<typename ProductType , Transition B>
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
template<class ProductType >
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
template<typename ProductType , BranchType B>
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
ProducesCollector producesCollector ()
 
- Protected Member Functions inherited from edm::EDConsumerBase
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B = InEvent>
EDConsumerBaseAdaptor< B > consumes (edm::InputTag tag) noexcept
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<Transition Tr = Transition::Event>
constexpr auto esConsumes () noexcept
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag) noexcept
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
- Protected Attributes inherited from DQMGlobalEDAnalyzerBase< dtrechit::Histograms, Args... >
DQMStoredqmstore_
 
edm::EDPutTokenT< DQMTokenrunToken_
 

Detailed Description

Basic analyzer class which accesses 1D DTRecHits and plot resolution comparing reconstructed and simulated quantities

Residual/pull plots are filled for the rechit with distance from wire closer to that of the muon simhit.

Efficiencies are defined as the fraction of muon simhits with a rechit in the same cell, for the given reconstruction step. Hence, for S2 and S3 the definition incorporate the segment reconstruction efficiency.

Author
G. Cerminara - INFN Torino

Definition at line 46 of file DTRecHitQuality.h.

Constructor & Destructor Documentation

◆ DTRecHitQuality()

DTRecHitQuality::DTRecHitQuality ( const edm::ParameterSet pset)

Constructor.

Definition at line 88 of file DTRecHitQuality.cc.

88  {
89  // Get the debug parameter for verbose output
90  debug_ = pset.getUntrackedParameter<bool>("debug");
91  // the name of the simhit collection
92  simHitLabel_ = pset.getUntrackedParameter<InputTag>("simHitLabel");
93  simHitToken_ = consumes<PSimHitContainer>(pset.getUntrackedParameter<InputTag>("simHitLabel"));
94  // the name of the 1D rec hit collection
95  recHitLabel_ = pset.getUntrackedParameter<InputTag>("recHitLabel");
96  recHitToken_ = consumes<DTRecHitCollection>(pset.getUntrackedParameter<InputTag>("recHitLabel"));
97  // the name of the 2D rec hit collection
98  segment2DLabel_ = pset.getUntrackedParameter<InputTag>("segment2DLabel");
99  segment2DToken_ = consumes<DTRecSegment2DCollection>(pset.getUntrackedParameter<InputTag>("segment2DLabel"));
100  // the name of the 4D rec hit collection
101  segment4DLabel_ = pset.getUntrackedParameter<InputTag>("segment4DLabel");
102  segment4DToken_ = consumes<DTRecSegment4DCollection>(pset.getUntrackedParameter<InputTag>("segment4DLabel"));
103  // Switches for analysis at various steps
104  doStep1_ = pset.getUntrackedParameter<bool>("doStep1", false);
105  doStep2_ = pset.getUntrackedParameter<bool>("doStep2", false);
106  doStep3_ = pset.getUntrackedParameter<bool>("doStep3", false);
107  doall_ = pset.getUntrackedParameter<bool>("doall", false);
108  local_ = pset.getUntrackedParameter<bool>("local", true);
109 }

References muonDTDigis_cfi::pset.

Member Function Documentation

◆ bookHistograms()

void DTRecHitQuality::bookHistograms ( DQMStore::IBooker booker,
edm::Run const &  run,
edm::EventSetup const &  setup,
dtrechit::Histograms histograms 
) const
overrideprivatevirtual

Book the DQM plots.

Implements DQMGlobalEDAnalyzerBase< dtrechit::Histograms, Args... >.

Definition at line 111 of file DTRecHitQuality.cc.

114  {
115  if (doall_ && doStep1_) {
116  histograms.hRes_S1RPhi = std::make_unique<HRes1DHit>("S1RPhi", booker, true, local_); // RecHits, 1. step, RPhi
117  histograms.hRes_S1RPhi_W0 =
118  std::make_unique<HRes1DHit>("S1RPhi_W0", booker, true, local_); // RecHits, 1. step, RZ, wheel 0
119  histograms.hRes_S1RPhi_W1 =
120  std::make_unique<HRes1DHit>("S1RPhi_W1", booker, true, local_); // RecHits, 1. step, RZ, wheel +-1
121  histograms.hRes_S1RPhi_W2 =
122  std::make_unique<HRes1DHit>("S1RPhi_W2", booker, true, local_); // RecHits, 1. step, RZ, wheel +-2
123  histograms.hRes_S1RZ = std::make_unique<HRes1DHit>("S1RZ", booker, true, local_); // RecHits, 1. step, RZ
124  histograms.hRes_S1RZ_W0 =
125  std::make_unique<HRes1DHit>("S1RZ_W0", booker, true, local_); // RecHits, 1. step, RZ, wheel 0
126  histograms.hRes_S1RZ_W1 =
127  std::make_unique<HRes1DHit>("S1RZ_W1", booker, true, local_); // RecHits, 1. step, RZ, wheel +-1
128  histograms.hRes_S1RZ_W2 =
129  std::make_unique<HRes1DHit>("S1RZ_W2", booker, true, local_); // RecHits, 1. step, RZ, wheel +-2
130  histograms.hEff_S1RPhi = std::make_unique<HEff1DHit>("S1RPhi", booker); // RecHits, 1. step, RPhi
131  histograms.hEff_S1RZ = std::make_unique<HEff1DHit>("S1RZ", booker); // RecHits, 1. step, RZ
132  histograms.hEff_S1RZ_W0 = std::make_unique<HEff1DHit>("S1RZ_W0", booker); // RecHits, 1. step, RZ, wheel 0
133  histograms.hEff_S1RZ_W1 = std::make_unique<HEff1DHit>("S1RZ_W1", booker); // RecHits, 1. step, RZ, wheel +-1
134  histograms.hEff_S1RZ_W2 = std::make_unique<HEff1DHit>("S1RZ_W2", booker); // RecHits, 1. step, RZ, wheel +-2
135  }
136  if (doall_ && doStep2_) {
137  histograms.hRes_S2RPhi = std::make_unique<HRes1DHit>("S2RPhi", booker, true, local_); // RecHits, 2. step, RPhi
138  histograms.hRes_S2RPhi_W0 =
139  std::make_unique<HRes1DHit>("S2RPhi_W0", booker, true, local_); // RecHits, 2. step, RPhi, wheel 0
140  histograms.hRes_S2RPhi_W1 =
141  std::make_unique<HRes1DHit>("S2RPhi_W1", booker, true, local_); // RecHits, 2. step, RPhi, wheel +-1
142  histograms.hRes_S2RPhi_W2 =
143  std::make_unique<HRes1DHit>("S2RPhi_W2", booker, true, local_); // RecHits, 2. step, RPhi, wheel +-2
144  histograms.hRes_S2RZ = std::make_unique<HRes1DHit>("S2RZ", booker, true, local_); // RecHits, 2. step, RZ
145  histograms.hRes_S2RZ_W0 =
146  std::make_unique<HRes1DHit>("S2RZ_W0", booker, true, local_); // RecHits, 2. step, RZ, wheel 0
147  histograms.hRes_S2RZ_W1 =
148  std::make_unique<HRes1DHit>("S2RZ_W1", booker, true, local_); // RecHits, 2. step, RZ, wheel +-1
149  histograms.hRes_S2RZ_W2 =
150  std::make_unique<HRes1DHit>("S2RZ_W2", booker, true, local_); // RecHits, 2. step, RZ, wheel +-2
151  histograms.hEff_S2RPhi = std::make_unique<HEff1DHit>("S2RPhi", booker); // RecHits, 2. step, RPhi
152  histograms.hEff_S2RZ_W0 = std::make_unique<HEff1DHit>("S2RZ_W0", booker); // RecHits, 2. step, RZ, wheel 0
153  histograms.hEff_S2RZ_W1 = std::make_unique<HEff1DHit>("S2RZ_W1", booker); // RecHits, 2. step, RZ, wheel +-1
154  histograms.hEff_S2RZ_W2 = std::make_unique<HEff1DHit>("S2RZ_W2", booker); // RecHits, 2. step, RZ, wheel +-2
155  histograms.hEff_S2RZ = std::make_unique<HEff1DHit>("S2RZ", booker); // RecHits, 2. step, RZ
156  }
157  if (doStep3_) {
158  histograms.hRes_S3RPhi = std::make_unique<HRes1DHit>("S3RPhi", booker, doall_, local_); // RecHits, 3. step, RPhi
159  histograms.hRes_S3RPhi_W0 =
160  std::make_unique<HRes1DHit>("S3RPhi_W0", booker, doall_, local_); // RecHits, 3. step, RPhi, wheel 0
161  histograms.hRes_S3RPhi_W1 = std::make_unique<HRes1DHit>("S3RPhi_W1",
162  booker,
163  doall_,
164  local_); // RecHits, 3. step, RPhi, wheel +-1
165  histograms.hRes_S3RPhi_W2 = std::make_unique<HRes1DHit>("S3RPhi_W2",
166  booker,
167  doall_,
168  local_); // RecHits, 3. step, RPhi, wheel +-2
169  histograms.hRes_S3RZ = std::make_unique<HRes1DHit>("S3RZ", booker, doall_, local_); // RecHits, 3. step, RZ
170  histograms.hRes_S3RZ_W0 =
171  std::make_unique<HRes1DHit>("S3RZ_W0", booker, doall_, local_); // RecHits, 3. step, RZ, wheel 0
172  histograms.hRes_S3RZ_W1 =
173  std::make_unique<HRes1DHit>("S3RZ_W1", booker, doall_, local_); // RecHits, 3. step, RZ, wheel +-1
174  histograms.hRes_S3RZ_W2 =
175  std::make_unique<HRes1DHit>("S3RZ_W2", booker, doall_, local_); // RecHits, 3. step, RZ, wheel +-2
176 
177  if (local_) {
178  // Plots with finer granularity, not to be included in DQM
179  TString name1 = "RPhi_W";
180  TString name2 = "RZ_W";
181  for (long w = 0; w <= 2; ++w) {
182  for (long s = 1; s <= 4; ++s) {
183  histograms.hRes_S3RPhiWS[w][s - 1] =
184  std::make_unique<HRes1DHit>(("S3" + name1 + w + "_St" + s).Data(), booker, doall_, local_);
185  histograms.hEff_S1RPhiWS[w][s - 1] =
186  std::make_unique<HEff1DHit>(("S1" + name1 + w + "_St" + s).Data(), booker);
187  histograms.hEff_S3RPhiWS[w][s - 1] =
188  std::make_unique<HEff1DHit>(("S3" + name1 + w + "_St" + s).Data(), booker);
189  if (s != 4) {
190  histograms.hRes_S3RZWS[w][s - 1] =
191  std::make_unique<HRes1DHit>(("S3" + name2 + w + "_St" + s).Data(), booker, doall_, local_);
192  histograms.hEff_S1RZWS[w][s - 1] =
193  std::make_unique<HEff1DHit>(("S1" + name2 + w + "_St" + s).Data(), booker);
194  histograms.hEff_S3RZWS[w][s - 1] =
195  std::make_unique<HEff1DHit>(("S3" + name2 + w + "_St" + s).Data(), booker);
196  }
197  }
198  }
199  }
200 
201  if (doall_) {
202  histograms.hEff_S3RPhi = std::make_unique<HEff1DHit>("S3RPhi", booker); // RecHits, 3. step, RPhi
203  histograms.hEff_S3RZ = std::make_unique<HEff1DHit>("S3RZ", booker); // RecHits, 3. step, RZ
204  histograms.hEff_S3RZ_W0 = std::make_unique<HEff1DHit>("S3RZ_W0", booker); // RecHits, 3. step, RZ, wheel 0
205  histograms.hEff_S3RZ_W1 = std::make_unique<HEff1DHit>("S3RZ_W1", booker); // RecHits, 3. step, RZ, wheel +-1
206  histograms.hEff_S3RZ_W2 = std::make_unique<HEff1DHit>("S3RZ_W2", booker); // RecHits, 3. step, RZ, wheel +-2
207  }
208  }
209 }

References hfnoseParametersInitialization_cfi::name2, alignCSCRings::s, and w.

◆ compute()

template<typename type >
void DTRecHitQuality::compute ( const DTGeometry dtGeom,
const std::map< DTWireId, std::vector< PSimHit >> &  simHitsPerWire,
const std::map< DTWireId, std::vector< type >> &  recHitsPerWire,
dtrechit::Histograms const &  histograms,
int  step 
) const
private

Definition at line 416 of file DTRecHitQuality.cc.

420  {
421  // Loop over cells with a muon SimHit
422  for (const auto &wireAndSHits : simHitsPerWire) {
423  DTWireId wireId = wireAndSHits.first;
424  int wheel = wireId.wheel();
425  int sl = wireId.superLayer();
426 
427  vector<PSimHit> simHitsInCell = wireAndSHits.second;
428 
429  // Get the layer
430  const DTLayer *layer = dtGeom->layer(wireId);
431 
432  // Look for a mu hit in the cell
433  const PSimHit *muSimHit = DTHitQualityUtils::findMuSimHit(simHitsInCell);
434  if (muSimHit == nullptr) {
435  if (debug_) {
436  cout << " No mu SimHit in channel: " << wireId << ", skipping! " << endl;
437  }
438  continue; // Skip this cell
439  }
440 
441  // Find the distance of the simhit from the wire
442  float simHitWireDist = simHitDistFromWire(layer, wireId, *muSimHit);
443  // Skip simhits out of the cell
444  if (simHitWireDist > 2.1) {
445  if (debug_) {
446  cout << " [DTRecHitQuality]###Warning: The mu SimHit in out of the "
447  "cell, skipping!"
448  << endl;
449  }
450  continue; // Skip this cell
451  }
452  GlobalPoint simHitGlobalPos = layer->toGlobal(muSimHit->localPosition());
453 
454  // find SH impact angle
455  float simHitTheta = simHitImpactAngle(layer, wireId, *muSimHit);
456 
457  // find SH distance from FE
458  float simHitFEDist = simHitDistFromFE(layer, wireId, *muSimHit);
459 
460  bool recHitReconstructed = false;
461 
462  // Look for RecHits in the same cell
463  if (recHitsPerWire.find(wireId) == recHitsPerWire.end()) {
464  // No RecHit found in this cell
465  if (debug_) {
466  cout << " No RecHit found at Step: " << step << " in cell: " << wireId << endl;
467  }
468  } else {
469  recHitReconstructed = true;
470  // vector<type> recHits = (*wireAndRecHits).second;
471  const vector<type> &recHits = recHitsPerWire.at(wireId);
472  if (debug_) {
473  cout << " " << recHits.size() << " RecHits, Step " << step << " in channel: " << wireId << endl;
474  }
475 
476  // Find the best RecHit
477  const type *theBestRecHit = findBestRecHit(layer, wireId, recHits, simHitWireDist);
478 
479  float recHitWireDist = recHitDistFromWire(*theBestRecHit, layer);
480  if (debug_) {
481  cout << " SimHit distance from wire: " << simHitWireDist << endl
482  << " SimHit distance from FE: " << simHitFEDist << endl
483  << " SimHit angle in layer RF: " << simHitTheta << endl
484  << " RecHit distance from wire: " << recHitWireDist << endl;
485  }
486  float recHitErr = recHitPositionError(*theBestRecHit);
487  HRes1DHit *hRes = nullptr;
488  HRes1DHit *hResTot = nullptr;
489 
490  // Mirror angle in phi so that + and - wheels can be plotted together
491  if (mirrorMinusWheels && wheel < 0 && sl != 2) {
492  simHitTheta *= -1.;
493  // Note: local X, if used, would have to be mirrored as well
494  }
495 
496  // Fill residuals and pulls
497  // Select the histo to be filled
498  if (step == 1) {
499  // Step 1
500  if (sl != 2) {
501  hResTot = histograms.hRes_S1RPhi.get();
502  if (wheel == 0) {
503  hRes = histograms.hRes_S1RPhi_W0.get();
504  }
505  if (abs(wheel) == 1) {
506  hRes = histograms.hRes_S1RPhi_W1.get();
507  }
508  if (abs(wheel) == 2) {
509  hRes = histograms.hRes_S1RPhi_W2.get();
510  }
511  } else {
512  hResTot = histograms.hRes_S1RZ.get();
513  if (wheel == 0) {
514  hRes = histograms.hRes_S1RZ_W0.get();
515  }
516  if (abs(wheel) == 1) {
517  hRes = histograms.hRes_S1RZ_W1.get();
518  }
519  if (abs(wheel) == 2) {
520  hRes = histograms.hRes_S1RZ_W2.get();
521  }
522  }
523 
524  } else if (step == 2) {
525  // Step 2
526  if (sl != 2) {
527  hRes = histograms.hRes_S2RPhi.get();
528  if (wheel == 0) {
529  hRes = histograms.hRes_S2RPhi_W0.get();
530  }
531  if (abs(wheel) == 1) {
532  hRes = histograms.hRes_S2RPhi_W1.get();
533  }
534  if (abs(wheel) == 2) {
535  hRes = histograms.hRes_S2RPhi_W2.get();
536  }
537  } else {
538  hResTot = histograms.hRes_S2RZ.get();
539  if (wheel == 0) {
540  hRes = histograms.hRes_S2RZ_W0.get();
541  }
542  if (abs(wheel) == 1) {
543  hRes = histograms.hRes_S2RZ_W1.get();
544  }
545  if (abs(wheel) == 2) {
546  hRes = histograms.hRes_S2RZ_W2.get();
547  }
548  }
549 
550  } else if (step == 3) {
551  // Step 3
552  if (sl != 2) {
553  hResTot = histograms.hRes_S3RPhi.get();
554  if (wheel == 0) {
555  hRes = histograms.hRes_S3RPhi_W0.get();
556  }
557  if (abs(wheel) == 1) {
558  hRes = histograms.hRes_S3RPhi_W1.get();
559  }
560  if (abs(wheel) == 2) {
561  hRes = histograms.hRes_S3RPhi_W2.get();
562  }
563  if (local_) {
564  histograms.hRes_S3RPhiWS[abs(wheel)][wireId.station() - 1]->fill(simHitWireDist,
565  simHitTheta,
566  simHitFEDist,
567  recHitWireDist,
568  simHitGlobalPos.eta(),
569  simHitGlobalPos.phi(),
570  recHitErr,
571  wireId.station());
572  }
573  } else {
574  hResTot = histograms.hRes_S3RZ.get();
575  if (wheel == 0) {
576  hRes = histograms.hRes_S3RZ_W0.get();
577  }
578  if (abs(wheel) == 1) {
579  hRes = histograms.hRes_S3RZ_W1.get();
580  }
581  if (abs(wheel) == 2) {
582  hRes = histograms.hRes_S3RZ_W2.get();
583  }
584  if (local_) {
585  histograms.hRes_S3RZWS[abs(wheel)][wireId.station() - 1]->fill(simHitWireDist,
586  simHitTheta,
587  simHitFEDist,
588  recHitWireDist,
589  simHitGlobalPos.eta(),
590  simHitGlobalPos.phi(),
591  recHitErr,
592  wireId.station());
593  }
594  }
595  }
596 
597  // Fill
598  hRes->fill(simHitWireDist,
599  simHitTheta,
600  simHitFEDist,
601  recHitWireDist,
602  simHitGlobalPos.eta(),
603  simHitGlobalPos.phi(),
604  recHitErr,
605  wireId.station());
606  if (hResTot != nullptr) {
607  hResTot->fill(simHitWireDist,
608  simHitTheta,
609  simHitFEDist,
610  recHitWireDist,
611  simHitGlobalPos.eta(),
612  simHitGlobalPos.phi(),
613  recHitErr,
614  wireId.station());
615  }
616  }
617 
618  // Fill Efficiencies
619  if (doall_) {
620  HEff1DHit *hEff = nullptr;
621  HEff1DHit *hEffTot = nullptr;
622  if (step == 1) {
623  // Step 1
624  if (sl != 2) {
625  hEff = histograms.hEff_S1RPhi.get();
626  if (local_) {
627  histograms.hEff_S1RPhiWS[abs(wheel)][wireId.station() - 1]->fill(
628  simHitWireDist, simHitGlobalPos.eta(), simHitGlobalPos.phi(), recHitReconstructed);
629  }
630  } else {
631  hEffTot = histograms.hEff_S1RZ.get();
632  if (wheel == 0) {
633  hEff = histograms.hEff_S1RZ_W0.get();
634  }
635  if (abs(wheel) == 1) {
636  hEff = histograms.hEff_S1RZ_W1.get();
637  }
638  if (abs(wheel) == 2) {
639  hEff = histograms.hEff_S1RZ_W2.get();
640  }
641  if (local_) {
642  histograms.hEff_S1RZWS[abs(wheel)][wireId.station() - 1]->fill(
643  simHitWireDist, simHitGlobalPos.eta(), simHitGlobalPos.phi(), recHitReconstructed);
644  }
645  }
646 
647  } else if (step == 2) {
648  // Step 2
649  if (sl != 2) {
650  hEff = histograms.hEff_S2RPhi.get();
651  } else {
652  hEffTot = histograms.hEff_S2RZ.get();
653  if (wheel == 0) {
654  hEff = histograms.hEff_S2RZ_W0.get();
655  }
656  if (abs(wheel) == 1) {
657  hEff = histograms.hEff_S2RZ_W1.get();
658  }
659  if (abs(wheel) == 2) {
660  hEff = histograms.hEff_S2RZ_W2.get();
661  }
662  }
663 
664  } else if (step == 3) {
665  // Step 3
666  if (sl != 2) {
667  hEff = histograms.hEff_S3RPhi.get();
668  if (local_) {
669  histograms.hEff_S3RPhiWS[abs(wheel)][wireId.station() - 1]->fill(
670  simHitWireDist, simHitGlobalPos.eta(), simHitGlobalPos.phi(), recHitReconstructed);
671  }
672  } else {
673  hEffTot = histograms.hEff_S3RZ.get();
674  if (wheel == 0) {
675  hEff = histograms.hEff_S3RZ_W0.get();
676  }
677  if (abs(wheel) == 1) {
678  hEff = histograms.hEff_S3RZ_W1.get();
679  }
680  if (abs(wheel) == 2) {
681  hEff = histograms.hEff_S3RZ_W2.get();
682  }
683  if (local_) {
684  histograms.hEff_S3RZWS[abs(wheel)][wireId.station() - 1]->fill(
685  simHitWireDist, simHitGlobalPos.eta(), simHitGlobalPos.phi(), recHitReconstructed);
686  }
687  }
688  }
689  // Fill
690  hEff->fill(simHitWireDist, simHitGlobalPos.eta(), simHitGlobalPos.phi(), recHitReconstructed);
691  if (hEffTot != nullptr) {
692  hEffTot->fill(simHitWireDist, simHitGlobalPos.eta(), simHitGlobalPos.phi(), recHitReconstructed);
693  }
694  }
695  }
696 }

References funct::abs(), gather_cfg::cout, PV3DBase< T, PVType, FrameType >::eta(), HRes1DHit::fill(), HEff1DHit::fill(), DTHitQualityUtils::findMuSimHit(), PixelMapPlotter::hRes, DTGeometry::layer(), PSimHit::localPosition(), PV3DBase< T, PVType, FrameType >::phi(), FastTrackerRecHitMaskProducer_cfi::recHits, DTChamberId::station(), DTSuperLayerId::superLayer(), GeomDet::toGlobal(), DTChamberId::wheel(), and makeMuonMisalignmentScenario::wheel.

◆ dqmAnalyze()

void DTRecHitQuality::dqmAnalyze ( edm::Event const &  event,
edm::EventSetup const &  setup,
dtrechit::Histograms const &  histograms 
) const
overrideprivatevirtual

Perform the real analysis.

Implements DQMGlobalEDAnalyzerBase< dtrechit::Histograms, Args... >.

Definition at line 212 of file DTRecHitQuality.cc.

214  {
215  if (debug_) {
216  cout << "--- [DTRecHitQuality] Analysing Event: #Run: " << event.id().run() << " #Event: " << event.id().event()
217  << endl;
218  }
219 
220  // Get the DT Geometry
221  ESHandle<DTGeometry> dtGeom;
222  setup.get<MuonGeometryRecord>().get(dtGeom);
223 
224  // Get the SimHit collection from the event
226  event.getByToken(simHitToken_, simHits);
227 
228  // Map simhits per wire
229  map<DTWireId, PSimHitContainer> simHitsPerWire = DTHitQualityUtils::mapSimHitsPerWire(*(simHits.product()));
230 
231  //=======================================================================================
232  // RecHit analysis at Step 1
233  if (doStep1_ && doall_) {
234  if (debug_) {
235  cout << " -- DTRecHit S1: begin analysis:" << endl;
236  }
237  // Get the rechit collection from the event
238  Handle<DTRecHitCollection> dtRecHits;
239  event.getByToken(recHitToken_, dtRecHits);
240 
241  if (!dtRecHits.isValid()) {
242  if (debug_) {
243  cout << "[DTRecHitQuality]**Warning: no 1DRechits with label: " << recHitLabel_ << " in this event, skipping!"
244  << endl;
245  }
246  return;
247  }
248 
249  // Map rechits per wire
250  auto const &recHitsPerWire = map1DRecHitsPerWire(dtRecHits.product());
251  compute(dtGeom.product(), simHitsPerWire, recHitsPerWire, histograms, 1);
252  }
253 
254  //=======================================================================================
255  // RecHit analysis at Step 2
256  if (doStep2_ && doall_) {
257  if (debug_) {
258  cout << " -- DTRecHit S2: begin analysis:" << endl;
259  }
260 
261  // Get the 2D rechits from the event
263  event.getByToken(segment2DToken_, segment2Ds);
264 
265  if (!segment2Ds.isValid()) {
266  if (debug_) {
267  cout << "[DTRecHitQuality]**Warning: no 2DSegments with label: " << segment2DLabel_
268  << " in this event, skipping!" << endl;
269  }
270 
271  } else {
272  // Map rechits per wire
273  auto const &recHitsPerWire = map1DRecHitsPerWire(segment2Ds.product());
274  compute(dtGeom.product(), simHitsPerWire, recHitsPerWire, histograms, 2);
275  }
276  }
277 
278  //=======================================================================================
279  // RecHit analysis at Step 3
280  if (doStep3_) {
281  if (debug_) {
282  cout << " -- DTRecHit S3: begin analysis:" << endl;
283  }
284 
285  // Get the 4D rechits from the event
287  event.getByToken(segment4DToken_, segment4Ds);
288 
289  if (!segment4Ds.isValid()) {
290  if (debug_) {
291  cout << "[DTRecHitQuality]**Warning: no 4D Segments with label: " << segment4DLabel_
292  << " in this event, skipping!" << endl;
293  }
294  return;
295  }
296 
297  // Map rechits per wire
298  auto const &recHitsPerWire = map1DRecHitsPerWire(segment4Ds.product());
299  compute(dtGeom.product(), simHitsPerWire, recHitsPerWire, histograms, 3);
300  }
301 }

References bookConverter::compute(), gather_cfg::cout, get, bookConverter::histograms, edm::HandleBase::isValid(), DTHitQualityUtils::mapSimHitsPerWire(), edm::Handle< T >::product(), edm::ESHandle< T >::product(), singleTopDQM_cfi::setup, and FastTrackerRecHitCombiner_cfi::simHits.

◆ findBestRecHit()

template<typename type >
const type * DTRecHitQuality::findBestRecHit ( const DTLayer layer,
const DTWireId wireId,
const std::vector< type > &  recHits,
float  simHitDist 
) const
private

Definition at line 386 of file DTRecHitQuality.cc.

389  {
390  float res = 99999;
391  const type *theBestRecHit = nullptr;
392  // Loop over RecHits within the cell
393  for (auto recHit = recHits.begin(); recHit != recHits.end(); recHit++) {
394  float distTmp = recHitDistFromWire(*recHit, layer);
395  if (fabs(distTmp - simHitDist) < res) {
396  res = fabs(distTmp - simHitDist);
397  theBestRecHit = &(*recHit);
398  }
399  } // End of loop over RecHits within the cell
400 
401  return theBestRecHit;
402 }

References rpcPointValidation_cfi::recHit, and FastTrackerRecHitMaskProducer_cfi::recHits.

◆ map1DRecHitsPerWire() [1/3]

map< DTWireId, vector< DTRecHit1DPair > > DTRecHitQuality::map1DRecHitsPerWire ( const DTRecHitCollection dt1DRecHitPairs) const
private

Definition at line 304 of file DTRecHitQuality.cc.

305  {
306  map<DTWireId, vector<DTRecHit1DPair>> ret;
307 
308  for (const auto &dt1DRecHitPair : *dt1DRecHitPairs) {
309  ret[dt1DRecHitPair.wireId()].push_back(dt1DRecHitPair);
310  }
311 
312  return ret;
313 }

References runTheMatrix::ret.

◆ map1DRecHitsPerWire() [2/3]

map< DTWireId, vector< DTRecHit1D > > DTRecHitQuality::map1DRecHitsPerWire ( const DTRecSegment2DCollection segment2Ds) const
private

Definition at line 316 of file DTRecHitQuality.cc.

317  {
318  map<DTWireId, vector<DTRecHit1D>> ret;
319 
320  // Loop over all 2D segments
321  for (const auto &segment2D : *segment2Ds) {
322  vector<DTRecHit1D> component1DHits = segment2D.specificRecHits();
323  // Loop over all component 1D hits
324  for (auto &component1DHit : component1DHits) {
325  ret[component1DHit.wireId()].push_back(component1DHit);
326  }
327  }
328  return ret;
329 }

References runTheMatrix::ret.

◆ map1DRecHitsPerWire() [3/3]

map< DTWireId, std::vector< DTRecHit1D > > DTRecHitQuality::map1DRecHitsPerWire ( const DTRecSegment4DCollection segment4Ds) const
private

Definition at line 332 of file DTRecHitQuality.cc.

333  {
334  map<DTWireId, vector<DTRecHit1D>> ret;
335  // Loop over all 4D segments
336  for (const auto &segment4D : *segment4Ds) {
337  // Get component 2D segments
338  vector<const TrackingRecHit *> segment2Ds = segment4D.recHits();
339  // Loop over 2D segments:
340  for (auto &segment2D : segment2Ds) {
341  // Get 1D component rechits
342  vector<const TrackingRecHit *> hits = segment2D->recHits();
343  // Loop over them
344  for (auto &hit : hits) {
345  const auto *hit1D = dynamic_cast<const DTRecHit1D *>(hit);
346  ret[hit1D->wireId()].push_back(*hit1D);
347  }
348  }
349  }
350 
351  return ret;
352 }

References hfClusterShapes_cfi::hits, and runTheMatrix::ret.

◆ recHitDistFromWire() [1/2]

float DTRecHitQuality::recHitDistFromWire ( const DTRecHit1D recHit,
const DTLayer layer 
) const
private

Definition at line 411 of file DTRecHitQuality.cc.

411  {
412  return fabs(recHit.localPosition().x() - layer->specificTopology().wirePosition(recHit.wireId().wire()));
413 }

References rpcPointValidation_cfi::recHit, DTLayer::specificTopology(), and DTTopology::wirePosition().

◆ recHitDistFromWire() [2/2]

float DTRecHitQuality::recHitDistFromWire ( const DTRecHit1DPair hitPair,
const DTLayer layer 
) const
private

Definition at line 405 of file DTRecHitQuality.cc.

405  {
406  // Compute the rechit distance from wire
407  return fabs(hitPair.localPosition(DTEnums::Left).x() - hitPair.localPosition(DTEnums::Right).x()) / 2.;
408 }

References DTEnums::Left, DTRecHit1DPair::localPosition(), DTEnums::Right, and PV3DBase< T, PVType, FrameType >::x().

◆ recHitPositionError() [1/2]

float DTRecHitQuality::recHitPositionError ( const DTRecHit1D recHit) const
private

Definition at line 704 of file DTRecHitQuality.cc.

704  {
705  return sqrt(recHit.localPositionError().xx());
706 }

References rpcPointValidation_cfi::recHit, and mathSSE::sqrt().

◆ recHitPositionError() [2/2]

float DTRecHitQuality::recHitPositionError ( const DTRecHit1DPair recHit) const
private

Definition at line 699 of file DTRecHitQuality.cc.

699  {
700  return sqrt(recHit.localPositionError(DTEnums::Left).xx());
701 }

References DTEnums::Left, rpcPointValidation_cfi::recHit, and mathSSE::sqrt().

◆ simHitDistFromFE()

float DTRecHitQuality::simHitDistFromFE ( const DTLayer layer,
const DTWireId wireId,
const PSimHit hit 
) const
private

Definition at line 374 of file DTRecHitQuality.cc.

374  {
375  LocalPoint entryP = hit.entryPoint();
376  LocalPoint exitP = hit.exitPoint();
377  float wireLenght = layer->specificTopology().cellLenght();
378  // FIXME: should take only wireLenght/2.;
379  // moreover, pos+cellLenght/2. is shorter than the distance from FE.
380  // In fact it would make more sense to make plots vs y.
381  return (entryP.y() + exitP.y()) / 2. + wireLenght;
382 }

References DTTopology::cellLenght(), DTLayer::specificTopology(), and PV3DBase< T, PVType, FrameType >::y().

◆ simHitDistFromWire()

float DTRecHitQuality::simHitDistFromWire ( const DTLayer layer,
const DTWireId wireId,
const PSimHit hit 
) const
private

Definition at line 355 of file DTRecHitQuality.cc.

355  {
356  float xwire = layer->specificTopology().wirePosition(wireId.wire());
357  LocalPoint entryP = hit.entryPoint();
358  LocalPoint exitP = hit.exitPoint();
359  float xEntry = entryP.x() - xwire;
360  float xExit = exitP.x() - xwire;
361 
362  return fabs(xEntry - (entryP.z() * (xExit - xEntry)) / (exitP.z() - entryP.z())); // FIXME: check...
363 }

References DTLayer::specificTopology(), DTWireId::wire(), DTTopology::wirePosition(), PV3DBase< T, PVType, FrameType >::x(), and PV3DBase< T, PVType, FrameType >::z().

◆ simHitImpactAngle()

float DTRecHitQuality::simHitImpactAngle ( const DTLayer layer,
const DTWireId wireId,
const PSimHit hit 
) const
private

Definition at line 366 of file DTRecHitQuality.cc.

366  {
367  LocalPoint entryP = hit.entryPoint();
368  LocalPoint exitP = hit.exitPoint();
369  float theta = (exitP.x() - entryP.x()) / (exitP.z() - entryP.z());
370  return atan(theta);
371 }

References theta(), PV3DBase< T, PVType, FrameType >::x(), and PV3DBase< T, PVType, FrameType >::z().

Member Data Documentation

◆ debug_

bool DTRecHitQuality::debug_
private

Definition at line 63 of file DTRecHitQuality.h.

◆ doall_

bool DTRecHitQuality::doall_
private

Definition at line 82 of file DTRecHitQuality.h.

◆ doStep1_

bool DTRecHitQuality::doStep1_
private

Definition at line 78 of file DTRecHitQuality.h.

◆ doStep2_

bool DTRecHitQuality::doStep2_
private

Definition at line 79 of file DTRecHitQuality.h.

◆ doStep3_

bool DTRecHitQuality::doStep3_
private

Definition at line 80 of file DTRecHitQuality.h.

◆ local_

bool DTRecHitQuality::local_
private

Definition at line 81 of file DTRecHitQuality.h.

◆ recHitLabel_

edm::InputTag DTRecHitQuality::recHitLabel_
private

Definition at line 73 of file DTRecHitQuality.h.

◆ recHitToken_

edm::EDGetTokenT<DTRecHitCollection> DTRecHitQuality::recHitToken_
private

Definition at line 67 of file DTRecHitQuality.h.

◆ segment2DLabel_

edm::InputTag DTRecHitQuality::segment2DLabel_
private

Definition at line 74 of file DTRecHitQuality.h.

◆ segment2DToken_

edm::EDGetTokenT<DTRecSegment2DCollection> DTRecHitQuality::segment2DToken_
private

Definition at line 68 of file DTRecHitQuality.h.

◆ segment4DLabel_

edm::InputTag DTRecHitQuality::segment4DLabel_
private

Definition at line 75 of file DTRecHitQuality.h.

◆ segment4DToken_

edm::EDGetTokenT<DTRecSegment4DCollection> DTRecHitQuality::segment4DToken_
private

Definition at line 69 of file DTRecHitQuality.h.

◆ simHitLabel_

edm::InputTag DTRecHitQuality::simHitLabel_
private

Definition at line 70 of file DTRecHitQuality.h.

◆ simHitToken_

edm::EDGetTokenT<edm::PSimHitContainer> DTRecHitQuality::simHitToken_
private

Definition at line 66 of file DTRecHitQuality.h.

runTheMatrix.ret
ret
prodAgent to be discontinued
Definition: runTheMatrix.py:373
edm::ESHandle::product
T const * product() const
Definition: ESHandle.h:86
DTRecHitQuality::recHitDistFromWire
float recHitDistFromWire(const DTRecHit1DPair &hitPair, const DTLayer *layer) const
Definition: DTRecHitQuality.cc:405
DTWireId::wire
int wire() const
Return the wire number.
Definition: DTWireId.h:42
edm::Handle::product
T const * product() const
Definition: Handle.h:70
DTRecHitQuality::simHitToken_
edm::EDGetTokenT< edm::PSimHitContainer > simHitToken_
Definition: DTRecHitQuality.h:66
hfClusterShapes_cfi.hits
hits
Definition: hfClusterShapes_cfi.py:5
DTRecHitQuality::segment2DLabel_
edm::InputTag segment2DLabel_
Definition: DTRecHitQuality.h:74
step
step
Definition: StallMonitor.cc:94
DTRecHitQuality::debug_
bool debug_
Definition: DTRecHitQuality.h:63
PV3DBase::x
T x() const
Definition: PV3DBase.h:59
HEff1DHit
A set of histograms fo efficiency computation for 1D RecHits (producer)
Definition: Histograms.h:138
DTRecHitQuality::simHitImpactAngle
float simHitImpactAngle(const DTLayer *layer, const DTWireId &wireId, const PSimHit &hit) const
Definition: DTRecHitQuality.cc:366
DTRecHitQuality::doall_
bool doall_
Definition: DTRecHitQuality.h:82
gather_cfg.cout
cout
Definition: gather_cfg.py:144
DTRecHitQuality::recHitLabel_
edm::InputTag recHitLabel_
Definition: DTRecHitQuality.h:73
DTRecHitQuality::simHitLabel_
edm::InputTag simHitLabel_
Definition: DTRecHitQuality.h:70
DTRecHitQuality::segment2DToken_
edm::EDGetTokenT< DTRecSegment2DCollection > segment2DToken_
Definition: DTRecHitQuality.h:68
FastTrackerRecHitCombiner_cfi.simHits
simHits
Definition: FastTrackerRecHitCombiner_cfi.py:5
DTRecHitQuality::compute
void compute(const DTGeometry *dtGeom, const std::map< DTWireId, std::vector< PSimHit >> &simHitsPerWire, const std::map< DTWireId, std::vector< type >> &recHitsPerWire, dtrechit::Histograms const &histograms, int step) const
Definition: DTRecHitQuality.cc:416
DTSuperLayerId::superLayer
int superLayer() const
Return the superlayer number.
Definition: DTSuperLayerId.h:39
DTRecHitQuality::recHitToken_
edm::EDGetTokenT< DTRecHitCollection > recHitToken_
Definition: DTRecHitQuality.h:67
edm::Handle
Definition: AssociativeIterator.h:50
DTRecHitQuality::segment4DToken_
edm::EDGetTokenT< DTRecSegment4DCollection > segment4DToken_
Definition: DTRecHitQuality.h:69
rpcPointValidation_cfi.recHit
recHit
Definition: rpcPointValidation_cfi.py:7
singleTopDQM_cfi.setup
setup
Definition: singleTopDQM_cfi.py:37
PV3DBase::z
T z() const
Definition: PV3DBase.h:61
DTTopology::wirePosition
float wirePosition(int wireNumber) const
Returns the x position in the layer of a given wire number.
Definition: DTTopology.cc:59
alignCSCRings.s
s
Definition: alignCSCRings.py:92
DTEnums::Left
Definition: DTEnums.h:15
DTHitQualityUtils::findMuSimHit
const PSimHit * findMuSimHit(const edm::PSimHitContainer &hits)
Select the SimHit from a muon in a vector of SimHits.
DTRecHitQuality::doStep1_
bool doStep1_
Definition: DTRecHitQuality.h:78
PixelMapPlotter.hRes
hRes
Definition: PixelMapPlotter.py:31
DTWireId
Definition: DTWireId.h:12
w
const double w
Definition: UKUtility.cc:23
mathSSE::sqrt
T sqrt(T t)
Definition: SSEVec.h:19
DTRecHitQuality::recHitPositionError
float recHitPositionError(const DTRecHit1DPair &recHit) const
Definition: DTRecHitQuality.cc:699
edm::ESHandle< DTGeometry >
PSimHit::localPosition
Local3DPoint localPosition() const
Definition: PSimHit.h:52
theta
Geom::Theta< T > theta() const
Definition: Basic3DVectorLD.h:150
Point3DBase< float, GlobalTag >
DTTopology::cellLenght
float cellLenght() const
Definition: DTTopology.h:74
FastTrackerRecHitMaskProducer_cfi.recHits
recHits
Definition: FastTrackerRecHitMaskProducer_cfi.py:8
DTRecHitQuality::map1DRecHitsPerWire
std::map< DTWireId, std::vector< DTRecHit1DPair > > map1DRecHitsPerWire(const DTRecHitCollection *dt1DRecHitPairs) const
Definition: DTRecHitQuality.cc:304
HRes1DHit
A set of histograms of residuals and pulls for 1D RecHits.
Definition: Histograms.h:44
GeomDet::toGlobal
GlobalPoint toGlobal(const Local2DPoint &lp) const
Conversion to the global R.F. from the R.F. of the GeomDet.
Definition: GeomDet.h:49
DTHitQualityUtils::mapSimHitsPerWire
std::map< DTWireId, edm::PSimHitContainer > mapSimHitsPerWire(const edm::PSimHitContainer &simhits)
DTGeometry::layer
const DTLayer * layer(const DTLayerId &id) const
Return a layer given its id.
Definition: DTGeometry.cc:96
DTRecHitQuality::doStep3_
bool doStep3_
Definition: DTRecHitQuality.h:80
DTRecHitQuality::local_
bool local_
Definition: DTRecHitQuality.h:81
type
type
Definition: SiPixelVCal_PayloadInspector.cc:37
PV3DBase::eta
T eta() const
Definition: PV3DBase.h:73
PV3DBase::y
T y() const
Definition: PV3DBase.h:60
makeMuonMisalignmentScenario.wheel
wheel
Definition: makeMuonMisalignmentScenario.py:319
bookConverter.histograms
histograms
Definition: bookConverter.py:142
DTRecHitQuality::doStep2_
bool doStep2_
Definition: DTRecHitQuality.h:79
histograms
Definition: histograms.py:1
get
#define get
res
Definition: Electron.h:6
DTLayer
Definition: DTLayer.h:25
HEff1DHit::fill
void fill(float distSimHit, float etaSimHit, float phiSimHit, bool fillRecHit)
Definition: Histograms.h:157
HRes1DHit::fill
void fill(float distSimHit, float thetaSimHit, float distFESimHit, float distRecHit, float etaSimHit, float phiSimHit, float errRecHit, int station)
Definition: Histograms.h:83
DTEnums::Right
Definition: DTEnums.h:15
DTRecHit1DPair::localPosition
LocalPoint localPosition() const override
Definition: DTRecHit1DPair.cc:29
DTRecHitQuality::simHitDistFromFE
float simHitDistFromFE(const DTLayer *layer, const DTWireId &wireId, const PSimHit &hit) const
Definition: DTRecHitQuality.cc:374
DTRecHitQuality::simHitDistFromWire
float simHitDistFromWire(const DTLayer *layer, const DTWireId &wireId, const PSimHit &hit) const
Definition: DTRecHitQuality.cc:355
DTRecHitQuality::segment4DLabel_
edm::InputTag segment4DLabel_
Definition: DTRecHitQuality.h:75
DTLayer::specificTopology
const DTTopology & specificTopology() const
Definition: DTLayer.cc:37
funct::abs
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
PSimHit
Definition: PSimHit.h:15
edm::HandleBase::isValid
bool isValid() const
Definition: HandleBase.h:70
hfnoseParametersInitialization_cfi.name2
name2
Definition: hfnoseParametersInitialization_cfi.py:8
DTRecHitQuality::findBestRecHit
const type * findBestRecHit(const DTLayer *layer, const DTWireId &wireId, const std::vector< type > &recHits, float simHitDist) const
Definition: DTRecHitQuality.cc:386
MuonGeometryRecord
Definition: MuonGeometryRecord.h:34
DTChamberId::wheel
int wheel() const
Return the wheel number.
Definition: DTChamberId.h:39
edm::InputTag
Definition: InputTag.h:15
PV3DBase::phi
Geom::Phi< T > phi() const
Definition: PV3DBase.h:66
DTChamberId::station
int station() const
Return the station number.
Definition: DTChamberId.h:42
hit
Definition: SiStripHitEffFromCalibTree.cc:88
muonDTDigis_cfi.pset
pset
Definition: muonDTDigis_cfi.py:27