CMS 3D CMS Logo

List of all members | Public Member Functions | Protected Member Functions | Private Types | Private Attributes
MuonDTDigis Class Reference

#include <MuonDTDigis.h>

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

Public Member Functions

 MuonDTDigis (const edm::ParameterSet &pset)
 
 ~MuonDTDigis () 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
 
virtual void dqmBeginRun (edm::Run const &, edm::EventSetup const &)
 
 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
 

Protected Member Functions

void analyze (const edm::Event &event, const edm::EventSetup &eventSetup) override
 
void bookHistograms (DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
 
hDigisWheelHistos (int wheel)
 
- Protected Member Functions inherited from DQMEDAnalyzer
uint64_t meId () const
 

Private Types

typedef std::map< DTWireId, std::vector< const PSimHit * > > DTWireIdMap
 

Private Attributes

edm::EDGetTokenT< DTDigiCollectionDigiToken_
 
std::unique_ptr< hHitshAllHits
 
std::unique_ptr< hDigishDigis_global
 
std::unique_ptr< hDigishDigis_W0
 
std::unique_ptr< hDigishDigis_W1
 
std::unique_ptr< hDigishDigis_W2
 
MonitorElementmeDigiEfficiency_
 
MonitorElementmeDigiEfficiencyMu_
 
MonitorElementmeDigiHisto_
 
MonitorElementmeDigiTimeBox_
 
std::vector< MonitorElement * > meDigiTimeBox_SL_
 
MonitorElementmeDigiTimeBox_wheel0_
 
MonitorElementmeDigiTimeBox_wheel1m_
 
MonitorElementmeDigiTimeBox_wheel1p_
 
MonitorElementmeDigiTimeBox_wheel2m_
 
MonitorElementmeDigiTimeBox_wheel2p_
 
MonitorElementmeDoubleDigi_
 
MonitorElementmeMB1_digi_occup_
 
MonitorElementmeMB1_sim_occup_
 
MonitorElementmeMB2_digi_occup_
 
MonitorElementmeMB2_sim_occup_
 
MonitorElementmeMB3_digi_occup_
 
MonitorElementmeMB3_sim_occup_
 
MonitorElementmeMB4_digi_occup_
 
MonitorElementmeMB4_sim_occup_
 
MonitorElementmeSimvsDigi_
 
MonitorElementmeWire_DoubleDigi_
 
const DTGeometrymuonGeom
 
edm::ESGetToken< DTGeometry, MuonGeometryRecordmuonGeomToken_
 
edm::EDGetTokenT< edm::PSimHitContainerSimHitToken_
 
bool verbose_
 

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 Attributes inherited from DQMEDAnalyzer
edm::EDPutTokenT< DQMTokenlumiToken_
 
edm::EDPutTokenT< DQMTokenrunToken_
 
unsigned int streamId_
 

Detailed Description

Analyse the the muon-drift-tubes digitizer.

Authors
: R. Bellan

Definition at line 48 of file MuonDTDigis.h.

Member Typedef Documentation

◆ DTWireIdMap

typedef std::map<DTWireId, std::vector<const PSimHit *> > MuonDTDigis::DTWireIdMap
private

Definition at line 64 of file MuonDTDigis.h.

Constructor & Destructor Documentation

◆ MuonDTDigis()

MuonDTDigis::MuonDTDigis ( const edm::ParameterSet pset)
explicit

Definition at line 19 of file MuonDTDigis.cc.

References DigiToken_, hAllHits, hDigis_global, hDigis_W0, hDigis_W1, hDigis_W2, muonDTDigis_cfi::pset, SimHitToken_, and verbose_.

20  // ----------------------
21  // Get the debug parameter for verbose output
22  verbose_ = pset.getUntrackedParameter<bool>("verbose", false);
23 
24  // the name of the Digi collection
25  SimHitToken_ = consumes<edm::PSimHitContainer>(pset.getParameter<edm::InputTag>("SimHitLabel"));
26 
27  // the name of the Digi collection
28  DigiToken_ = consumes<DTDigiCollection>(pset.getParameter<edm::InputTag>(("DigiLabel")));
29 
30  hDigis_global = std::make_unique<hDigis>("Global");
31  hDigis_W0 = std::make_unique<hDigis>("Wheel0");
32  hDigis_W1 = std::make_unique<hDigis>("Wheel1");
33  hDigis_W2 = std::make_unique<hDigis>("Wheel2");
34  hAllHits = std::make_unique<hHits>("AllHits");
35 }
ESGetTokenH3DDVariant esConsumes(std::string const &Record, edm::ConsumesCollector &)
Definition: DeDxTools.cc:283
edm::EDGetTokenT< DTDigiCollection > DigiToken_
Definition: MuonDTDigis.h:67
std::unique_ptr< hDigis > hDigis_global
Definition: MuonDTDigis.h:103
edm::EDGetTokenT< edm::PSimHitContainer > SimHitToken_
Definition: MuonDTDigis.h:66
std::unique_ptr< hDigis > hDigis_W1
Definition: MuonDTDigis.h:105
std::unique_ptr< hDigis > hDigis_W0
Definition: MuonDTDigis.h:104
edm::ESGetToken< DTGeometry, MuonGeometryRecord > muonGeomToken_
Definition: MuonDTDigis.h:69
std::unique_ptr< hHits > hAllHits
Definition: MuonDTDigis.h:107
std::unique_ptr< hDigis > hDigis_W2
Definition: MuonDTDigis.h:106
bool verbose_
Definition: MuonDTDigis.h:73

