CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
SiStripMonitorCluster.cc
Go to the documentation of this file.
1 // -*- C++ -*-
2 // Package: SiStripMonitorCluster
3 // Class: SiStripMonitorCluster
7 // Original Author: Dorian Kcira
8 // Created: Wed Feb 1 16:42:34 CET 2006
9 #include <cmath>
10 #include <fstream>
11 #include <numeric>
12 #include <vector>
17 
18 #include "TNamed.h"
19 
31 
34 
36 
37 #include <iostream>
38 #include "TMath.h"
39 
40 //--------------------------------------------------------------------------------------------
42  : conf_(iConfig),
43  show_mechanical_structure_view(true),
44  show_readout_view(false),
45  show_control_view(false),
46  select_all_detectors(false),
47  reset_each_run(false),
48  m_cacheID_(0),
49  qualityLabel_{conf_.getParameter<std::string>("StripQualityLabel")},
50  trackerTopologyRunToken_{esConsumes<TrackerTopology, TrackerTopologyRcd, edm::Transition::BeginRun>()},
51  tkDetMapToken_{esConsumes<TkDetMap, TrackerTopologyRcd, edm::Transition::BeginRun>()},
52  siStripDetCablingRunToken_{esConsumes<SiStripDetCabling, SiStripDetCablingRcd, edm::Transition::BeginRun>()},
53  trackerTopologyEventToken_{esConsumes<TrackerTopology, TrackerTopologyRcd>()},
54  siStripNoisesToken_{esConsumes<SiStripNoises, SiStripNoisesRcd>()},
55  siStripGainToken_{esConsumes<SiStripGain, SiStripGainRcd>()},
56  siStripQualityToken_{esConsumes<SiStripQuality, SiStripQualityRcd>(edm::ESInputTag("", qualityLabel_))},
57  siStripDetCablingEventToken_{esConsumes<SiStripDetCabling, SiStripDetCablingRcd>()} {
58  // initialize
59  passBPTXfilter_ = true;
60 
61  // initialize GenericTriggerEventFlag by specific configuration
62  // in this way, one can set specific selections for different MEs
64  new GenericTriggerEventFlag(iConfig.getParameter<edm::ParameterSet>("BPTXfilter"), consumesCollector(), *this);
66  iConfig.getParameter<edm::ParameterSet>("PixelDCSfilter"), consumesCollector(), *this);
68  iConfig.getParameter<edm::ParameterSet>("StripDCSfilter"), consumesCollector(), *this);
69 
70  firstEvent = -1;
71  eventNb = 0;
72 
73  // Detector Partitions
74  SubDetPhasePartMap["TIB"] = "TI";
75  SubDetPhasePartMap["TID__MINUS"] = "TI";
76  SubDetPhasePartMap["TID__PLUS"] = "TI";
77  SubDetPhasePartMap["TOB"] = "TO";
78  SubDetPhasePartMap["TEC__MINUS"] = "TM";
79  SubDetPhasePartMap["TEC__PLUS"] = "TP";
80 
81  // get on/off option for every cluster from cfi
82  edm::ParameterSet ParametersnClusters = conf_.getParameter<edm::ParameterSet>("TH1nClusters");
83  layerswitchncluson = ParametersnClusters.getParameter<bool>("layerswitchon");
84  moduleswitchncluson = ParametersnClusters.getParameter<bool>("moduleswitchon");
85 
86  edm::ParameterSet ParametersClusterCharge = conf_.getParameter<edm::ParameterSet>("TH1ClusterCharge");
87  layerswitchcluschargeon = ParametersClusterCharge.getParameter<bool>("layerswitchon");
88  moduleswitchcluschargeon = ParametersClusterCharge.getParameter<bool>("moduleswitchon");
89  subdetswitchcluschargeon = ParametersClusterCharge.getParameter<bool>("subdetswitchon");
90 
91  edm::ParameterSet ParametersClusterStoN = conf_.getParameter<edm::ParameterSet>("TH1ClusterStoN");
92  layerswitchclusstonon = ParametersClusterStoN.getParameter<bool>("layerswitchon");
93  moduleswitchclusstonon = ParametersClusterStoN.getParameter<bool>("moduleswitchon");
94 
95  edm::ParameterSet ParametersClusterStoNVsPos = conf_.getParameter<edm::ParameterSet>("TH1ClusterStoNVsPos");
96  layerswitchclusstonVsposon = ParametersClusterStoNVsPos.getParameter<bool>("layerswitchon");
97  moduleswitchclusstonVsposon = ParametersClusterStoNVsPos.getParameter<bool>("moduleswitchon");
98 
99  edm::ParameterSet ParametersClusterPos = conf_.getParameter<edm::ParameterSet>("TH1ClusterPos");
100  layerswitchclusposon = ParametersClusterPos.getParameter<bool>("layerswitchon");
101  moduleswitchclusposon = ParametersClusterPos.getParameter<bool>("moduleswitchon");
102 
103  edm::ParameterSet ParametersClusterDigiPos = conf_.getParameter<edm::ParameterSet>("TH1ClusterDigiPos");
104  layerswitchclusdigiposon = ParametersClusterDigiPos.getParameter<bool>("layerswitchon");
105  moduleswitchclusdigiposon = ParametersClusterDigiPos.getParameter<bool>("moduleswitchon");
106 
107  edm::ParameterSet ParametersClusterNoise = conf_.getParameter<edm::ParameterSet>("TH1ClusterNoise");
108  layerswitchclusnoiseon = ParametersClusterNoise.getParameter<bool>("layerswitchon");
109  moduleswitchclusnoiseon = ParametersClusterNoise.getParameter<bool>("moduleswitchon");
110 
111  edm::ParameterSet ParametersClusterWidth = conf_.getParameter<edm::ParameterSet>("TH1ClusterWidth");
112  layerswitchcluswidthon = ParametersClusterWidth.getParameter<bool>("layerswitchon");
113  moduleswitchcluswidthon = ParametersClusterWidth.getParameter<bool>("moduleswitchon");
114  subdetswitchcluswidthon = ParametersClusterWidth.getParameter<bool>("subdetswitchon");
115 
116  edm::ParameterSet ParametersModuleLocalOccupancy = conf_.getParameter<edm::ParameterSet>("TH1ModuleLocalOccupancy");
117  layerswitchlocaloccupancy = ParametersModuleLocalOccupancy.getParameter<bool>("layerswitchon");
118  moduleswitchlocaloccupancy = ParametersModuleLocalOccupancy.getParameter<bool>("moduleswitchon");
119 
120  edm::ParameterSet ParametersNrOfClusterizedStrips = conf_.getParameter<edm::ParameterSet>("TH1NrOfClusterizedStrips");
121  layerswitchnrclusterizedstrip = ParametersNrOfClusterizedStrips.getParameter<bool>("layerswitchon");
122  moduleswitchnrclusterizedstrip = ParametersNrOfClusterizedStrips.getParameter<bool>("moduleswitchon");
123 
124  edm::ParameterSet ParametersClusterProf = conf_.getParameter<edm::ParameterSet>("TProfNumberOfCluster");
125  layerswitchnumclusterprofon = ParametersClusterProf.getParameter<bool>("layerswitchon");
126 
127  edm::ParameterSet ParametersClusterWidthProf = conf_.getParameter<edm::ParameterSet>("TProfClusterWidth");
128  layerswitchclusterwidthprofon = ParametersClusterWidthProf.getParameter<bool>("layerswitchon");
129 
130  edm::ParameterSet ParametersTotClusterProf = conf_.getParameter<edm::ParameterSet>("TProfTotalNumberOfClusters");
131  subdetswitchtotclusprofon = ParametersTotClusterProf.getParameter<bool>("subdetswitchon");
132 
133  edm::ParameterSet ParametersTotClusterTH1 = conf_.getParameter<edm::ParameterSet>("TH1TotalNumberOfClusters");
134  subdetswitchtotclusth1on = ParametersTotClusterTH1.getParameter<bool>("subdetswitchon");
135 
136  edm::ParameterSet ParametersClusterApvProf = conf_.getParameter<edm::ParameterSet>("TProfClustersApvCycle");
137  subdetswitchapvcycleprofon = ParametersClusterApvProf.getParameter<bool>("subdetswitchon");
138 
139  edm::ParameterSet ParametersClustersApvTH2 = conf_.getParameter<edm::ParameterSet>("TH2ClustersApvCycle");
140  subdetswitchapvcycleth2on = ParametersClustersApvTH2.getParameter<bool>("subdetswitchon");
141 
142  edm::ParameterSet ParametersApvCycleDBxProf2 = conf_.getParameter<edm::ParameterSet>("TProf2ApvCycleVsDBx");
143  subdetswitchapvcycledbxprof2on = ParametersApvCycleDBxProf2.getParameter<bool>("subdetswitchon");
144 
145  edm::ParameterSet ParametersDBxCycleProf = conf_.getParameter<edm::ParameterSet>("TProfClustersVsDBxCycle");
146  subdetswitchdbxcycleprofon = ParametersDBxCycleProf.getParameter<bool>("subdetswitchon");
147 
148  edm::ParameterSet ParametersCStripVsCPix = conf_.getParameter<edm::ParameterSet>("TH2CStripVsCpixel");
149  globalswitchcstripvscpix = ParametersCStripVsCPix.getParameter<bool>("globalswitchon");
150 
151  edm::ParameterSet ParametersMultiplicityRegionsTH1 = conf_.getParameter<edm::ParameterSet>("TH1MultiplicityRegions");
152  globalswitchMultiRegions = ParametersMultiplicityRegionsTH1.getParameter<bool>("globalswitchon");
153 
154  edm::ParameterSet ParametersApvCycleVsDBxGlobalTH2 = conf_.getParameter<edm::ParameterSet>("TH2ApvCycleVsDBxGlobal");
155  globalswitchapvcycledbxth2on = ParametersApvCycleVsDBxGlobalTH2.getParameter<bool>("globalswitchon");
156 
157  edm::ParameterSet ParametersNoiseStrip2ApvCycle = conf_.getParameter<edm::ParameterSet>("TH1StripNoise2ApvCycle");
158  globalswitchstripnoise2apvcycle = ParametersNoiseStrip2ApvCycle.getParameter<bool>("globalswitchon");
159 
160  edm::ParameterSet ParametersNoiseStrip3ApvCycle = conf_.getParameter<edm::ParameterSet>("TH1StripNoise3ApvCycle");
161  globalswitchstripnoise3apvcycle = ParametersNoiseStrip3ApvCycle.getParameter<bool>("globalswitchon");
162 
163  edm::ParameterSet ParametersMainDiagonalPosition = conf_.getParameter<edm::ParameterSet>("TH1MainDiagonalPosition");
164  globalswitchmaindiagonalposition = ParametersMainDiagonalPosition.getParameter<bool>("globalswitchon");
165 
166  edm::ParameterSet ClusterMultiplicityRegions = conf_.getParameter<edm::ParameterSet>("MultiplicityRegions");
167  k0 = ClusterMultiplicityRegions.getParameter<double>("k0");
168  q0 = ClusterMultiplicityRegions.getParameter<double>("q0");
169  dk0 = ClusterMultiplicityRegions.getParameter<double>("dk0");
170  maxClus = ClusterMultiplicityRegions.getParameter<double>("MaxClus");
171  minPix = ClusterMultiplicityRegions.getParameter<double>("MinPix");
172 
173  edm::ParameterSet ParametersNclusVsCycleTimeProf2D = conf_.getParameter<edm::ParameterSet>("NclusVsCycleTimeProf2D");
174  globalswitchnclusvscycletimeprof2don = ParametersNclusVsCycleTimeProf2D.getParameter<bool>("globalswitchon");
175 
176  edm::ParameterSet ParametersFEDCluster = conf_.getParameter<edm::ParameterSet>("TProfNClustersFED");
177  globalswitchFEDCluster = ParametersFEDCluster.getParameter<bool>("globalswitchon");
178 
179  edm::ParameterSet ParametersClusWidthVsAmpTH2 = conf_.getParameter<edm::ParameterSet>("ClusWidthVsAmpTH2");
180  clusterWidth_vs_amplitude_on = ParametersClusWidthVsAmpTH2.getParameter<bool>("globalswitchon");
181  layer_clusterWidth_vs_amplitude_on = ParametersClusWidthVsAmpTH2.getParameter<bool>("layerswitchon");
182  subdet_clusterWidth_vs_amplitude_on = ParametersClusWidthVsAmpTH2.getParameter<bool>("subdetswitchon");
183  module_clusterWidth_vs_amplitude_on = ParametersClusWidthVsAmpTH2.getParameter<bool>("moduleswitchon");
184 
185  clustertkhistomapon = conf_.getParameter<bool>("TkHistoMap_On");
186  clusterchtkhistomapon = conf_.getParameter<bool>("ClusterChTkHistoMap_On");
187  createTrendMEs = conf_.getParameter<bool>("CreateTrendMEs");
188  trendVs10Ls_ = conf_.getParameter<bool>("TrendVs10LS");
189  Mod_On_ = conf_.getParameter<bool>("Mod_On");
190  ClusterHisto_ = conf_.getParameter<bool>("ClusterHisto");
191 
192  topFolderName_ = conf_.getParameter<std::string>("TopFolderName");
193 
194  // Poducer name of input StripClusterCollection
196  consumes<edmNew::DetSetVector<SiStripCluster> >(conf_.getParameter<edm::InputTag>("ClusterProducerStrip"));
198  consumes<edmNew::DetSetVector<SiPixelCluster> >(conf_.getParameter<edm::InputTag>("ClusterProducerPix"));
199  /*
200  clusterProducerStrip_ =
201  conf_.getParameter<edm::InputTag>("ClusterProducerStrip"); clusterProducerPix_
202  = conf_.getParameter<edm::InputTag>("ClusterProducerPix");
203  */
204  // cluster quality conditions
205  edm::ParameterSet cluster_condition = conf_.getParameter<edm::ParameterSet>("ClusterConditions");
206  applyClusterQuality_ = cluster_condition.getParameter<bool>("On");
207  sToNLowerLimit_ = cluster_condition.getParameter<double>("minStoN");
208  sToNUpperLimit_ = cluster_condition.getParameter<double>("maxStoN");
209  widthLowerLimit_ = cluster_condition.getParameter<double>("minWidth");
210  widthUpperLimit_ = cluster_condition.getParameter<double>("maxWidth");
211 
212  // Event History Producer
213  // historyProducer_ = conf_.getParameter<edm::InputTag>("HistoryProducer");
214  historyProducerToken_ = consumes<EventWithHistory>(conf_.getParameter<edm::InputTag>("HistoryProducer"));
215  // Apv Phase Producer
216  // apvPhaseProducer_ = conf_.getParameter<edm::InputTag>("ApvPhaseProducer");
217  apvPhaseProducerToken_ = consumes<APVCyclePhaseCollection>(conf_.getParameter<edm::InputTag>("ApvPhaseProducer"));
218  // Create DCS Status
219  bool checkDCS = conf_.getParameter<bool>("UseDCSFiltering");
220  if (checkDCS)
221  dcsStatus_ = new SiStripDCSStatus(consumesCollector());
222  else
223  dcsStatus_ = nullptr;
224 }
225 
227  if (dcsStatus_)
228  delete dcsStatus_;
235 }
236 
237 //--------------------------------------------------------------------------------------------
239  // Initialize the GenericTriggerEventFlag
246 }
247 
248 //--------------------------------------------------------------------------------------------
251  const TrackerTopology* const tTopo = &es.getData(trackerTopologyRunToken_);
252  const TkDetMap* tkDetMap = &es.getData(tkDetMapToken_);
253  const SiStripDetCabling& siStripDetCabling = es.getData(siStripDetCablingRunToken_);
254 
255  // get list of active detectors from SiStripDetCabling
256  std::vector<uint32_t> activeDets;
257  siStripDetCabling.addActiveDetectorsRawIds(activeDets);
258 
260  folder_organizer.setSiStripFolderName(topFolderName_);
261  folder_organizer.setSiStripFolder();
262 
263  // Create TkHistoMap for Cluster
264  if (clustertkhistomapon) {
265  // std::cout << "[SiStripMonitorCluster::createMEs] topFolderName_: "
266  // << topFolderName_ << " ";
267  if ((topFolderName_ == "SiStrip") or (std::string::npos != topFolderName_.find("HLT")))
268  tkmapcluster =
269  std::make_unique<TkHistoMap>(tkDetMap, ibooker, topFolderName_, "TkHMap_NumberOfCluster", 0., true);
270  else
271  tkmapcluster = std::make_unique<TkHistoMap>(
272  tkDetMap, ibooker, topFolderName_ + "/TkHistoMap", "TkHMap_NumberOfCluster", 0., false);
273  }
274  if (clusterchtkhistomapon) {
275  if ((topFolderName_ == "SiStrip") or (std::string::npos != topFolderName_.find("HLT")))
277  std::make_unique<TkHistoMap>(tkDetMap, ibooker, topFolderName_, "TkHMap_ClusterCharge", 0., true);
278  else
279  tkmapclusterch = std::make_unique<TkHistoMap>(
280  tkDetMap, ibooker, topFolderName_ + "/TkHistoMap", "TkHMap_ClusterCharge", 0., false);
281  }
282 
283  // loop over detectors and book MEs
284  edm::LogInfo("SiStripTkDQM|SiStripMonitorCluster") << "nr. of activeDets: " << activeDets.size();
285  for (std::vector<uint32_t>::iterator detid_iterator = activeDets.begin(); detid_iterator != activeDets.end();
286  detid_iterator++) {
287  uint32_t detid = (*detid_iterator);
288  // remove any eventual zero elements - there should be none, but just in
289  // case
290  if (detid == 0) {
291  activeDets.erase(detid_iterator);
292  continue;
293  }
294 
295  if (Mod_On_) {
296  ModMEs mod_single;
297  // set appropriate folder using SiStripFolderOrganizer
298  folder_organizer.setDetectorFolder(detid, tTopo); // pass the detid to this method
299  if (reset_each_run)
300  ResetModuleMEs(detid);
301  createModuleMEs(mod_single, detid, ibooker, siStripDetCabling);
302  // append to ModuleMEsMap
303  ModuleMEsMap.insert(std::make_pair(detid, mod_single));
304  }
305 
306  // Create Layer Level MEs if they are not created already
307  std::pair<std::string, int32_t> det_layer_pair = folder_organizer.GetSubDetAndLayer(detid, tTopo);
309  std::string label = hidmanager.getSubdetid(detid, tTopo, false);
310 
311  std::map<std::string, LayerMEs>::iterator iLayerME = LayerMEsMap.find(label);
312  if (iLayerME == LayerMEsMap.end()) {
313  // get detids for the layer
314  int32_t lnumber = det_layer_pair.second;
315  std::vector<uint32_t> layerDetIds;
316  if (det_layer_pair.first == "TIB") {
317  SiStripSubStructure::getTIBDetectors(activeDets, layerDetIds, tTopo, lnumber, 0, 0, 0);
318  } else if (det_layer_pair.first == "TOB") {
319  SiStripSubStructure::getTOBDetectors(activeDets, layerDetIds, tTopo, lnumber, 0, 0);
320  } else if (det_layer_pair.first == "TID" && lnumber > 0) {
321  SiStripSubStructure::getTIDDetectors(activeDets, layerDetIds, tTopo, 2, std::abs(lnumber), 0, 0);
322  } else if (det_layer_pair.first == "TID" && lnumber < 0) {
323  SiStripSubStructure::getTIDDetectors(activeDets, layerDetIds, tTopo, 1, std::abs(lnumber), 0, 0);
324  } else if (det_layer_pair.first == "TEC" && lnumber > 0) {
325  SiStripSubStructure::getTECDetectors(activeDets, layerDetIds, tTopo, 2, std::abs(lnumber), 0, 0, 0, 0);
326  } else if (det_layer_pair.first == "TEC" && lnumber < 0) {
327  SiStripSubStructure::getTECDetectors(activeDets, layerDetIds, tTopo, 1, std::abs(lnumber), 0, 0, 0, 0);
328  }
329  LayerDetMap[label] = layerDetIds;
330 
331  // book Layer MEs
332  folder_organizer.setLayerFolder(detid, tTopo, det_layer_pair.second);
333  createLayerMEs(label, layerDetIds.size(), ibooker);
334  }
335  // book sub-detector plots
336  auto sdet_pair = folder_organizer.getSubDetFolderAndTag(detid, tTopo);
337  if (SubDetMEsMap.find(sdet_pair.second) == SubDetMEsMap.end()) {
338  ibooker.setCurrentFolder(sdet_pair.first);
339 
340  createSubDetMEs(sdet_pair.second, ibooker);
341  }
342  } // end of loop over detectors
343 
344  // Create Global Histogram
346  ibooker.setCurrentFolder(topFolderName_ + "/MechanicalView/");
347  edm::ParameterSet GlobalTH2Parameters = conf_.getParameter<edm::ParameterSet>("TH2ApvCycleVsDBxGlobal");
348  std::string HistoName = "DeltaBx_vs_ApvCycle";
349  GlobalApvCycleDBxTH2 = ibooker.book2D(HistoName,
350  HistoName,
351  GlobalTH2Parameters.getParameter<int32_t>("Nbinsx"),
352  GlobalTH2Parameters.getParameter<double>("xmin"),
353  GlobalTH2Parameters.getParameter<double>("xmax"),
354  GlobalTH2Parameters.getParameter<int32_t>("Nbinsy"),
355  GlobalTH2Parameters.getParameter<double>("ymin"),
356  GlobalTH2Parameters.getParameter<double>("ymax"));
357  GlobalApvCycleDBxTH2->setAxisTitle("APV Cycle (Corrected Absolute Bx % 70)", 1);
358  GlobalApvCycleDBxTH2->setAxisTitle("Delta Bunch Crossing Cycle", 2);
359 
360  // plot DeltaBX ***************************
361  edm::ParameterSet GlobalTH1Parameters = conf_.getParameter<edm::ParameterSet>("TH1DBxGlobal");
362  HistoName = "DeltaBx";
363  GlobalDBxTH1 = ibooker.book1D(HistoName,
364  HistoName,
365  GlobalTH1Parameters.getParameter<int32_t>("Nbinsx"),
366  GlobalTH1Parameters.getParameter<double>("xmin"),
367  GlobalTH1Parameters.getParameter<double>("xmax"));
368  GlobalDBxTH1->setAxisTitle("Delta Bunch Crossing", 1);
369 
370  // plot DeltaBXCycle ***************************
371  edm::ParameterSet DBxCycle = conf_.getParameter<edm::ParameterSet>("TH1DBxCycleGlobal");
372  HistoName = "DeltaBxCycle";
373  GlobalDBxCycleTH1 = ibooker.book1D(HistoName,
374  HistoName,
375  DBxCycle.getParameter<int32_t>("Nbinsx"),
376  DBxCycle.getParameter<double>("xmin"),
377  DBxCycle.getParameter<double>("xmax"));
378  GlobalDBxCycleTH1->setAxisTitle("Delta Bunch Crossing Cycle", 1);
379  }
380 
382  ibooker.setCurrentFolder(topFolderName_ + "/MechanicalView/");
383  edm::ParameterSet GlobalTH2Parameters = conf_.getParameter<edm::ParameterSet>("TH2CStripVsCpixel");
384  std::string HistoName = "StripClusVsPixClus";
385  GlobalCStripVsCpix = ibooker.book2D(HistoName,
386  HistoName,
387  GlobalTH2Parameters.getParameter<int32_t>("Nbinsx"),
388  GlobalTH2Parameters.getParameter<double>("xmin"),
389  GlobalTH2Parameters.getParameter<double>("xmax"),
390  GlobalTH2Parameters.getParameter<int32_t>("Nbinsy"),
391  GlobalTH2Parameters.getParameter<double>("ymin"),
392  GlobalTH2Parameters.getParameter<double>("ymax"));
393  GlobalCStripVsCpix->setAxisTitle("Strip Clusters", 1);
394  GlobalCStripVsCpix->setAxisTitle("Pix Clusters", 2);
395 
396  // Absolute Bunch Crossing ***********************
397  edm::ParameterSet GlobalTH1Parameters = conf_.getParameter<edm::ParameterSet>("TH1ABx_CSCP");
398  HistoName = "AbsoluteBx_CStripVsCpixel";
399  GlobalABXTH1_CSCP = ibooker.book1D(HistoName,
400  HistoName,
401  GlobalTH1Parameters.getParameter<int32_t>("Nbinsx"),
402  GlobalTH1Parameters.getParameter<double>("xmin"),
403  GlobalTH1Parameters.getParameter<double>("xmax"));
404  GlobalABXTH1_CSCP->setAxisTitle("Absolute Bunch Crossing", 1);
405  }
406 
408  ibooker.setCurrentFolder(topFolderName_ + "/MechanicalView/");
409  edm::ParameterSet GlobalTH2Parameters = conf_.getParameter<edm::ParameterSet>("TH1MultiplicityRegions");
410  std::string HistoName = "ClusterMultiplicityRegions";
411  PixVsStripMultiplicityRegions = ibooker.book1D(HistoName,
412  HistoName,
413  GlobalTH2Parameters.getParameter<int32_t>("Nbinx"),
414  GlobalTH2Parameters.getParameter<double>("xmin"),
415  GlobalTH2Parameters.getParameter<double>("xmax"));
417  PixVsStripMultiplicityRegions->setBinLabel(1, "Main Diagonal");
418  PixVsStripMultiplicityRegions->setBinLabel(2, "Strip Noise");
419  PixVsStripMultiplicityRegions->setBinLabel(3, "High Strip Noise");
420  PixVsStripMultiplicityRegions->setBinLabel(4, "Beam Background");
421  PixVsStripMultiplicityRegions->setBinLabel(5, "No Strip Clusters");
422  }
423 
425  ibooker.setCurrentFolder(topFolderName_ + "/MechanicalView/");
426  edm::ParameterSet GlobalTH1Parameters = conf_.getParameter<edm::ParameterSet>("TH1MainDiagonalPosition");
427  std::string HistoName = "MainDiagonal Position";
428  GlobalMainDiagonalPosition = ibooker.book1D(HistoName,
429  HistoName,
430  GlobalTH1Parameters.getParameter<int32_t>("Nbinsx"),
431  GlobalTH1Parameters.getParameter<double>("xmin"),
432  GlobalTH1Parameters.getParameter<double>("xmax"));
433  GlobalMainDiagonalPosition->setAxisTitle("atan(NPix/(k*NStrip))");
434 
435  // PLOT MainDiagonalPosition_vs_BX ***************************
436  edm::ParameterSet GlobalTProfParameters = conf_.getParameter<edm::ParameterSet>("TProfMainDiagonalPosition");
437  HistoName = "MainDiagonalPosition_vs_BX";
438  GlobalMainDiagonalPosition_vs_BX = ibooker.bookProfile(HistoName,
439  HistoName,
440  GlobalTProfParameters.getParameter<int32_t>("Nbinsx"),
441  GlobalTProfParameters.getParameter<double>("xmin"),
442  GlobalTProfParameters.getParameter<double>("xmax"),
443  GlobalTProfParameters.getParameter<int32_t>("Nbinsy"),
444  GlobalTProfParameters.getParameter<double>("ymin"),
445  GlobalTProfParameters.getParameter<double>("ymax"));
446 
448  GlobalMainDiagonalPosition_vs_BX->setAxisTitle("tan^{-1}(NPix/k*NStrip))", 2);
449 
450  edm::ParameterSet GlobalTH2Parameters = conf_.getParameter<edm::ParameterSet>("TH2MainDiagonalPosition");
451  HistoName = "TH2MainDiagonalPosition_vs_BX";
452  GlobalTH2MainDiagonalPosition_vs_BX = ibooker.book2D(HistoName,
453  HistoName,
454  GlobalTH2Parameters.getParameter<int32_t>("Nbinsx"),
455  GlobalTH2Parameters.getParameter<double>("xmin"),
456  GlobalTH2Parameters.getParameter<double>("xmax"),
457  GlobalTH2Parameters.getParameter<int32_t>("Nbinsy"),
458  GlobalTH2Parameters.getParameter<double>("ymin"),
459  GlobalTH2Parameters.getParameter<double>("ymax"));
461  GlobalTH2MainDiagonalPosition_vs_BX->setAxisTitle("tan^{-1}(NPix/k*NStrip))", 2);
462  }
463 
464  // TO BE ADDED !!!
465  /*
466  if ( globalswitchapvcycledbxth2on or globalswitchcstripvscpix or
467  globalswitchMultiRegions or ClusterHisto_ ) {
468  ibooker.setCurrentFolder(topFolderName_+"/MechanicalView/");
469  std::string HistoName = "BPTX rate";
470  BPTXrateTrend = ibooker.bookProfile(HistoName,HistoName, LSBin, LSMin,
471  LSMax, 0, 10000.,""); BPTXrateTrend->getTH1()->SetCanExtend(TH1::kAllAxes);
472  BPTXrateTrend->setAxisTitle("#Lumi section",1);
473  BPTXrateTrend->setAxisTitle("Number of BPTX events per LS",2);
474  }
475  */
476 
478  ibooker.setCurrentFolder(topFolderName_ + "/MechanicalView/");
479  edm::ParameterSet GlobalTH1Parameters = conf_.getParameter<edm::ParameterSet>("TH1StripNoise2ApvCycle");
480  std::string HistoName = "StripNoise_ApvCycle";
481  StripNoise2Cycle = ibooker.book1D(HistoName,
482  HistoName,
483  GlobalTH1Parameters.getParameter<int32_t>("Nbinsx"),
484  GlobalTH1Parameters.getParameter<double>("xmin"),
485  GlobalTH1Parameters.getParameter<double>("xmax"));
486  StripNoise2Cycle->setAxisTitle("APV Cycle");
487  }
488 
490  ibooker.setCurrentFolder(topFolderName_ + "/MechanicalView/");
491  edm::ParameterSet GlobalTH1Parameters = conf_.getParameter<edm::ParameterSet>("TH1StripNoise3ApvCycle");
492  std::string HistoName = "HighStripNoise_ApvCycle";
493  StripNoise3Cycle = ibooker.book1D(HistoName,
494  HistoName,
495  GlobalTH1Parameters.getParameter<int32_t>("Nbinsx"),
496  GlobalTH1Parameters.getParameter<double>("xmin"),
497  GlobalTH1Parameters.getParameter<double>("xmax"));
498  StripNoise3Cycle->setAxisTitle("APV Cycle");
499  }
500 
502  const char* HistoName = "StripClusVsBXandOrbit";
503  const char* HistoTitle =
504  "Strip cluster multiplicity vs BX mod(70) and Orbit;Event 1 BX "
505  "mod(70);time [Orb#]";
506  edm::ParameterSet ParametersNclusVsCycleTimeProf2D =
507  conf_.getParameter<edm::ParameterSet>("NclusVsCycleTimeProf2D");
508  NclusVsCycleTimeProf2D = ibooker.bookProfile2D(HistoName,
509  HistoTitle,
510  ParametersNclusVsCycleTimeProf2D.getParameter<int32_t>("Nbins"),
511  ParametersNclusVsCycleTimeProf2D.getParameter<double>("xmin"),
512  ParametersNclusVsCycleTimeProf2D.getParameter<double>("xmax"),
513  ParametersNclusVsCycleTimeProf2D.getParameter<int32_t>("Nbinsy"),
514  ParametersNclusVsCycleTimeProf2D.getParameter<double>("ymin"),
515  ParametersNclusVsCycleTimeProf2D.getParameter<double>("ymax"),
516  0,
517  0);
518  if (NclusVsCycleTimeProf2D->kind() == MonitorElement::Kind::TPROFILE2D)
519  NclusVsCycleTimeProf2D->setCanExtend(TH1::kAllAxes);
520  }
522  ibooker.setCurrentFolder(topFolderName_ + "/MechanicalView/");
523  edm::ParameterSet ParametersClusWidthVsAmpTH2 = conf_.getParameter<edm::ParameterSet>("ClusWidthVsAmpTH2");
524  const char* HistoName = "ClusterWidths_vs_Amplitudes";
525  const char* HistoTitle =
526  "Cluster widths vs amplitudes;Amplitudes (integrated ADC "
527  "counts);Cluster widths";
528  ClusWidthVsAmpTH2 = ibooker.book2D(HistoName,
529  HistoTitle,
530  ParametersClusWidthVsAmpTH2.getParameter<int32_t>("Nbinsx"),
531  ParametersClusWidthVsAmpTH2.getParameter<double>("xmin"),
532  ParametersClusWidthVsAmpTH2.getParameter<double>("xmax"),
533  ParametersClusWidthVsAmpTH2.getParameter<int32_t>("Nbinsy"),
534  ParametersClusWidthVsAmpTH2.getParameter<double>("ymin"),
535  ParametersClusWidthVsAmpTH2.getParameter<double>("ymax"));
536  }
537 
538  if (ClusterHisto_) {
539  ibooker.setCurrentFolder(topFolderName_ + "/MechanicalView/");
540  edm::ParameterSet PixelCluster = conf_.getParameter<edm::ParameterSet>("TH1NClusPx");
541  std::string HistoName = "NumberOfClustersInPixel";
542  NumberOfPixelClus = ibooker.book1D(HistoName,
543  HistoName,
544  PixelCluster.getParameter<int32_t>("Nbinsx"),
545  PixelCluster.getParameter<double>("xmin"),
546  PixelCluster.getParameter<double>("xmax"));
547  NumberOfPixelClus->setAxisTitle("# of Clusters in Pixel", 1);
548  NumberOfPixelClus->setAxisTitle("Number of Events", 2);
549  //
550  edm::ParameterSet StripCluster = conf_.getParameter<edm::ParameterSet>("TH1NClusStrip");
551  HistoName = "NumberOfClustersInStrip";
552  NumberOfStripClus = ibooker.book1D(HistoName,
553  HistoName,
554  StripCluster.getParameter<int32_t>("Nbinsx"),
555  StripCluster.getParameter<double>("xmin"),
556  StripCluster.getParameter<double>("xmax"));
557  NumberOfStripClus->setAxisTitle("# of Clusters in Strip", 1);
558  NumberOfStripClus->setAxisTitle("Number of Events", 2);
559 
560  // NumberOfClustersinStrip vs BX PLOT ****************************
561  edm::ParameterSet StripClusterBX = conf_.getParameter<edm::ParameterSet>("TProfNClusStrip");
562  HistoName = "NumberOfClustersInStrip_vs_BX";
563  NumberOfStripClus_vs_BX = ibooker.bookProfile(HistoName,
564  HistoName,
565  StripClusterBX.getParameter<int32_t>("Nbinsx"),
566  StripClusterBX.getParameter<double>("xmin"),
567  StripClusterBX.getParameter<double>("xmax"),
568  StripClusterBX.getParameter<int32_t>("Nbinsy"),
569  StripClusterBX.getParameter<double>("ymin"),
570  StripClusterBX.getParameter<double>("ymax"));
571 
572  NumberOfStripClus_vs_BX->setAxisTitle("Absolute BX", 1);
573  NumberOfStripClus_vs_BX->setAxisTitle("# of Clusters in Strip", 2);
574 
575  // NumberOfClustersinStrip vs BX PLOT ****************************
576  edm::ParameterSet PixelClusterBX = conf_.getParameter<edm::ParameterSet>("TProfNClusPixel");
577  HistoName = "NumberOfClustersInPixel_vs_BX";
578  NumberOfPixelClus_vs_BX = ibooker.bookProfile(HistoName,
579  HistoName,
580  PixelClusterBX.getParameter<int32_t>("Nbinsx"),
581  PixelClusterBX.getParameter<double>("xmin"),
582  PixelClusterBX.getParameter<double>("xmax"),
583  PixelClusterBX.getParameter<int32_t>("Nbinsy"),
584  PixelClusterBX.getParameter<double>("ymin"),
585  PixelClusterBX.getParameter<double>("ymax"));
586 
587  NumberOfPixelClus_vs_BX->setAxisTitle("Absolute BX", 1);
588  NumberOfPixelClus_vs_BX->setAxisTitle("# of Clusters in Pixel", 2);
589 
591  // Number of clusters per FED
592  edm::ParameterSet FEDCluster = conf_.getParameter<edm::ParameterSet>("TProfNClustersFED");
593  HistoName = "NumberOfClustersinFED_v_FEDID";
594  NumberOfFEDClus = ibooker.bookProfile(HistoName,
595  HistoName,
596  FEDCluster.getParameter<int32_t>("Nbinsx"),
597  FEDCluster.getParameter<double>("xmin"),
598  FEDCluster.getParameter<double>("xmax"),
599  FEDCluster.getParameter<int32_t>("Nbinsy"),
600  FEDCluster.getParameter<double>("ymin"),
601  FEDCluster.getParameter<double>("ymax"),
602  "");
603  NumberOfFEDClus->setAxisTitle("FED ID", 1);
604  NumberOfFEDClus->setAxisTitle("Mean # of Cluster in FED", 2);
605  }
606  }
607 
608  } // end of if
609 } // end of method
610 
611 //--------------------------------------------------------------------------------------------
612 
615  unsigned long long cacheID = es.get<SiStripDetCablingRcd>().cacheIdentifier();
616  if (m_cacheID_ != cacheID) {
617  m_cacheID_ = cacheID;
618  edm::LogInfo("SiStripMonitorCluster") << "SiStripMonitorCluster::bookHistograms: "
619  << " Creating MEs for new Cabling ";
620 
621  createMEs(es, ibooker);
622  }
623  } else if (reset_each_run) {
624  edm::LogInfo("SiStripMonitorCluster") << "SiStripMonitorCluster::bookHistograms: "
625  << " Resetting MEs ";
626  for (std::map<uint32_t, ModMEs>::const_iterator idet = ModuleMEsMap.begin(); idet != ModuleMEsMap.end(); idet++) {
627  ResetModuleMEs(idet->first);
628  }
629  }
630 }
631 
632 //--------------------------------------------------------------------------------------------
634  // Retrieve tracker topology from geometry
635  const TrackerTopology* const tTopo = &iSetup.getData(trackerTopologyEventToken_);
636 
637  // Filter out events if Trigger Filtering is requested
639  ? genTriggerEventFlagBPTXfilter_->accept(iEvent, iSetup)
640  : true;
642  ? genTriggerEventFlagPixelDCSfilter_->accept(iEvent, iSetup)
643  : true;
645  ? genTriggerEventFlagStripDCSfilter_->accept(iEvent, iSetup)
646  : true;
647  // std::cout << "passBPTXfilter_ ? " << passBPTXfilter_ << std::endl;
648 
649  // Filter out events if DCS Event if requested
650  bool passDCSFilter_ = !(dcsStatus_ && !dcsStatus_->getStatus(iEvent, iSetup));
651 
652  runNb = iEvent.id().run();
653  eventNb++;
654 
655  if (!iEvent.isRealData()) {
657  : iEvent.eventAuxiliary().luminosityBlock(); // 10 lumisection : lumisection
658 
659  } else {
660  trendVar = trendVs10Ls_ ? iEvent.orbitNumber() / (10 * 262144.0)
661  : iEvent.orbitNumber() / (1 * 262144.0); // 10 lumisection : lumisection
662  }
663 
664  int NPixClusters = 0, NStripClusters = 0, MultiplicityRegion = 0;
665  bool isPixValid = false;
666 
667  const SiStripNoises& siStripNoises = iSetup.getData(siStripNoisesToken_);
668  const SiStripGain& siStripGain = iSetup.getData(siStripGainToken_);
669  const SiStripQuality& siStripQuality = iSetup.getData(siStripQualityToken_);
670  const SiStripDetCabling& siStripDetCabling = iSetup.getData(siStripDetCablingEventToken_);
671 
672  // get collection of DetSetVector of clusters from Event
674  iEvent.getByToken(clusterProducerStripToken_, cluster_detsetvektor);
675 
676  // get pixel clusters
677  edm::Handle<edmNew::DetSetVector<SiPixelCluster> > cluster_detsetvektor_pix;
678  iEvent.getByToken(clusterProducerPixToken_, cluster_detsetvektor_pix);
679 
680  if (!cluster_detsetvektor.isValid())
681  return;
682 
683  const edmNew::DetSetVector<SiStripCluster>* StrC = cluster_detsetvektor.product();
684  NStripClusters = StrC->data().size();
685 
686  if (cluster_detsetvektor_pix.isValid()) {
687  const edmNew::DetSetVector<SiPixelCluster>* PixC = cluster_detsetvektor_pix.product();
688  NPixClusters = PixC->data().size();
689  isPixValid = true;
690  MultiplicityRegion = FindRegion(NStripClusters, NPixClusters);
691 
692  if (passBPTXfilter_ and passPixelDCSfilter_ and passStripDCSfilter_ and passDCSFilter_) {
694  GlobalCStripVsCpix->Fill(NStripClusters, NPixClusters);
695  if (globalswitchmaindiagonalposition && NStripClusters > 0)
696  GlobalMainDiagonalPosition->Fill(atan(NPixClusters / (k0 * NStripClusters)));
697 
699  PixVsStripMultiplicityRegions->Fill(MultiplicityRegion);
700  }
701 
702  if (ClusterHisto_ and passDCSFilter_) {
704  NumberOfPixelClus->Fill(NPixClusters);
706  NumberOfStripClus->Fill(NStripClusters);
707  }
708  }
709  // initialise # of clusters to zero
710  for (std::map<std::string, SubDetMEs>::iterator iSubdet = SubDetMEsMap.begin(); iSubdet != SubDetMEsMap.end();
711  iSubdet++) {
712  iSubdet->second.totNClusters = 0;
713  }
714 
716  bool found_layer_me = false;
717  // Map of cumulative clusters per fed ID.
718  std::map<int, int> FEDID_v_clustersum;
719 
720  for (std::map<std::string, std::vector<uint32_t> >::const_iterator iterLayer = LayerDetMap.begin();
721  iterLayer != LayerDetMap.end();
722  iterLayer++) {
723  std::string layer_label = iterLayer->first;
724 
725  int ncluster_layer = 0;
726  std::map<std::string, LayerMEs>::iterator iLayerME = LayerMEsMap.find(layer_label);
727 
728  // get Layer MEs
729  LayerMEs layer_single;
730  if (iLayerME != LayerMEsMap.end()) {
731  layer_single = iLayerME->second;
732  found_layer_me = true;
733  }
734 
735  int ncluster_ring[20] = {0};
736 
737  bool found_module_me = false;
738  uint16_t iDet = 0;
739  std::string subdet_label = "";
740  // loop over all modules in the layer
741  for (std::vector<uint32_t>::const_iterator iterDets = iterLayer->second.begin();
742  iterDets != iterLayer->second.end();
743  iterDets++) {
744  iDet++;
745  // detid and type of ME
746  uint32_t detid = (*iterDets);
747 
748  // Get SubDet label once
749  if (subdet_label.empty())
750  subdet_label = folder_organizer.getSubDetFolderAndTag(detid, tTopo).second;
751 
752  // DetId and corresponding set of MEs
753  ModMEs mod_single;
754  if (Mod_On_) {
755  std::map<uint32_t, ModMEs>::iterator imodME = ModuleMEsMap.find(detid);
756  if (imodME != ModuleMEsMap.end()) {
757  mod_single = imodME->second;
758  found_module_me = true;
759  }
760  } else
761  found_module_me = false;
762 
764  cluster_detsetvektor->find(detid); // search clusters of detid
765 
766  if (isearch == cluster_detsetvektor->end() and passDCSFilter_) {
767  if (found_module_me && moduleswitchncluson && (mod_single.NumberOfClusters)) {
768  (mod_single.NumberOfClusters)->Fill(0.); // no clusters for this
769  // detector module,fill
770  // histogram with 0
771  }
773  tkmapcluster->fill(detid, 0.);
775  tkmapclusterch->fill(detid, 0.);
776  if (found_layer_me && layerswitchnumclusterprofon)
777  layer_single.LayerNumberOfClusterProfile->Fill(iDet, 0.0);
778  }
779 
780  if (isearch == cluster_detsetvektor->end()) {
781  continue; // no clusters for this detid => jump to next step of loop
782  }
783 
784  // cluster_detset is a structure, cluster_detset.data is a
785  // std::vector<SiStripCluster>, cluster_detset.id is uint32_t
786  // edmNew::DetSet<SiStripCluster> cluster_detset =
787  // (*cluster_detsetvektor)[detid]; // the statement above makes sure there
788  // exists an element with 'detid'
789  edmNew::DetSet<SiStripCluster> cluster_detset = (*isearch);
790 
792  // Get all FED connections associated with given detID.
793  // All connections for a detid have same FED Id therefore one FEDID is
794  // associated with a given detID. Vector of constant FedChannelConnection
795  // objects to variable pointers.
796  std::vector<const FedChannelConnection*> fedConnections = siStripDetCabling.getConnections(detid);
797 
798  // Filling FED Id associated clusters map.
799 
800  int good_fcc_index = -999;
801  for (unsigned int x = 0; x < fedConnections.size(); x++) {
802  if (fedConnections[x] != nullptr) {
803  good_fcc_index = x;
804  break;
805  }
806  }
807  if (good_fcc_index != -999 && fedConnections[good_fcc_index] != nullptr) {
808  int temp_fedid = fedConnections[good_fcc_index]->fedId();
809  if (FEDID_v_clustersum.find(temp_fedid) != FEDID_v_clustersum.end()) {
810  if (cluster_detset.size() < 1000 && !cluster_detset.empty()) {
811  FEDID_v_clustersum[temp_fedid] = FEDID_v_clustersum.find(temp_fedid)->second + cluster_detset.size();
812  }
813  } else {
814  if (cluster_detset.size() < 1000 && !cluster_detset.empty()) {
815  FEDID_v_clustersum[temp_fedid] = cluster_detset.size();
816  }
817  }
818  } else {
819  edm::LogInfo("SiStripMonitorCluster") << "SiStripMonitorCluster::analyze WARNING! no good connections "
820  "for detid = "
821  << detid << endl;
822  }
824 
825  // Filling TkHistoMap with number of clusters for each module
826  if (clustertkhistomapon and passDCSFilter_) {
827  tkmapcluster->fill(detid, static_cast<float>(cluster_detset.size()));
828  }
829 
830  if (moduleswitchncluson && found_module_me && (mod_single.NumberOfClusters != nullptr) &&
831  passDCSFilter_) { // nr. of clusters per module
832  (mod_single.NumberOfClusters)->Fill(static_cast<float>(cluster_detset.size()));
833  }
834 
835  if (found_layer_me && layerswitchnumclusterprofon && passDCSFilter_)
836  layer_single.LayerNumberOfClusterProfile->Fill(iDet, static_cast<float>(cluster_detset.size()));
837  ncluster_layer += cluster_detset.size();
838 
839  short total_clusterized_strips = 0;
840 
841  SiStripNoises::Range detNoiseRange = siStripNoises.getRange(detid);
842  SiStripApvGain::Range detGainRange = siStripGain.getRange(detid);
843  SiStripQuality::Range qualityRange = siStripQuality.getRange(detid);
844 
845  for (edmNew::DetSet<SiStripCluster>::const_iterator clusterIter = cluster_detset.begin();
846  clusterIter != cluster_detset.end();
847  clusterIter++) {
848  const auto& ampls = clusterIter->amplitudes();
849  // cluster position
850  float cluster_position = clusterIter->barycenter();
851  // start defined as nr. of first strip beloning to the cluster
852  short cluster_start = clusterIter->firstStrip();
853  // width defined as nr. of strips that belong to cluster
854  short cluster_width = ampls.size();
855  // add nr of strips of this cluster to total nr. of clusterized strips
856  total_clusterized_strips = total_clusterized_strips + cluster_width;
857 
858  if (clusterchtkhistomapon and passDCSFilter_)
859  tkmapclusterch->fill(detid, static_cast<float>(clusterIter->charge()));
860 
861  // cluster signal and noise from the amplitudes
862  float cluster_signal = 0.0;
863  float cluster_noise = 0.0;
864  int nrnonzeroamplitudes = 0;
865  float noise2 = 0.0;
866  float noise = 0.0;
867  for (uint iamp = 0; iamp < ampls.size(); iamp++) {
868  if (ampls[iamp] > 0) { // nonzero amplitude
869  cluster_signal += ampls[iamp];
870  if (!siStripQuality.IsStripBad(qualityRange, clusterIter->firstStrip() + iamp)) {
871  noise = siStripNoises.getNoise(clusterIter->firstStrip() + iamp, detNoiseRange) /
872  siStripGain.getStripGain(clusterIter->firstStrip() + iamp, detGainRange);
873  }
874  noise2 += noise * noise;
875  nrnonzeroamplitudes++;
876  }
877  } // End loop over cluster amplitude
878 
879  if (nrnonzeroamplitudes > 0)
880  cluster_noise = sqrt(noise2 / nrnonzeroamplitudes);
881 
882  if (applyClusterQuality_ &&
883  (cluster_signal / cluster_noise < sToNLowerLimit_ || cluster_signal / cluster_noise > sToNUpperLimit_ ||
884  cluster_width < widthLowerLimit_ || cluster_width > widthUpperLimit_))
885  continue;
886 
887  ClusterProperties cluster_properties;
888  cluster_properties.charge = cluster_signal;
889  cluster_properties.position = cluster_position;
890  cluster_properties.start = cluster_start;
891  cluster_properties.width = cluster_width;
892  cluster_properties.noise = cluster_noise;
893 
894  // Fill Module Level MEs
895  if (found_module_me and passDCSFilter_)
896  fillModuleMEs(mod_single, cluster_properties);
897 
898  // Fill Layer Level MEs
899  if (found_layer_me and passDCSFilter_) {
900  fillLayerMEs(layer_single, cluster_properties);
902  layer_single.LayerClusterWidthProfile->Fill(iDet, cluster_width);
903  }
904 
906  std::map<std::string, SubDetMEs>::iterator iSubdet = SubDetMEsMap.find(subdet_label);
907  if (iSubdet != SubDetMEsMap.end()) {
908  if (subdetswitchcluschargeon and passDCSFilter_)
909  iSubdet->second.SubDetClusterChargeTH1->Fill(cluster_signal);
910  if (subdetswitchcluswidthon and passDCSFilter_)
911  iSubdet->second.SubDetClusterWidthTH1->Fill(cluster_width);
912  }
913  }
914 
915  if (subdet_clusterWidth_vs_amplitude_on and passDCSFilter_) {
916  std::map<std::string, SubDetMEs>::iterator iSubdet = SubDetMEsMap.find(subdet_label);
917  if (iSubdet != SubDetMEsMap.end())
918  iSubdet->second.SubDetClusWidthVsAmpTH2->Fill(cluster_signal, cluster_width);
919  }
920 
921  if (clusterWidth_vs_amplitude_on and passDCSFilter_) {
922  ClusWidthVsAmpTH2->Fill(cluster_signal, cluster_width);
923  }
924 
926  (subdet_label.find("TID") != std::string::npos || subdet_label.find("TEC") != std::string::npos)) {
927  std::pair<std::string, int32_t> det_ring_pair = folder_organizer.GetSubDetAndLayer(detid, tTopo, true);
928  ncluster_ring[std::abs(det_ring_pair.second)]++;
929  }
930 
931  } // end loop over clusters
932 
934  std::map<std::string, SubDetMEs>::iterator iSubdet = SubDetMEsMap.find(subdet_label);
935  std::pair<std::string, int32_t> det_layer_pair = folder_organizer.GetSubDetAndLayer(detid, tTopo);
936  iSubdet->second.SubDetNumberOfClusterPerLayerTrend->Fill(
937  trendVar, std::abs(det_layer_pair.second), ncluster_layer);
938  }
939 
941  (subdet_label.find("TID") != std::string::npos || subdet_label.find("TEC") != std::string::npos)) {
942  std::pair<std::string, int32_t> det_ring_pair = folder_organizer.GetSubDetAndLayer(detid, tTopo, true);
944  trendVar, std::abs(det_ring_pair.second), ncluster_ring[std::abs(det_ring_pair.second)]);
945  }
946 
947  short total_nr_strips = siStripDetCabling.nApvPairs(detid) * 2 * 128; // get correct # of avp pairs
948  float local_occupancy = static_cast<float>(total_clusterized_strips) / static_cast<float>(total_nr_strips);
949  if (found_module_me and passDCSFilter_) {
950  if (moduleswitchnrclusterizedstrip && mod_single.NrOfClusterizedStrips) { // nr of clusterized strips
951  mod_single.NrOfClusterizedStrips->Fill(static_cast<float>(total_clusterized_strips));
952  }
953 
954  if (moduleswitchlocaloccupancy && mod_single.ModuleLocalOccupancy) { // Occupancy
955  mod_single.ModuleLocalOccupancy->Fill(local_occupancy);
956  }
957  }
958  if (layerswitchlocaloccupancy && found_layer_me && layer_single.LayerLocalOccupancy && passDCSFilter_) {
959  fillME(layer_single.LayerLocalOccupancy, local_occupancy);
960  if (createTrendMEs)
961  fillME(layer_single.LayerLocalOccupancyTrend, trendVar, local_occupancy);
962  }
963  }
964 
966  fillME(layer_single.LayerNumberOfClusterTrend, trendVar, ncluster_layer);
967 
968  std::map<std::string, SubDetMEs>::iterator iSubdet = SubDetMEsMap.find(subdet_label);
969  if (iSubdet != SubDetMEsMap.end())
970  iSubdet->second.totNClusters += ncluster_layer;
971  }
972 
973  // EventHistory
974  edm::Handle<EventWithHistory> event_history;
975  iEvent.getByToken(historyProducerToken_, event_history);
976 
977  // Phase of APV
978  edm::Handle<APVCyclePhaseCollection> apv_phase_collection;
979  iEvent.getByToken(apvPhaseProducerToken_, apv_phase_collection);
980 
981  if (event_history.isValid() && !event_history.failedToGet() && apv_phase_collection.isValid() &&
982  !apv_phase_collection.failedToGet()) {
983  long long dbx = event_history->deltaBX();
984  long long tbx = event_history->absoluteBX();
985 
986  bool global_histo_filled = false;
987  bool MultiplicityRegion_Vs_APVcycle_filled = false;
988 
989  // plot n 2
990  if (passBPTXfilter_ and passPixelDCSfilter_ and passStripDCSfilter_ && passDCSFilter_) {
992  GlobalABXTH1_CSCP->Fill(tbx % 3564);
993  }
994  // plot n 2
995 
996  for (std::map<std::string, SubDetMEs>::iterator it = SubDetMEsMap.begin(); it != SubDetMEsMap.end(); it++) {
997  std::string sdet = it->first;
998  // std::string sdet = sdet_tag.substr(0,sdet_tag.find_first_of("_"));
999  SubDetMEs sdetmes = it->second;
1000 
1001  int the_phase = APVCyclePhaseCollection::invalid;
1002  long long tbx_corr = tbx;
1003 
1004  if (SubDetPhasePartMap.find(sdet) != SubDetPhasePartMap.end())
1005  the_phase = apv_phase_collection->getPhase(SubDetPhasePartMap[sdet]);
1007  the_phase == APVCyclePhaseCollection::invalid) {
1008  the_phase = 30;
1009  // std::cout << " subdet " << it->first << " not valid" << " MR " <<
1010  // MultiplicityRegion <<std::endl;
1011  }
1012  tbx_corr -= the_phase;
1013 
1014  long long dbxincycle = event_history->deltaBXinCycle(the_phase);
1015  // std::cout<<"dbx in cycle: " << dbxincycle << std::endl;
1016  if (globalswitchapvcycledbxth2on && !global_histo_filled && passDCSFilter_) {
1017  GlobalApvCycleDBxTH2->Fill(tbx_corr % 70, dbx);
1018  GlobalDBxTH1->Fill(dbx);
1019  GlobalDBxCycleTH1->Fill(dbxincycle);
1020  global_histo_filled = true;
1021  }
1022 
1023  // Fill MainDiagonalPosition plots ***************
1024  if (cluster_detsetvektor_pix.isValid()) {
1025  if (ClusterHisto_) {
1026  if (passBPTXfilter_ and passStripDCSfilter_ and passDCSFilter_) {
1027  NumberOfStripClus_vs_BX->Fill(tbx % 3564, NStripClusters);
1028  if (passPixelDCSfilter_) {
1029  NumberOfPixelClus_vs_BX->Fill(tbx % 3564, NPixClusters);
1030  if (globalswitchmaindiagonalposition && NStripClusters > 0) {
1031  GlobalMainDiagonalPosition_vs_BX->Fill(tbx % 3564, atan(NPixClusters / (k0 * NStripClusters)));
1032  GlobalTH2MainDiagonalPosition_vs_BX->Fill(tbx % 3564, atan(NPixClusters / (k0 * NStripClusters)));
1033  }
1034  }
1035  }
1036 
1037  // Filling # clusters per FED ID histogram from FED Id clusters map
1038  // (for all layers simultaneously).
1039  map<int, int>::iterator it;
1040  // for(it=FEDID_v_clustersum.begin(); it!=FEDID_v_clustersum.end();
1041  // it++){
1042  for (auto const& fedidEntry : FEDID_v_clustersum) {
1043  // NumberOfFEDClus->Fill(it->first,it->second);
1044  if (passDCSFilter_)
1045  NumberOfFEDClus->Fill(fedidEntry.first, fedidEntry.second);
1046  // if(it->first < 100){
1047  // Trend_NumberOfFEDClus->Fill(trendVar,it->first,it->second);
1048  //}
1049  }
1050  FEDID_v_clustersum.clear();
1051  }
1052  }
1053 
1054  if (isPixValid && !MultiplicityRegion_Vs_APVcycle_filled && passDCSFilter_) {
1055  if (globalswitchstripnoise2apvcycle && MultiplicityRegion == 2) {
1056  StripNoise2Cycle->Fill(tbx_corr % 70);
1057  }
1058  if (globalswitchstripnoise3apvcycle && MultiplicityRegion == 3) {
1059  StripNoise3Cycle->Fill(tbx_corr % 70);
1060  }
1061  MultiplicityRegion_Vs_APVcycle_filled = true;
1062  }
1063 
1064  if (subdetswitchtotclusth1on and passDCSFilter_)
1065  sdetmes.SubDetTotClusterTH1->Fill(sdetmes.totNClusters);
1067  sdetmes.SubDetTotClusterProf->Fill(trendVar, sdetmes.totNClusters);
1068  if (subdetswitchapvcycleprofon and passDCSFilter_)
1069  sdetmes.SubDetClusterApvProf->Fill(tbx_corr % 70, sdetmes.totNClusters);
1070  if (subdetswitchapvcycleth2on and passDCSFilter_)
1071  sdetmes.SubDetClusterApvTH2->Fill(tbx_corr % 70, sdetmes.totNClusters);
1072  if (subdetswitchdbxcycleprofon and passDCSFilter_) {
1073  sdetmes.SubDetClusterDBxCycleProf->Fill(dbxincycle, sdetmes.totNClusters);
1074  }
1075  if (subdetswitchapvcycledbxprof2on and passDCSFilter_)
1076  sdetmes.SubDetApvDBxProf2->Fill(tbx_corr % 70, dbx, sdetmes.totNClusters);
1077  }
1078 
1079  if (globalswitchnclusvscycletimeprof2don and passDCSFilter_) {
1080  long long tbx_corr = tbx;
1081  int the_phase = apv_phase_collection->getPhase("All");
1082 
1084  the_phase == APVCyclePhaseCollection::invalid)
1085  the_phase = 30;
1086 
1087  tbx_corr -= the_phase;
1088 
1089  NclusVsCycleTimeProf2D->Fill(tbx_corr % 70, (int)event_history->_orbit, NStripClusters);
1090  }
1091  }
1092 }
1093 //
1094 // -- Reset MEs
1095 //------------------------------------------------------------------------------
1097  std::map<uint32_t, ModMEs>::iterator pos = ModuleMEsMap.find(idet);
1098  ModMEs mod_me = pos->second;
1099 
1100  if (moduleswitchncluson)
1101  mod_me.NumberOfClusters->Reset();
1103  mod_me.ClusterPosition->Reset();
1105  mod_me.ClusterDigiPosition->Reset();
1109  mod_me.ClusterWidth->Reset();
1111  mod_me.ClusterCharge->Reset();
1113  mod_me.ClusterNoise->Reset();
1115  mod_me.ClusterSignalOverNoise->Reset();
1117  mod_me.ModuleLocalOccupancy->Reset();
1119  mod_me.NrOfClusterizedStrips->Reset();
1121  mod_me.Module_ClusWidthVsAmpTH2->Reset();
1122 }
1123 //
1124 // -- Create Module Level MEs
1125 //
1127  uint32_t detid,
1128  DQMStore::IBooker& ibooker,
1129  const SiStripDetCabling& siStripDetCabling) {
1130  // use SistripHistoId for producing histogram id (and title)
1132  std::string hid;
1133 
1134  // nr. of clusters per module
1135  if (moduleswitchncluson) {
1136  hid = hidmanager.createHistoId("NumberOfClusters", "det", detid);
1137  mod_single.NumberOfClusters = bookME1D("TH1nClusters", hid.c_str(), ibooker);
1138  mod_single.NumberOfClusters->setAxisTitle("number of clusters in one detector module");
1139  mod_single.NumberOfClusters->setStatOverflows(kTRUE); // over/underflows in Mean calculation
1140  }
1141 
1142  // ClusterPosition
1143  if (moduleswitchclusposon) {
1144  short total_nr_strips = siStripDetCabling.nApvPairs(detid) * 2 * 128; // get correct # of avp pairs
1145  hid = hidmanager.createHistoId("ClusterPosition", "det", detid);
1146  mod_single.ClusterPosition = ibooker.book1D(hid, hid, total_nr_strips, 0.5, total_nr_strips + 0.5);
1147  mod_single.ClusterPosition->setAxisTitle("cluster position [strip number +0.5]");
1148  }
1149 
1150  // ClusterDigiPosition
1152  short total_nr_strips = siStripDetCabling.nApvPairs(detid) * 2 * 128; // get correct # of avp pairs
1153  hid = hidmanager.createHistoId("ClusterDigiPosition", "det", detid);
1154  mod_single.ClusterDigiPosition = ibooker.book1D(hid, hid, total_nr_strips, 0.5, total_nr_strips + 0.5);
1155  mod_single.ClusterDigiPosition->setAxisTitle("digi in cluster position [strip number +0.5]");
1156  }
1157 
1158  // ClusterWidth
1160  hid = hidmanager.createHistoId("ClusterWidth", "det", detid);
1161  mod_single.ClusterWidth = bookME1D("TH1ClusterWidth", hid.c_str(), ibooker);
1162  mod_single.ClusterWidth->setAxisTitle("cluster width [nr strips]");
1163  }
1164 
1165  // ClusterCharge
1167  hid = hidmanager.createHistoId("ClusterCharge", "det", detid);
1168  mod_single.ClusterCharge = bookME1D("TH1ClusterCharge", hid.c_str(), ibooker);
1169  mod_single.ClusterCharge->setAxisTitle("cluster charge [ADC]");
1170  }
1171 
1172  // ClusterNoise
1174  hid = hidmanager.createHistoId("ClusterNoise", "det", detid);
1175  mod_single.ClusterNoise = bookME1D("TH1ClusterNoise", hid.c_str(), ibooker);
1176  mod_single.ClusterNoise->setAxisTitle("cluster noise");
1177  }
1178 
1179  // ClusterSignalOverNoise
1180  if (moduleswitchclusstonon) {
1181  hid = hidmanager.createHistoId("ClusterSignalOverNoise", "det", detid);
1182  mod_single.ClusterSignalOverNoise = bookME1D("TH1ClusterStoN", hid.c_str(), ibooker);
1183  mod_single.ClusterSignalOverNoise->setAxisTitle("ratio of signal to noise for each cluster");
1184  }
1185 
1186  // ClusterSignalOverNoiseVsPos
1188  hid = hidmanager.createHistoId("ClusterSignalOverNoiseVsPos", "det", detid);
1189  Parameters = conf_.getParameter<edm::ParameterSet>("TH1ClusterStoNVsPos");
1190  mod_single.ClusterSignalOverNoiseVsPos = ibooker.bookProfile(hid.c_str(),
1191  hid.c_str(),
1192  Parameters.getParameter<int32_t>("Nbinx"),
1193  Parameters.getParameter<double>("xmin"),
1194  Parameters.getParameter<double>("xmax"),
1195  Parameters.getParameter<int32_t>("Nbiny"),
1196  Parameters.getParameter<double>("ymin"),
1197  Parameters.getParameter<double>("ymax"));
1198  mod_single.ClusterSignalOverNoiseVsPos->setAxisTitle("pos");
1199  }
1200 
1201  // ModuleLocalOccupancy
1203  hid = hidmanager.createHistoId("ClusterLocalOccupancy", "det", detid);
1204  mod_single.ModuleLocalOccupancy = bookME1D("TH1ModuleLocalOccupancy", hid.c_str(), ibooker);
1205  mod_single.ModuleLocalOccupancy->setAxisTitle("module local occupancy [% of clusterized strips]");
1206  }
1207 
1208  // NrOfClusterizedStrips
1210  hid = hidmanager.createHistoId("NrOfClusterizedStrips", "det", detid);
1211  mod_single.NrOfClusterizedStrips = bookME1D("TH1NrOfClusterizedStrips", hid.c_str(), ibooker);
1212  mod_single.NrOfClusterizedStrips->setAxisTitle("number of clusterized strips");
1213  }
1214 
1216  hid = hidmanager.createHistoId("ClusterWidths_vs_Amplitudes", "det", detid);
1217  Parameters = conf_.getParameter<edm::ParameterSet>("ClusWidthVsAmpTH2");
1218  int32_t Nbinsx = Parameters.getParameter<int32_t>("Nbinsx");
1219  Nbinsx = Nbinsx / 2; // Without this "rebinning" the job is killed on
1220  // lxplus. We think it's due to the high memory needed
1221  // to create all those histograms.
1222  mod_single.Module_ClusWidthVsAmpTH2 = ibooker.book2D(hid.c_str(),
1223  hid.c_str(),
1224  Nbinsx,
1225  Parameters.getParameter<double>("xmin"),
1226  Parameters.getParameter<double>("xmax"),
1227  Parameters.getParameter<int32_t>("Nbinsy"),
1228  Parameters.getParameter<double>("ymin"),
1229  Parameters.getParameter<double>("ymax"));
1230  mod_single.Module_ClusWidthVsAmpTH2->setAxisTitle("Amplitudes (integrated ADC counts)", 1);
1231  mod_single.Module_ClusWidthVsAmpTH2->setAxisTitle("Cluster widths", 2);
1232  }
1233 }
1234 //
1235 // -- Create Module Level MEs
1236 //
1239 
1240  LayerMEs layerMEs;
1241  layerMEs.LayerClusterStoN = nullptr;
1242  layerMEs.LayerClusterStoNTrend = nullptr;
1243  layerMEs.LayerClusterCharge = nullptr;
1244  layerMEs.LayerClusterChargeTrend = nullptr;
1245  layerMEs.LayerClusterNoise = nullptr;
1246  layerMEs.LayerClusterNoiseTrend = nullptr;
1247  layerMEs.LayerClusterWidth = nullptr;
1248  layerMEs.LayerClusterWidthTrend = nullptr;
1249  layerMEs.LayerLocalOccupancy = nullptr;
1250  layerMEs.LayerLocalOccupancyTrend = nullptr;
1251  layerMEs.LayerNumberOfClusterProfile = nullptr;
1252  layerMEs.LayerNumberOfClusterTrend = nullptr;
1253  layerMEs.LayerNumberOfClusterPerRingTrend = nullptr;
1254  layerMEs.LayerClusterWidthProfile = nullptr;
1255  layerMEs.LayerClusWidthVsAmpTH2 = nullptr;
1256  layerMEs.LayerClusterPosition = nullptr;
1257 
1258  // Cluster Width
1259  if (layerswitchcluswidthon) {
1260  layerMEs.LayerClusterWidth = bookME1D(
1261  "TH1ClusterWidth", hidmanager.createHistoLayer("Summary_ClusterWidth", "layer", label, "").c_str(), ibooker);
1262  if (createTrendMEs)
1263  layerMEs.LayerClusterWidthTrend =
1264  bookMETrend(hidmanager.createHistoLayer("Trend_ClusterWidth", "layer", label, "").c_str(), ibooker);
1265  }
1266 
1267  // Cluster Noise
1268  if (layerswitchclusnoiseon) {
1269  layerMEs.LayerClusterNoise = bookME1D(
1270  "TH1ClusterNoise", hidmanager.createHistoLayer("Summary_ClusterNoise", "layer", label, "").c_str(), ibooker);
1271  if (createTrendMEs)
1272  layerMEs.LayerClusterNoiseTrend =
1273  bookMETrend(hidmanager.createHistoLayer("Trend_ClusterNoise", "layer", label, "").c_str(), ibooker);
1274  }
1275 
1276  // Cluster Charge
1278  layerMEs.LayerClusterCharge = bookME1D(
1279  "TH1ClusterCharge", hidmanager.createHistoLayer("Summary_ClusterCharge", "layer", label, "").c_str(), ibooker);
1280  if (createTrendMEs)
1281  layerMEs.LayerClusterChargeTrend =
1282  bookMETrend(hidmanager.createHistoLayer("Trend_ClusterCharge", "layer", label, "").c_str(), ibooker);
1283  }
1284 
1285  // Cluster StoN
1286  if (layerswitchclusstonon) {
1287  layerMEs.LayerClusterStoN =
1288  bookME1D("TH1ClusterStoN",
1289  hidmanager.createHistoLayer("Summary_ClusterSignalOverNoise", "layer", label, "").c_str(),
1290  ibooker);
1291  if (createTrendMEs)
1292  layerMEs.LayerClusterStoNTrend =
1293  bookMETrend(hidmanager.createHistoLayer("Trend_ClusterSignalOverNoise", "layer", label, "").c_str(), ibooker);
1294  }
1295 
1296  // Cluster Occupancy
1298  layerMEs.LayerLocalOccupancy =
1299  bookME1D("TH1ModuleLocalOccupancy",
1300  hidmanager.createHistoLayer("Summary_ClusterLocalOccupancy", "layer", label, "").c_str(),
1301  ibooker);
1302  if (createTrendMEs)
1303  layerMEs.LayerLocalOccupancyTrend =
1304  bookMETrend(hidmanager.createHistoLayer("Trend_ClusterLocalOccupancy", "layer", label, "").c_str(), ibooker);
1305  }
1306 
1307  // # of Cluster Profile
1309  std::string hid = hidmanager.createHistoLayer("NumberOfClusterProfile", "layer", label, "");
1310  layerMEs.LayerNumberOfClusterProfile = ibooker.bookProfile(hid, hid, ndets, 0.5, ndets + 0.5, 21, -0.5, 20.5);
1311  }
1312 
1313  // # of Cluster Trend
1315  layerMEs.LayerNumberOfClusterTrend =
1316  bookMETrend(hidmanager.createHistoLayer("NumberOfClusterTrend", "layer", label, "").c_str(), ibooker);
1317 
1318  if (label.find("TID") != std::string::npos || label.find("TEC") != std::string::npos) {
1319  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("NumberOfClusterPerRingVsTrendVar");
1320 
1322  "NumberOfClusterPerRingVsTrendVar",
1323  hidmanager.createHistoLayer("NumberOfClusterPerRing_vs_TrendVar", "layer", label, "").c_str(),
1324  Parameters.getParameter<int32_t>("Nbinsx"),
1325  Parameters.getParameter<double>("xmin"),
1326  Parameters.getParameter<double>("xmax"),
1327  Parameters.getParameter<int32_t>("Nbinsy"),
1328  Parameters.getParameter<double>("ymin"),
1329  Parameters.getParameter<double>("ymax"),
1330  0,
1331  0,
1332  "");
1333  }
1334  }
1335 
1336  // Cluster Width Profile
1338  std::string hid = hidmanager.createHistoLayer("ClusterWidthProfile", "layer", label, "");
1339  layerMEs.LayerClusterWidthProfile = ibooker.bookProfile(hid, hid, ndets, 0.5, ndets + 0.5, 20, -0.5, 19.5);
1340  }
1341 
1343  layerMEs.LayerClusWidthVsAmpTH2 =
1344  bookME2D("ClusWidthVsAmpTH2",
1345  hidmanager.createHistoLayer("ClusterWidths_vs_Amplitudes", "layer", label, "").c_str(),
1346  ibooker);
1347  }
1348 
1349  // Cluster Position
1350  if (layerswitchclusposon) {
1351  std::string hid = hidmanager.createHistoLayer("ClusterPosition", "layer", label, "");
1352  layerMEs.LayerClusterPosition = ibooker.book1D(hid, hid, 128 * 6, 0.5, 128 * 6 + 0.5);
1353  }
1354 
1355  LayerMEsMap[label] = layerMEs;
1356 }
1357 //
1358 // -- Create SubDetector MEs
1359 //
1361  SubDetMEs subdetMEs;
1362  subdetMEs.totNClusters = 0;
1363  subdetMEs.SubDetTotClusterTH1 = nullptr;
1364  subdetMEs.SubDetTotClusterProf = nullptr;
1365  subdetMEs.SubDetClusterApvProf = nullptr;
1366  subdetMEs.SubDetClusterApvTH2 = nullptr;
1367  subdetMEs.SubDetClusterDBxCycleProf = nullptr;
1368  subdetMEs.SubDetApvDBxProf2 = nullptr;
1369  subdetMEs.SubDetClusterChargeTH1 = nullptr;
1370  subdetMEs.SubDetClusterWidthTH1 = nullptr;
1371  subdetMEs.SubDetClusWidthVsAmpTH2 = nullptr;
1372  subdetMEs.SubDetNumberOfClusterPerLayerTrend = nullptr;
1373 
1375  // cluster charge
1377  HistoName = "ClusterCharge__" + label;
1378  subdetMEs.SubDetClusterChargeTH1 = bookME1D("TH1ClusterCharge", HistoName.c_str(), ibooker);
1379  subdetMEs.SubDetClusterChargeTH1->setAxisTitle("Cluster charge [ADC counts]");
1380  subdetMEs.SubDetClusterChargeTH1->setStatOverflows(kTRUE); // over/underflows in Mean calculation
1381  }
1382  // cluster width
1384  HistoName = "ClusterWidth__" + label;
1385  subdetMEs.SubDetClusterWidthTH1 = bookME1D("TH1ClusterWidth", HistoName.c_str(), ibooker);
1386  subdetMEs.SubDetClusterWidthTH1->setAxisTitle("Cluster width [strips]");
1387  subdetMEs.SubDetClusterWidthTH1->setStatOverflows(kTRUE); // over/underflows in Mean calculation
1388  }
1389  // Total Number of Cluster - 1D
1391  HistoName = "TotalNumberOfCluster__" + label;
1392  subdetMEs.SubDetTotClusterTH1 = bookME1D("TH1TotalNumberOfClusters", HistoName.c_str(), ibooker);
1393  subdetMEs.SubDetTotClusterTH1->setAxisTitle("Total number of clusters in subdetector");
1394  subdetMEs.SubDetTotClusterTH1->setStatOverflows(kTRUE); // over/underflows in Mean calculation
1395  }
1396  // Total Number of Cluster vs Time - Profile
1399  : conf_.getParameter<edm::ParameterSet>("Trending");
1400  HistoName = "TotalNumberOfClusterProfile__" + label;
1401  subdetMEs.SubDetTotClusterProf = ibooker.bookProfile(HistoName,
1402  HistoName,
1403  Parameters.getParameter<int32_t>("Nbins"),
1404  Parameters.getParameter<double>("xmin"),
1405  Parameters.getParameter<double>("xmax"),
1406  0,
1407  0,
1408  "");
1409  subdetMEs.SubDetTotClusterProf->setAxisTitle(Parameters.getParameter<std::string>("xaxis"), 1);
1411  subdetMEs.SubDetTotClusterProf->setCanExtend(TH1::kAllAxes);
1412 
1413  Parameters = conf_.getParameter<edm::ParameterSet>("NumberOfClusterPerLayerTrendVar");
1414  HistoName = "TotalNumberOfClusterPerLayer__" + label;
1415  subdetMEs.SubDetNumberOfClusterPerLayerTrend = ibooker.bookProfile2D("NumberOfClusterPerLayerTrendVar",
1416  HistoName.c_str(),
1417  Parameters.getParameter<int32_t>("Nbinsx"),
1418  Parameters.getParameter<double>("xmin"),
1419  Parameters.getParameter<double>("xmax"),
1420  Parameters.getParameter<int32_t>("Nbinsy"),
1421  Parameters.getParameter<double>("ymin"),
1422  Parameters.getParameter<double>("ymax"),
1423  0,
1424  0,
1425  "");
1426  subdetMEs.SubDetNumberOfClusterPerLayerTrend->setAxisTitle("Lumisection", 1);
1427  subdetMEs.SubDetNumberOfClusterPerLayerTrend->setAxisTitle("Layer Number", 2);
1428  }
1429 
1430  // Total Number of Cluster vs APV cycle - Profile
1432  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TProfClustersApvCycle");
1433  HistoName = "Cluster_vs_ApvCycle__" + label;
1434  subdetMEs.SubDetClusterApvProf = ibooker.bookProfile(HistoName,
1435  HistoName,
1436  Parameters.getParameter<int32_t>("Nbins"),
1437  Parameters.getParameter<double>("xmin"),
1438  Parameters.getParameter<double>("xmax"),
1439  200, // that parameter should not be there !?
1440  Parameters.getParameter<double>("ymin"),
1441  Parameters.getParameter<double>("ymax"),
1442  "");
1443  subdetMEs.SubDetClusterApvProf->setAxisTitle("Apv Cycle (Corrected Absolute Bx % 70)", 1);
1444  }
1445 
1446  // Total Number of Clusters vs ApvCycle - 2D
1449  HistoName = "Cluster_vs_ApvCycle_2D__" + label;
1450  // Adjusting the scale for 2D histogram
1451  double h2ymax = 9999.0;
1452  double yfact = Parameters.getParameter<double>("yfactor");
1453  if (label.find("TIB") != std::string::npos)
1454  h2ymax = (6984. * 256.) * yfact;
1455  else if (label.find("TID") != std::string::npos)
1456  h2ymax = (2208. * 256.) * yfact;
1457  else if (label.find("TOB") != std::string::npos)
1458  h2ymax = (12906. * 256.) * yfact;
1459  else if (label.find("TEC") != std::string::npos)
1460  h2ymax = (7552. * 2. * 256.) * yfact;
1461 
1462  subdetMEs.SubDetClusterApvTH2 = ibooker.book2D(HistoName,
1463  HistoName,
1464  Parameters.getParameter<int32_t>("Nbinsx"),
1465  Parameters.getParameter<double>("xmin"),
1466  Parameters.getParameter<double>("xmax"),
1467  Parameters.getParameter<int32_t>("Nbinsy"),
1468  Parameters.getParameter<double>("ymin"),
1469  h2ymax);
1470  subdetMEs.SubDetClusterApvTH2->setAxisTitle("Apv Cycle (Corrected Absolute Bx % 70))", 1);
1471  subdetMEs.SubDetClusterApvTH2->setAxisTitle("Total # of Clusters", 2);
1472  }
1473 
1474  // Cluster widths vs amplitudes - 2D
1477  HistoName = "ClusterWidths_vs_Amplitudes__" + label;
1478  subdetMEs.SubDetClusWidthVsAmpTH2 = ibooker.book2D(HistoName,
1479  HistoName,
1480  Parameters.getParameter<int32_t>("Nbinsx"),
1481  Parameters.getParameter<double>("xmin"),
1482  Parameters.getParameter<double>("xmax"),
1483  Parameters.getParameter<int32_t>("Nbinsy"),
1484  Parameters.getParameter<double>("ymin"),
1485  Parameters.getParameter<double>("ymax"));
1486  subdetMEs.SubDetClusWidthVsAmpTH2->setAxisTitle("Amplitudes (integrated ADC counts)", 1);
1487  subdetMEs.SubDetClusWidthVsAmpTH2->setAxisTitle("Cluster widths", 2);
1488  }
1489 
1490  // Total Number of Cluster vs DeltaBxCycle - Profile
1492  edm::ParameterSet Parameters = conf_.getParameter<edm::ParameterSet>("TProfClustersVsDBxCycle");
1493  HistoName = "Cluster_vs_DeltaBxCycle__" + label;
1494  subdetMEs.SubDetClusterDBxCycleProf = ibooker.bookProfile(HistoName,
1495  HistoName,
1496  Parameters.getParameter<int32_t>("Nbins"),
1497  Parameters.getParameter<double>("xmin"),
1498  Parameters.getParameter<double>("xmax"),
1499  200, // that parameter should not be there !?
1500  Parameters.getParameter<double>("ymin"),
1501  Parameters.getParameter<double>("ymax"),
1502  "");
1503  subdetMEs.SubDetClusterDBxCycleProf->setAxisTitle("Delta Bunch Crossing Cycle", 1);
1504  }
1505  // DeltaBx vs ApvCycle - 2DProfile
1508  HistoName = "DeltaBx_vs_ApvCycle__" + label;
1509  subdetMEs.SubDetApvDBxProf2 = ibooker.bookProfile2D(HistoName,
1510  HistoName,
1511  Parameters.getParameter<int32_t>("Nbinsx"),
1512  Parameters.getParameter<double>("xmin"),
1513  Parameters.getParameter<double>("xmax"),
1514  Parameters.getParameter<int32_t>("Nbinsy"),
1515  Parameters.getParameter<double>("ymin"),
1516  Parameters.getParameter<double>("ymax"),
1517  Parameters.getParameter<double>("zmin"),
1518  Parameters.getParameter<double>("zmax"),
1519  "");
1520  subdetMEs.SubDetApvDBxProf2->setAxisTitle("APV Cycle (Corrected Absolute Bx % 70)", 1);
1521  subdetMEs.SubDetApvDBxProf2->setAxisTitle("Delta Bunch Crossing Cycle", 2);
1522  }
1523  SubDetMEsMap[label] = subdetMEs;
1524 }
1525 
1526 //
1527 // -- Fill Module Level Histograms
1528 //
1530  if (moduleswitchclusposon && (mod_mes.ClusterPosition)) // position of cluster
1531  (mod_mes.ClusterPosition)->Fill(cluster.position);
1532 
1533  // position of digis in cluster
1535  for (int ipos = cluster.start + 1; ipos <= cluster.start + cluster.width; ipos++) {
1536  (mod_mes.ClusterDigiPosition)->Fill(ipos);
1537  }
1538  }
1539 
1540  if (moduleswitchcluswidthon && (mod_mes.ClusterWidth)) // width of cluster
1541  (mod_mes.ClusterWidth)->Fill(static_cast<float>(cluster.width));
1542 
1543  if (moduleswitchclusstonon && (mod_mes.ClusterSignalOverNoise)) { // SignalToNoise
1544  if (cluster.noise > 0)
1545  (mod_mes.ClusterSignalOverNoise)->Fill(cluster.charge / cluster.noise);
1546  }
1547 
1548  if (moduleswitchclusstonVsposon && (mod_mes.ClusterSignalOverNoiseVsPos)) { // SignalToNoise
1549  if (cluster.noise > 0)
1550  (mod_mes.ClusterSignalOverNoiseVsPos)->Fill(cluster.position, cluster.charge / cluster.noise);
1551  }
1552 
1553  if (moduleswitchclusnoiseon && (mod_mes.ClusterNoise)) // Noise
1554  (mod_mes.ClusterNoise)->Fill(cluster.noise);
1555 
1556  if (moduleswitchcluschargeon && (mod_mes.ClusterCharge)) // charge of cluster
1557  (mod_mes.ClusterCharge)->Fill(cluster.charge);
1558 
1560  (mod_mes.Module_ClusWidthVsAmpTH2)->Fill(cluster.charge, cluster.width);
1561 }
1562 //
1563 // -- Fill Layer Level MEs
1564 //
1566  if (layerswitchclusstonon) {
1567  fillME(layerMEs.LayerClusterStoN, cluster.charge / cluster.noise);
1568  if (createTrendMEs) {
1569  fillME(layerMEs.LayerClusterStoNTrend, trendVar, cluster.charge / cluster.noise);
1570  }
1571  }
1572 
1574  fillME(layerMEs.LayerClusterCharge, cluster.charge);
1575  if (createTrendMEs) {
1576  fillME(layerMEs.LayerClusterChargeTrend, trendVar, cluster.charge);
1577  }
1578  }
1579 
1580  if (layerswitchclusnoiseon) {
1581  fillME(layerMEs.LayerClusterNoise, cluster.noise);
1582  if (createTrendMEs) {
1583  fillME(layerMEs.LayerClusterNoiseTrend, trendVar, cluster.noise);
1584  }
1585  }
1586 
1587  if (layerswitchcluswidthon) {
1588  fillME(layerMEs.LayerClusterWidth, cluster.width);
1589  if (createTrendMEs) {
1590  fillME(layerMEs.LayerClusterWidthTrend, trendVar, cluster.width);
1591  }
1592  }
1593 
1595  fillME(layerMEs.LayerClusWidthVsAmpTH2, cluster.charge, cluster.width);
1596  }
1597 
1598  if (layerswitchclusposon) {
1599  fillME(layerMEs.LayerClusterPosition, cluster.position);
1600  }
1601 }
1602 //------------------------------------------------------------------------------------------
1604  DQMStore::IBooker& ibooker) {
1605  edm::ParameterSet ParametersTrend = trendVs10Ls_ ? conf_.getParameter<edm::ParameterSet>("TrendingLS")
1606  : conf_.getParameter<edm::ParameterSet>("Trending");
1607  MonitorElement* me = ibooker.bookProfile(HistoName,
1608  HistoName,
1609  ParametersTrend.getParameter<int32_t>("Nbins"),
1610  ParametersTrend.getParameter<double>("xmin"),
1611  ParametersTrend.getParameter<double>("xmax"),
1612  0,
1613  0,
1614  "");
1615  if (!me)
1616  return me;
1617  me->setAxisTitle(ParametersTrend.getParameter<std::string>("xaxis"), 1);
1618  if (me->kind() == MonitorElement::Kind::TPROFILE)
1619  me->setCanExtend(TH1::kAllAxes);
1620  return me;
1621 }
1622 
1623 //------------------------------------------------------------------------------------------
1625  const char* HistoName,
1626  DQMStore::IBooker& ibooker) {
1627  Parameters = conf_.getParameter<edm::ParameterSet>(ParameterSetLabel);
1628  return ibooker.book1D(HistoName,
1629  HistoName,
1630  Parameters.getParameter<int32_t>("Nbinx"),
1631  Parameters.getParameter<double>("xmin"),
1632  Parameters.getParameter<double>("xmax"));
1633 }
1634 
1635 //------------------------------------------------------------------------------------------
1637  const char* HistoName,
1638  DQMStore::IBooker& ibooker) {
1639  Parameters = conf_.getParameter<edm::ParameterSet>(ParameterSetLabel);
1640  return ibooker.book2D(HistoName,
1641  HistoName,
1642  Parameters.getParameter<int32_t>("Nbinsx"),
1643  Parameters.getParameter<double>("xmin"),
1644  Parameters.getParameter<double>("xmax"),
1645  Parameters.getParameter<int32_t>("Nbinsy"),
1646  Parameters.getParameter<double>("ymin"),
1647  Parameters.getParameter<double>("ymax"));
1648 }
1649 
1650 int SiStripMonitorCluster::FindRegion(int nstrip, int npix) {
1651  double kplus = k0 * (1 + dk0 / 100);
1652  double kminus = k0 * (1 - dk0 / 100);
1653  int region = 0;
1654 
1655  if (nstrip != 0 && npix >= (nstrip * kminus - q0) && npix <= (nstrip * kplus + q0))
1656  region = 1;
1657  else if (nstrip != 0 && npix < (nstrip * kminus - q0) && nstrip <= maxClus)
1658  region = 2;
1659  else if (nstrip != 0 && npix < (nstrip * kminus - q0) && nstrip > maxClus)
1660  region = 3;
1661  else if (nstrip != 0 && npix > (nstrip * kplus + q0))
1662  region = 4;
1663  else if (npix > minPix && nstrip == 0)
1664  region = 5;
1665  return region;
1666 }
RunNumber_t run() const
Definition: EventID.h:38
MonitorElement * GlobalABXTH1_CSCP
void ResetModuleMEs(uint32_t idet)
int FindRegion(int nstrip, int npixel)
void getTIBDetectors(const std::vector< uint32_t > &inputDetRawIds, std::vector< uint32_t > &tibDetRawIds, const TrackerTopology *trackerTopology, uint32_t layer=0, uint32_t bkw_frw=0, uint32_t int_ext=0, uint32_t string=0)
MonitorElement * bookProfile2D(TString const &name, TString const &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, double lowZ, double highZ, char const *option="s", FUNC onbooking=NOOP())
Definition: DQMStore.h:399
edm::ESGetToken< SiStripDetCabling, SiStripDetCablingRcd > siStripDetCablingRunToken_
MonitorElement * NumberOfPixelClus_vs_BX
void addActiveDetectorsRawIds(std::vector< uint32_t > &) const
virtual DQM_DEPRECATED void setCanExtend(unsigned int value)
void setSiStripFolderName(std::string name)
MonitorElement * PixVsStripMultiplicityRegions
std::pair< const std::string, const char * > getSubDetFolderAndTag(const uint32_t &detid, const TrackerTopology *tTopo)
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e< void, edm::EventIDconst &, edm::Timestampconst & > We also list in braces which AR_WATCH_USING_METHOD_ is used for those or
Definition: Activities.doc:12
virtual void setCurrentFolder(std::string const &fullpath)
Definition: DQMStore.cc:32
MonitorElement * GlobalTH2MainDiagonalPosition_vs_BX
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:539
edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > trackerTopologyEventToken_
edm::ESGetToken< SiStripQuality, SiStripQualityRcd > siStripQualityToken_
MonitorElement * GlobalCStripVsCpix
bool IsStripBad(const uint32_t &detid, const short &strip) const
void getTIDDetectors(const std::vector< uint32_t > &inputDetRawIds, std::vector< uint32_t > &tidDetRawIds, const TrackerTopology *trackerTopology, uint32_t side=0, uint32_t wheel=0, uint32_t ring=0, uint32_t ster=0)
Kind kind() const
Get the type of the monitor element.
MonitorElement * ClusterSignalOverNoiseVsPos
void setLayerFolder(uint32_t rawdetid, const TrackerTopology *tTopo, int32_t layer=0, bool ring_flag=false)
Provides a code based selection for trigger and DCS information in order to have no failing filters i...
MonitorElement * StripNoise2Cycle
data_type const * const_iterator
Definition: DetSetNew.h:31
void createLayerMEs(std::string label, int ndets, DQMStore::IBooker &ibooker)
EventAuxiliary const & eventAuxiliary() const override
Definition: Event.h:95
void getTECDetectors(const std::vector< uint32_t > &inputDetRawIds, std::vector< uint32_t > &tecDetRawIds, const TrackerTopology *trackerTopology, uint32_t side=0, uint32_t wheel=0, uint32_t petal_bkw_frw=0, uint32_t petal=0, uint32_t ring=0, uint32_t ster=0)
std::map< std::string, LayerMEs > LayerMEsMap
void analyze(const edm::Event &, const edm::EventSetup &) override
bool isRealData() const
Definition: EventBase.h:62
LuminosityBlockNumber_t luminosityBlock() const
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
MonitorElement * NumberOfPixelClus
void setDetectorFolder(uint32_t rawdetid, const TrackerTopology *tTopo)
unsigned long long m_cacheID_
void Fill(long long x)
void createSubDetMEs(std::string label, DQMStore::IBooker &ibooker)
bool getData(T &iHolder) const
Definition: EventSetup.h:128
const std::vector< const FedChannelConnection * > & getConnections(uint32_t det_id) const
virtual void Reset()
Remove all data from the ME, keept the empty histogram with all its settings.
std::map< uint32_t, ModMEs > ModuleMEsMap
bool getStatus(edm::Event const &e, edm::EventSetup const &eSetup)
char const * label
static float getNoise(uint16_t strip, const Range &range)
Definition: SiStripNoises.h:73
int iEvent
Definition: GenABIO.cc:224
void createMEs(const edm::EventSetup &es, DQMStore::IBooker &ibooker)
std::map< std::string, std::string > SubDetPhasePartMap
MonitorElement * GlobalApvCycleDBxTH2
auto size() const
vector< ParameterSet > Parameters
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
static float getStripGain(const uint16_t &strip, const SiStripApvGain::Range &range)
Definition: SiStripGain.h:77
void Fill(HcalDetId &id, double val, std::vector< TH2F > &depth)
GenericTriggerEventFlag * genTriggerEventFlagPixelDCSfilter_
T sqrt(T t)
Definition: SSEVec.h:19
bool accept(const edm::Event &event, const edm::EventSetup &setup)
To be called from analyze/filter() methods.
MonitorElement * bookMETrend(const char *, DQMStore::IBooker &ibooker)
edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > trackerTopologyRunToken_
std::vector< uint32_t > activeDets
bool empty() const
Definition: DetSetNew.h:70
edm::ESGetToken< SiStripDetCabling, SiStripDetCablingRcd > siStripDetCablingEventToken_
data_type const * data(size_t cell) const
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
std::pair< ContainerIterator, ContainerIterator > Range
int orbitNumber() const
Definition: EventBase.h:65
MonitorElement * NumberOfStripClus
void createModuleMEs(ModMEs &mod_single, uint32_t detid, DQMStore::IBooker &ibooker, const SiStripDetCabling &)
std::string getSubdetid(uint32_t id, const TrackerTopology *tTopo, bool flag_ring)
MonitorElement * GlobalMainDiagonalPosition_vs_BX
bool isValid() const
Definition: HandleBase.h:70
MonitorElement * NumberOfStripClus_vs_BX
virtual void setBinLabel(int bin, const std::string &label, int axis=1)
set bin label for x, y or z axis (axis=1, 2, 3 respectively)
edm::EDGetTokenT< EventWithHistory > historyProducerToken_
MonitorElement * bookME2D(const char *ParameterSetLabel, const char *HistoName, DQMStore::IBooker &ibooker)
MonitorElement * ClusWidthVsAmpTH2
edm::ESGetToken< SiStripNoises, SiStripNoisesRcd > siStripNoisesToken_
MonitorElement * GlobalMainDiagonalPosition
SiStripHistoId hidmanager
__shared__ int noise
Log< level::Info, false > LogInfo
boost::transform_iterator< IterHelp, const_IdIter > const_iterator
SiStripDCSStatus * dcsStatus_
bool failedToGet() const
Definition: HandleBase.h:72
GenericTriggerEventFlag * genTriggerEventFlagBPTXfilter_
MonitorElement * LayerNumberOfClusterPerRingTrend
void fillME(MonitorElement *ME, float value1)
SiStripMonitorCluster(const edm::ParameterSet &)
T const * product() const
Definition: Handle.h:70
std::string createHistoId(std::string description, std::string id_type, uint32_t component_id)
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
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
SiStripFolderOrganizer folder_organizer
virtual DQM_DEPRECATED void setStatOverflows(bool value)
MonitorElement * NumberOfFEDClus
std::string HistoName
MonitorElement * StripNoise3Cycle
std::pair< std::string, int32_t > GetSubDetAndLayer(const uint32_t &detid, const TrackerTopology *tTopo, bool ring_flag=false)
edm::ESGetToken< SiStripGain, SiStripGainRcd > siStripGainToken_
const uint16_t nApvPairs(uint32_t det_id) const
edm::EventID id() const
Definition: EventBase.h:59
const Range getRange(const uint32_t detID) const
iterator end()
Definition: DetSetNew.h:56
edm::EDGetTokenT< edmNew::DetSetVector< SiPixelCluster > > clusterProducerPixToken_
std::map< std::string, SubDetMEs > SubDetMEsMap
const Range getRange(const uint32_t detID) const
void fillLayerMEs(LayerMEs &, ClusterProperties &cluster)
std::pair< ContainerIterator, ContainerIterator > Range
T get() const
Definition: EventSetup.h:88
std::unique_ptr< TkHistoMap > tkmapcluster
edm::EDGetTokenT< edmNew::DetSetVector< SiStripCluster > > clusterProducerStripToken_
void initRun(const edm::Run &run, const edm::EventSetup &setup)
To be called from beginRun() methods.
void getTOBDetectors(const std::vector< uint32_t > &inputDetRawIds, std::vector< uint32_t > &tobDetRawIds, const TrackerTopology *trackerTopology, uint32_t layer=0, uint32_t bkw_frw=0, uint32_t rod=0)
std::string createHistoLayer(std::string description, std::string id_type, std::string path, std::string flag)
std::pair< ContainerIterator, ContainerIterator > Range
Definition: SiStripNoises.h:47
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
Definition: DQMStore.h:98
size_type size() const
Definition: DetSetNew.h:68
std::map< std::string, std::vector< uint32_t > > LayerDetMap
edm::ESGetToken< TkDetMap, TrackerTopologyRcd > tkDetMapToken_
std::unique_ptr< TkHistoMap > tkmapclusterch
MonitorElement * GlobalDBxCycleTH1
edm::EDGetTokenT< APVCyclePhaseCollection > apvPhaseProducerToken_
void dqmBeginRun(const edm::Run &, const edm::EventSetup &) override
GenericTriggerEventFlag * genTriggerEventFlagStripDCSfilter_
MonitorElement * NclusVsCycleTimeProf2D
MonitorElement * bookME1D(const char *ParameterSetLabel, const char *HistoName, DQMStore::IBooker &ibooker)
void fillModuleMEs(ModMEs &mod_mes, ClusterProperties &cluster)
Definition: Run.h:45
const SiStripApvGain::Range getRange(uint32_t detID) const
Definition: SiStripGain.h:75
int size() const
virtual void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
iterator begin()
Definition: DetSetNew.h:54