◆ ~MuonDTDigis()

MuonDTDigis::~MuonDTDigis ( )
override

Definition at line 37 of file MuonDTDigis.cc.

References gather_cfg::cout, and verbose_.

37  {
38  if (verbose_)
39  cout << "[MuonDTDigis] Destructor called" << endl;
40 }
bool verbose_
Definition: MuonDTDigis.h:73

Member Function Documentation

◆ analyze()

void MuonDTDigis::analyze ( const edm::Event event,
const edm::EventSetup eventSetup 
)
overrideprotectedvirtual

Reimplemented from DQMEDAnalyzer.

Definition at line 162 of file MuonDTDigis.cc.

References funct::abs(), gather_cfg::cout, DigiToken_, options_cfi::eventSetup, hDigis::Fill(), dqm::impl::MonitorElement::Fill(), hAllHits, hDigis_global, M_PI, mag(), meDigiEfficiency_, meDigiEfficiencyMu_, meDigiTimeBox_, meDigiTimeBox_SL_, meDigiTimeBox_wheel0_, meDigiTimeBox_wheel1m_, meDigiTimeBox_wheel1p_, meDigiTimeBox_wheel2m_, meDigiTimeBox_wheel2p_, meDoubleDigi_, meMB1_digi_occup_, meMB1_sim_occup_, meMB2_digi_occup_, meMB2_sim_occup_, meMB3_digi_occup_, meMB3_sim_occup_, meMB4_digi_occup_, meMB4_sim_occup_, meSimvsDigi_, meWire_DoubleDigi_, amptDefaultParameters_cff::mu, muonGeom, muonGeomToken_, castor_dqm_sourceclient_file_cfg::path, FastTimerService_cff::range, FastTrackerRecHitCombiner_cfi::simHits, SimHitToken_, relativeConstraints::station, theta(), verbose_, makeMuonMisalignmentScenario::wheel, WheelHistos(), x, PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), and PV3DBase< T, PVType, FrameType >::z().

162  {
163  if (verbose_)
164  cout << "--- [MuonDTDigis] Analysing Event: #Run: " << event.id().run() << " #Event: " << event.id().event()
165  << endl;
166 
167  // Get the DT Geometry
168  muonGeom = &eventSetup.getData(muonGeomToken_);
169 
170  // Get the Digi collection from the event
171  Handle<DTDigiCollection> dtDigis;
172  event.getByToken(DigiToken_, dtDigis);
173 
174  // Get simhits
176  event.getByToken(SimHitToken_, simHits);
177 
178  int num_mudigis;
179  int num_musimhits;
180  int num_digis;
181  int num_digis_layer;
182  int cham_num;
183  int wire_touched;
184  num_digis = 0;
185  num_mudigis = 0;
186  num_musimhits = 0;
187  DTWireIdMap wireMap;
188 
189  for (vector<PSimHit>::const_iterator hit = simHits->begin(); hit != simHits->end(); hit++) {
190  // Create the id of the wire, the simHits in the DT known also the wireId
191  DTWireId wireId(hit->detUnitId());
192  // cout << " PSimHits wire id " << wireId << " part type " <<
193  // hit->particleType() << endl;
194 
195  // Fill the map
196  wireMap[wireId].push_back(&(*hit));
197 
198  LocalPoint entryP = hit->entryPoint();
199  LocalPoint exitP = hit->exitPoint();
200  int partType = hit->particleType();
201  if (abs(partType) == 13)
202  num_musimhits++;
203 
204  if (wireId.station() == 1 && abs(partType) == 13)
205  meMB1_sim_occup_->Fill(wireId.wire());
206  if (wireId.station() == 2 && abs(partType) == 13)
207  meMB2_sim_occup_->Fill(wireId.wire());
208  if (wireId.station() == 3 && abs(partType) == 13)
209  meMB3_sim_occup_->Fill(wireId.wire());
210  if (wireId.station() == 4 && abs(partType) == 13)
211  meMB4_sim_occup_->Fill(wireId.wire());
212 
213  float path = (exitP - entryP).mag();
214  float path_x = fabs((exitP - entryP).x());
215 
216  hAllHits->Fill(entryP.x(),
217  exitP.x(),
218  entryP.y(),
219  exitP.y(),
220  entryP.z(),
221  exitP.z(),
222  path,
223  path_x,
224  partType,
225  hit->processType(),
226  hit->pabs());
227  }
228 
229  // cout << "num muon simhits " << num_musimhits << endl;
230 
232  for (detUnitIt = dtDigis->begin(); detUnitIt != dtDigis->end(); ++detUnitIt) {
233  const DTLayerId &id = (*detUnitIt).first;
234  const DTDigiCollection::Range &range = (*detUnitIt).second;
235 
236  num_digis_layer = 0;
237  cham_num = 0;
238  wire_touched = 0;
239 
240  // Loop over the digis of this DetUnit
241  for (DTDigiCollection::const_iterator digiIt = range.first; digiIt != range.second; ++digiIt) {
242  // cout<<" Wire: "<<(*digiIt).wire()<<endl
243  // <<" digi time (ns): "<<(*digiIt).time()<<endl;
244 
245  num_digis++;
246  num_digis_layer++;
247  if (num_digis_layer > 1) {
248  if ((*digiIt).wire() == wire_touched) {
249  meWire_DoubleDigi_->Fill((*digiIt).wire());
250  // cout << "old & new wire " << wire_touched << " " <<
251  // (*digiIt).wire() << endl;
252  }
253  }
254  wire_touched = (*digiIt).wire();
255 
256  meDigiTimeBox_->Fill((*digiIt).time());
257  if (id.wheel() == -2)
258  meDigiTimeBox_wheel2m_->Fill((*digiIt).time());
259  if (id.wheel() == -1)
260  meDigiTimeBox_wheel1m_->Fill((*digiIt).time());
261  if (id.wheel() == 0)
262  meDigiTimeBox_wheel0_->Fill((*digiIt).time());
263  if (id.wheel() == 1)
264  meDigiTimeBox_wheel1p_->Fill((*digiIt).time());
265  if (id.wheel() == 2)
266  meDigiTimeBox_wheel2p_->Fill((*digiIt).time());
267 
268  // Superlayer number and fill histo with digi timebox
269 
270  cham_num = (id.wheel() + 2) * 12 + (id.station() - 1) * 3 + id.superlayer();
271  // cout << " Histo number " << cham_num << endl;
272 
273  meDigiTimeBox_SL_[cham_num]->Fill((*digiIt).time());
274 
275  // cout << " size de digis " << (*digiIt).size() << endl;
276 
277  DTWireId wireId(id, (*digiIt).wire());
278  if (wireId.station() == 1)
279  meMB1_digi_occup_->Fill((*digiIt).wire());
280  if (wireId.station() == 2)
281  meMB2_digi_occup_->Fill((*digiIt).wire());
282  if (wireId.station() == 3)
283  meMB3_digi_occup_->Fill((*digiIt).wire());
284  if (wireId.station() == 4)
285  meMB4_digi_occup_->Fill((*digiIt).wire());
286 
287  int mu = 0;
288  float theta = 0;
289 
290  for (vector<const PSimHit *>::iterator hit = wireMap[wireId].begin(); hit != wireMap[wireId].end(); hit++)
291  if (abs((*hit)->particleType()) == 13) {
292  theta = atan((*hit)->momentumAtEntry().x() / (-(*hit)->momentumAtEntry().z())) * 180 / M_PI;
293  // cout<<"momentum x: "<<(*hit)->momentumAtEntry().x()<<endl
294  // <<"momentum z: "<<(*hit)->momentumAtEntry().z()<<endl
295  // <<"atan: "<<theta<<endl;
296  mu++;
297  }
298 
299  if (mu)
300  num_mudigis++;
301 
302  if (mu && theta) {
303  hDigis_global->Fill((*digiIt).time(), theta, id.superlayer());
304  // filling digi histos for wheel and for RZ and RPhi
305  WheelHistos(id.wheel())->Fill((*digiIt).time(), theta, id.superlayer());
306  }
307 
308  } // for digis in layer
309 
310  meDoubleDigi_->Fill((float)num_digis_layer);
311 
312  } // for layers
313 
314  // cout << "num_digis " << num_digis << "mu digis " << num_mudigis << endl;
315 
316  if (num_musimhits != 0) {
317  meDigiEfficiencyMu_->Fill((float)num_mudigis / (float)num_musimhits);
318  meDigiEfficiency_->Fill((float)num_digis / (float)num_musimhits);
319  }
320 
321  meSimvsDigi_->Fill((float)num_musimhits, (float)num_digis);
322  // cout<<"--------------"<<endl;
323 }
MonitorElement * meDoubleDigi_
Definition: MuonDTDigis.h:84
MonitorElement * meWire_DoubleDigi_
Definition: MuonDTDigis.h:86
std::vector< MonitorElement * > meDigiTimeBox_SL_
Definition: MuonDTDigis.h:97
T z() const
Definition: PV3DBase.h:61
MonitorElement * meMB2_digi_occup_
Definition: MuonDTDigis.h:91
edm::EDGetTokenT< DTDigiCollection > DigiToken_
Definition: MuonDTDigis.h:67
MonitorElement * meMB3_sim_occup_
Definition: MuonDTDigis.h:92
std::map< DTWireId, std::vector< const PSimHit * > > DTWireIdMap
Definition: MuonDTDigis.h:64
MonitorElement * meDigiEfficiencyMu_
Definition: MuonDTDigis.h:83
const DTGeometry * muonGeom
Definition: MuonDTDigis.h:70
std::unique_ptr< hDigis > hDigis_global
Definition: MuonDTDigis.h:103
MonitorElement * meDigiTimeBox_wheel2m_
Definition: MuonDTDigis.h:77
void Fill(long long x)
MonitorElement * meDigiTimeBox_wheel1m_
Definition: MuonDTDigis.h:78
MonitorElement * meDigiTimeBox_wheel0_
Definition: MuonDTDigis.h:79
T x() const
Definition: PV3DBase.h:59
T y() const
Definition: PV3DBase.h:60
edm::EDGetTokenT< edm::PSimHitContainer > SimHitToken_
Definition: MuonDTDigis.h:66
MonitorElement * meMB4_sim_occup_
Definition: MuonDTDigis.h:94
MonitorElement * meMB1_sim_occup_
Definition: MuonDTDigis.h:88
MonitorElement * meMB2_sim_occup_
Definition: MuonDTDigis.h:90
MonitorElement * meMB3_digi_occup_
Definition: MuonDTDigis.h:93
MonitorElement * meDigiTimeBox_
Definition: MuonDTDigis.h:76
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
MonitorElement * meDigiTimeBox_wheel1p_
Definition: MuonDTDigis.h:80
edm::ESGetToken< DTGeometry, MuonGeometryRecord > muonGeomToken_
Definition: MuonDTDigis.h:69
MonitorElement * meMB4_digi_occup_
Definition: MuonDTDigis.h:95
std::unique_ptr< hHits > hAllHits
Definition: MuonDTDigis.h:107
hDigis * WheelHistos(int wheel)
Definition: MuonDTDigis.cc:325
#define M_PI
MonitorElement * meSimvsDigi_
Definition: MuonDTDigis.h:85
T mag() const
The vector magnitude. Equivalent to sqrt(vec.mag2())
std::pair< const_iterator, const_iterator > Range
std::vector< DigiType >::const_iterator const_iterator
MonitorElement * meDigiEfficiency_
Definition: MuonDTDigis.h:82
void Fill(double time, double theta, int sltype)
Definition: Histograms.h:90
bool verbose_
Definition: MuonDTDigis.h:73
MonitorElement * meDigiTimeBox_wheel2p_
Definition: MuonDTDigis.h:81
Geom::Theta< T > theta() const
MonitorElement * meMB1_digi_occup_
Definition: MuonDTDigis.h:89

◆ bookHistograms()

void MuonDTDigis::bookHistograms ( DQMStore::IBooker iBooker,
edm::Run const &  iRun,
edm::EventSetup const &   
)
overrideprotectedvirtual

Implements DQMEDAnalyzer.

Definition at line 42 of file MuonDTDigis.cc.

References dqm::implementation::IBooker::book1D(), dqm::implementation::IBooker::book2D(), meDigiEfficiency_, meDigiEfficiencyMu_, meDigiHisto_, meDigiTimeBox_, meDigiTimeBox_SL_, meDigiTimeBox_wheel0_, meDigiTimeBox_wheel1m_, meDigiTimeBox_wheel1p_, meDigiTimeBox_wheel2m_, meDigiTimeBox_wheel2p_, meDoubleDigi_, meMB1_digi_occup_, meMB1_sim_occup_, meMB2_digi_occup_, meMB2_sim_occup_, meMB3_digi_occup_, meMB3_sim_occup_, meMB4_digi_occup_, meMB4_sim_occup_, meSimvsDigi_, meWire_DoubleDigi_, and dqm::implementation::NavigatorBase::setCurrentFolder().

44  {
45  meDigiTimeBox_ = nullptr;
46  meDigiTimeBox_wheel2m_ = nullptr;
47  meDigiTimeBox_wheel1m_ = nullptr;
48  meDigiTimeBox_wheel0_ = nullptr;
49  meDigiTimeBox_wheel1p_ = nullptr;
50  meDigiTimeBox_wheel2p_ = nullptr;
51  meDigiEfficiency_ = nullptr;
52  meDigiEfficiencyMu_ = nullptr;
53  meDoubleDigi_ = nullptr;
54  meSimvsDigi_ = nullptr;
55  meWire_DoubleDigi_ = nullptr;
56 
57  meMB1_sim_occup_ = nullptr;
58  meMB1_digi_occup_ = nullptr;
59  meMB2_sim_occup_ = nullptr;
60  meMB2_digi_occup_ = nullptr;
61  meMB3_sim_occup_ = nullptr;
62  meMB3_digi_occup_ = nullptr;
63  meMB4_sim_occup_ = nullptr;
64  meMB4_digi_occup_ = nullptr;
65 
66  meDigiHisto_ = nullptr;
67 
68  // ----------------------
69  // We go
70  // ----------------------
71 
72  Char_t histo_n[100];
73  Char_t histo_t[100];
74 
75  iBooker.setCurrentFolder("MuonDTDigisV/DTDigiValidationTask");
76 
77  sprintf(histo_n, "DigiTimeBox");
78  sprintf(histo_t, "Digi Time Box");
79  meDigiTimeBox_ = iBooker.book1D(histo_n, histo_t, 1536, 0, 1200);
80 
81  sprintf(histo_n, "DigiTimeBox_wheel2m");
82  sprintf(histo_t, "Digi Time Box wheel -2");
83  meDigiTimeBox_wheel2m_ = iBooker.book1D(histo_n, histo_t, 384, 0, 1200);
84 
85  sprintf(histo_n, "DigiTimeBox_wheel1m");
86  sprintf(histo_t, "Digi Time Box wheel -1");
87  meDigiTimeBox_wheel1m_ = iBooker.book1D(histo_n, histo_t, 384, 0, 1200);
88 
89  sprintf(histo_n, "DigiTimeBox_wheel0");
90  sprintf(histo_t, "Digi Time Box wheel 0");
91  meDigiTimeBox_wheel0_ = iBooker.book1D(histo_n, histo_t, 384, 0, 1200);
92 
93  sprintf(histo_n, "DigiTimeBox_wheel1p");
94  sprintf(histo_t, "Digi Time Box wheel 1");
95  meDigiTimeBox_wheel1p_ = iBooker.book1D(histo_n, histo_t, 384, 0, 1200);
96 
97  sprintf(histo_n, "DigiTimeBox_wheel2p");
98  sprintf(histo_t, "Digi Time Box wheel 2");
99  meDigiTimeBox_wheel2p_ = iBooker.book1D(histo_n, histo_t, 384, 0, 1200);
100 
101  sprintf(histo_n, "DigiEfficiencyMu");
102  sprintf(histo_t, "Ratio (#Digis Mu)/(#SimHits Mu)");
103  meDigiEfficiencyMu_ = iBooker.book1D(histo_n, histo_t, 100, 0., 5.);
104 
105  sprintf(histo_n, "DigiEfficiency");
106  sprintf(histo_t, "Ratio (#Digis)/(#SimHits)");
107  meDigiEfficiency_ = iBooker.book1D(histo_n, histo_t, 100, 0., 5.);
108 
109  sprintf(histo_n, "Number_Digi_per_layer");
110  sprintf(histo_t, "Number_Digi_per_layer");
111  meDoubleDigi_ = iBooker.book1D(histo_n, histo_t, 10, 0., 10.);
112 
113  sprintf(histo_n, "Number_simhit_vs_digi");
114  sprintf(histo_t, "Number_simhit_vs_digi");
115  meSimvsDigi_ = iBooker.book2D(histo_n, histo_t, 100, 0., 140., 100, 0., 140.);
116 
117  sprintf(histo_n, "Wire_Number_with_double_Digi");
118  sprintf(histo_t, "Wire_Number_with_double_Digi");
119  meWire_DoubleDigi_ = iBooker.book1D(histo_n, histo_t, 100, 0., 100.);
120 
121  sprintf(histo_n, "Simhit_occupancy_MB1");
122  sprintf(histo_t, "Simhit_occupancy_MB1");
123  meMB1_sim_occup_ = iBooker.book1D(histo_n, histo_t, 55, 0., 55.);
124 
125  sprintf(histo_n, "Digi_occupancy_MB1");
126  sprintf(histo_t, "Digi_occupancy_MB1");
127  meMB1_digi_occup_ = iBooker.book1D(histo_n, histo_t, 55, 0., 55.);
128 
129  sprintf(histo_n, "Simhit_occupancy_MB2");
130  sprintf(histo_t, "Simhit_occupancy_MB2");
131  meMB2_sim_occup_ = iBooker.book1D(histo_n, histo_t, 63, 0., 63.);
132 
133  sprintf(histo_n, "Digi_occupancy_MB2");
134  sprintf(histo_t, "Digi_occupancy_MB2");
135  meMB2_digi_occup_ = iBooker.book1D(histo_n, histo_t, 63, 0., 63.);
136 
137  sprintf(histo_n, "Simhit_occupancy_MB3");
138  sprintf(histo_t, "Simhit_occupancy_MB3");
139  meMB3_sim_occup_ = iBooker.book1D(histo_n, histo_t, 75, 0., 75.);
140 
141  sprintf(histo_n, "Digi_occupancy_MB3");
142  sprintf(histo_t, "Digi_occupancy_MB3");
143  meMB3_digi_occup_ = iBooker.book1D(histo_n, histo_t, 75, 0., 75.);
144 
145  sprintf(histo_n, "Simhit_occupancy_MB4");
146  sprintf(histo_t, "Simhit_occupancy_MB4");
147  meMB4_sim_occup_ = iBooker.book1D(histo_n, histo_t, 99, 0., 99.);
148 
149  sprintf(histo_n, "Digi_occupancy_MB4");
150  sprintf(histo_t, "Digi_occupancy_MB4");
151  meMB4_digi_occup_ = iBooker.book1D(histo_n, histo_t, 99, 0., 99.);
152 
153  // Begona's option
154  char stringcham[40];
155  for (int slnum = 1; slnum < 62; ++slnum) {
156  sprintf(stringcham, "DigiTimeBox_slid_%d", slnum);
157  meDigiHisto_ = iBooker.book1D(stringcham, stringcham, 100, 0, 1200);
158  meDigiTimeBox_SL_.push_back(meDigiHisto_);
159  }
160 }
MonitorElement * meDoubleDigi_
Definition: MuonDTDigis.h:84
MonitorElement * meWire_DoubleDigi_
Definition: MuonDTDigis.h:86
std::vector< MonitorElement * > meDigiTimeBox_SL_
Definition: MuonDTDigis.h:97
MonitorElement * meDigiHisto_
Definition: MuonDTDigis.h:98
virtual void setCurrentFolder(std::string const &fullpath)
Definition: DQMStore.cc:32
MonitorElement * meMB2_digi_occup_
Definition: MuonDTDigis.h:91
MonitorElement * meMB3_sim_occup_
Definition: MuonDTDigis.h:92
MonitorElement * meDigiEfficiencyMu_
Definition: MuonDTDigis.h:83
MonitorElement * meDigiTimeBox_wheel2m_
Definition: MuonDTDigis.h:77
MonitorElement * meDigiTimeBox_wheel1m_
Definition: MuonDTDigis.h:78
MonitorElement * meDigiTimeBox_wheel0_
Definition: MuonDTDigis.h:79
MonitorElement * meMB4_sim_occup_
Definition: MuonDTDigis.h:94
MonitorElement * meMB1_sim_occup_
Definition: MuonDTDigis.h:88
MonitorElement * meMB2_sim_occup_
Definition: MuonDTDigis.h:90
MonitorElement * meMB3_digi_occup_
Definition: MuonDTDigis.h:93
MonitorElement * meDigiTimeBox_
Definition: MuonDTDigis.h:76
MonitorElement * meDigiTimeBox_wheel1p_
Definition: MuonDTDigis.h:80
MonitorElement * meMB4_digi_occup_
Definition: MuonDTDigis.h:95
MonitorElement * meSimvsDigi_
Definition: MuonDTDigis.h:85
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:212
MonitorElement * meDigiEfficiency_
Definition: MuonDTDigis.h:82
MonitorElement * meDigiTimeBox_wheel2p_
Definition: MuonDTDigis.h:81
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
Definition: DQMStore.h:98
MonitorElement * meMB1_digi_occup_
Definition: MuonDTDigis.h:89

◆ WheelHistos()

hDigis * MuonDTDigis::WheelHistos ( int  wheel)
protected

Definition at line 325 of file MuonDTDigis.cc.

References funct::abs(), hDigis_W0, hDigis_W1, hDigis_W2, and makeMuonMisalignmentScenario::wheel.

Referenced by analyze().

325  {
326  switch (abs(wheel)) {
327  case 0:
328  return hDigis_W0.get();
329 
330  case 1:
331  return hDigis_W1.get();
332 
333  case 2:
334  return hDigis_W2.get();
335 
336  default:
337  return nullptr;
338  }
339 }
std::unique_ptr< hDigis > hDigis_W1
Definition: MuonDTDigis.h:105
std::unique_ptr< hDigis > hDigis_W0
Definition: MuonDTDigis.h:104
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
std::unique_ptr< hDigis > hDigis_W2
Definition: MuonDTDigis.h:106

Member Data Documentation

◆ DigiToken_

edm::EDGetTokenT<DTDigiCollection> MuonDTDigis::DigiToken_
private

Definition at line 67 of file MuonDTDigis.h.

Referenced by analyze(), and MuonDTDigis().

◆ hAllHits

std::unique_ptr<hHits> MuonDTDigis::hAllHits
private

Definition at line 107 of file MuonDTDigis.h.

Referenced by analyze(), and MuonDTDigis().

◆ hDigis_global

std::unique_ptr<hDigis> MuonDTDigis::hDigis_global
private

Definition at line 103 of file MuonDTDigis.h.

Referenced by analyze(), and MuonDTDigis().

◆ hDigis_W0

std::unique_ptr<hDigis> MuonDTDigis::hDigis_W0
private

Definition at line 104 of file MuonDTDigis.h.

Referenced by MuonDTDigis(), and WheelHistos().

◆ hDigis_W1

std::unique_ptr<hDigis> MuonDTDigis::hDigis_W1
private

Definition at line 105 of file MuonDTDigis.h.

Referenced by MuonDTDigis(), and WheelHistos().

◆ hDigis_W2

std::unique_ptr<hDigis> MuonDTDigis::hDigis_W2
private

Definition at line 106 of file MuonDTDigis.h.

Referenced by MuonDTDigis(), and WheelHistos().

◆ meDigiEfficiency_

MonitorElement* MuonDTDigis::meDigiEfficiency_
private

Definition at line 82 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meDigiEfficiencyMu_

MonitorElement* MuonDTDigis::meDigiEfficiencyMu_
private

Definition at line 83 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meDigiHisto_

MonitorElement* MuonDTDigis::meDigiHisto_
private

Definition at line 98 of file MuonDTDigis.h.

Referenced by bookHistograms().

◆ meDigiTimeBox_

MonitorElement* MuonDTDigis::meDigiTimeBox_
private

Definition at line 76 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meDigiTimeBox_SL_

std::vector<MonitorElement *> MuonDTDigis::meDigiTimeBox_SL_
private

Definition at line 97 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meDigiTimeBox_wheel0_

MonitorElement* MuonDTDigis::meDigiTimeBox_wheel0_
private

Definition at line 79 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meDigiTimeBox_wheel1m_

MonitorElement* MuonDTDigis::meDigiTimeBox_wheel1m_
private

Definition at line 78 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meDigiTimeBox_wheel1p_

MonitorElement* MuonDTDigis::meDigiTimeBox_wheel1p_
private

Definition at line 80 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meDigiTimeBox_wheel2m_

MonitorElement* MuonDTDigis::meDigiTimeBox_wheel2m_
private

Definition at line 77 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meDigiTimeBox_wheel2p_

MonitorElement* MuonDTDigis::meDigiTimeBox_wheel2p_
private

Definition at line 81 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meDoubleDigi_

MonitorElement* MuonDTDigis::meDoubleDigi_
private

Definition at line 84 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meMB1_digi_occup_

MonitorElement* MuonDTDigis::meMB1_digi_occup_
private

Definition at line 89 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meMB1_sim_occup_

MonitorElement* MuonDTDigis::meMB1_sim_occup_
private

Definition at line 88 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meMB2_digi_occup_

MonitorElement* MuonDTDigis::meMB2_digi_occup_
private

Definition at line 91 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meMB2_sim_occup_

MonitorElement* MuonDTDigis::meMB2_sim_occup_
private

Definition at line 90 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meMB3_digi_occup_

MonitorElement* MuonDTDigis::meMB3_digi_occup_
private

Definition at line 93 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meMB3_sim_occup_

MonitorElement* MuonDTDigis::meMB3_sim_occup_
private

Definition at line 92 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meMB4_digi_occup_

MonitorElement* MuonDTDigis::meMB4_digi_occup_
private

Definition at line 95 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meMB4_sim_occup_

MonitorElement* MuonDTDigis::meMB4_sim_occup_
private

Definition at line 94 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meSimvsDigi_

MonitorElement* MuonDTDigis::meSimvsDigi_
private

Definition at line 85 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ meWire_DoubleDigi_

MonitorElement* MuonDTDigis::meWire_DoubleDigi_
private

Definition at line 86 of file MuonDTDigis.h.

Referenced by analyze(), and bookHistograms().

◆ muonGeom

const DTGeometry* MuonDTDigis::muonGeom
private

Definition at line 70 of file MuonDTDigis.h.

Referenced by analyze().

◆ muonGeomToken_

edm::ESGetToken<DTGeometry, MuonGeometryRecord> MuonDTDigis::muonGeomToken_
private

Definition at line 69 of file MuonDTDigis.h.

Referenced by analyze().

◆ SimHitToken_

edm::EDGetTokenT<edm::PSimHitContainer> MuonDTDigis::SimHitToken_
private

Definition at line 66 of file MuonDTDigis.h.

Referenced by analyze(), and MuonDTDigis().

◆ verbose_

bool MuonDTDigis::verbose_
private

Definition at line 73 of file MuonDTDigis.h.

Referenced by analyze(), MuonDTDigis(), and ~MuonDTDigis().