CMS 3D CMS Logo

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

#include <DTt0DBValidation.h>

Inheritance diagram for DTt0DBValidation:
edm::one::EDAnalyzer< edm::one::SharedResources, edm::one::WatchRuns > edm::one::EDAnalyzerBase edm::EDConsumerBase

Public Types

typedef dqm::legacy::DQMStore DQMStore
 
typedef dqm::legacy::MonitorElement MonitorElement
 
- Public Types inherited from edm::one::EDAnalyzerBase
typedef EDAnalyzerBase ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 

Public Member Functions

void analyze (const edm::Event &event, const edm::EventSetup &setup) override
 
void beginRun (const edm::Run &run, const edm::EventSetup &setup) override
 Operations. More...
 
 DTt0DBValidation (const edm::ParameterSet &pset)
 Constructor. More...
 
void endJob () override
 
void endRun (edm::Run const &, edm::EventSetup const &) override
 
 ~DTt0DBValidation () override
 Destructor. More...
 
- Public Member Functions inherited from edm::one::EDAnalyzer< edm::one::SharedResources, edm::one::WatchRuns >
 EDAnalyzer ()=default
 
 EDAnalyzer (const EDAnalyzer &)=delete
 
SerialTaskQueueglobalLuminosityBlocksQueue () final
 
SerialTaskQueueglobalRunsQueue () final
 
const EDAnalyzeroperator= (const EDAnalyzer &)=delete
 
bool wantsGlobalLuminosityBlocks () const noexcept final
 
bool wantsGlobalRuns () const noexcept final
 
bool wantsInputProcessBlocks () const noexcept final
 
bool wantsProcessBlocks () const noexcept final
 
- Public Member Functions inherited from edm::one::EDAnalyzerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzerBase ()
 
ModuleDescription const & moduleDescription () const
 
bool wantsStreamLuminosityBlocks () const noexcept
 
bool wantsStreamRuns () const noexcept
 
 ~EDAnalyzerBase () override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
 EDConsumerBase (EDConsumerBase &&)=default
 
ESResolverIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESResolverIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex > const & esGetTokenRecordIndicesVector (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector< ProductResolverIndexAndSkipBit > const & itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::array< std::vector< ModuleDescription const *> *, NumBranchTypes > &modulesAll, std::vector< ModuleProcessName > &modulesInPreviousProcesses, ProductRegistry const &preg, std::map< std::string, ModuleDescription const *> const &labelsToDesc, std::string const &processName) const
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
void selectInputProcessBlocks (ProductRegistry const &productRegistry, ProcessBlockHelperBase const &processBlockHelperBase)
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProductResolverIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Private Member Functions

void bookHistos (DTLayerId lId, int firstWire, int lastWire)
 
void bookHistos (int wheel)
 

Private Attributes

DQMStoredbe_
 
const DTGeometrydtGeom
 
edm::ESGetToken< DTT0, DTT0RcdlabelDB_
 
edm::ESGetToken< DTT0, DTT0RcdlabelDBRef_
 
std::string metname_
 
edm::ESGetToken< DTGeometry, MuonGeometryRecordmuonGeomToken_
 
std::string outputFileName_
 
bool outputMEsInRootFile_
 
std::map< DTLayerId, MonitorElement * > t0DiffHistos_
 
std::map< DTWireId, std::vector< float > > t0Map_
 
std::map< DTWireId, std::vector< float > > t0RefMap_
 
std::string t0TestName_
 
const DTT0tZeroMap_
 
const DTT0tZeroRefMap_
 
std::map< int, MonitorElement * > wheelSummary_
 

Additional Inherited Members

- Static Public Member Functions inherited from edm::one::EDAnalyzerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B = InEvent>
EDConsumerBaseAdaptor< Bconsumes (edm::InputTag tag) noexcept
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
constexpr auto esConsumes ()
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag)
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
void resetItemsToGetFrom (BranchType iType)
 

Detailed Description

Plot the t0 from the DB

Author
G. Mila - INFN Torino

Definition at line 32 of file DTt0DBValidation.h.

Member Typedef Documentation

◆ DQMStore

Definition at line 35 of file DTt0DBValidation.h.

◆ MonitorElement

Definition at line 34 of file DTt0DBValidation.h.

Constructor & Destructor Documentation

◆ DTt0DBValidation()

DTt0DBValidation::DTt0DBValidation ( const edm::ParameterSet pset)

Constructor.

Definition at line 35 of file DTt0DBValidation.cc.

References dbe_, metname_, Utilities::operator, outputFileName_, outputMEsInRootFile_, muonDTDigis_cfi::pset, dqm::implementation::DQMStore::setCurrentFolder(), AlCaHLTBitMon_QueryRunRegistry::string, and t0TestName_.

36  : labelDBRef_(esConsumes(edm::ESInputTag("", pset.getParameter<string>("labelDBRef")))),
37  labelDB_(esConsumes(edm::ESInputTag("", pset.getParameter<string>("labelDB")))),
39  metname_ = "InterChannelSynchDBValidation";
40  LogVerbatim(metname_) << "[DTt0DBValidation] Constructor called!";
41 
42  // Get the DQM needed services
43  usesResource("DQMStore");
45  dbe_->setCurrentFolder("DT/DtCalib/InterChannelSynchDBValidation");
46 
47  t0TestName_ = "t0DifferenceInRange";
48  if (pset.exists("t0TestName"))
49  t0TestName_ = pset.getParameter<string>("t0TestName");
50 
51  outputMEsInRootFile_ = false;
52  if (pset.exists("OutputFileName")) {
53  outputMEsInRootFile_ = true;
54  outputFileName_ = pset.getParameter<std::string>("OutputFileName");
55  }
56 }
Log< level::Info, true > LogVerbatim
edm::ESGetToken< DTT0, DTT0Rcd > labelDB_
void setCurrentFolder(std::string const &fullpath) override
Definition: DQMStore.h:656
std::string metname_
std::string outputFileName_
std::string t0TestName_
edm::ESGetToken< DTGeometry, MuonGeometryRecord > muonGeomToken_
edm::ESGetToken< DTT0, DTT0Rcd > labelDBRef_

◆ ~DTt0DBValidation()

DTt0DBValidation::~DTt0DBValidation ( )
override

Destructor.

Definition at line 58 of file DTt0DBValidation.cc.

58 {}

Member Function Documentation

◆ analyze()

void DTt0DBValidation::analyze ( const edm::Event event,
const edm::EventSetup setup 
)
inlineoverridevirtual

Implements edm::one::EDAnalyzerBase.

Definition at line 47 of file DTt0DBValidation.h.

47 {}

◆ beginRun()

void DTt0DBValidation::beginRun ( const edm::Run run,
const edm::EventSetup setup 
)
override

Operations.

Definition at line 60 of file DTt0DBValidation.cc.

References DTT0::begin(), bookHistos(), DTTimeUnits::counts, dtGeom, DTT0::end(), DTTopology::firstChannel(), DTT0::get(), labelDB_, labelDBRef_, DTTopology::lastChannel(), DTGeometry::layer(), LogTrace, genParticles_cff::map, metname_, muonGeomToken_, singleTopDQM_cfi::setup, DTLayer::specificTopology(), t0DiffHistos_, t0Map_, t0RefMap_, tzero, tZeroMap_, tZeroRefMap_, DTT0::version(), makeMuonMisalignmentScenario::wheel, and wheelSummary_.

60  {
61  metname_ = "InterChannelSynchDBValidation";
62  LogVerbatim(metname_) << "[DTt0DBValidation] Parameters initialization";
63 
64  tZeroRefMap_ = &setup.getData(labelDBRef_);
65  ;
66  LogVerbatim(metname_) << "[DTt0DBValidation] reference T0 version: " << tZeroRefMap_->version();
67 
68  tZeroMap_ = &setup.getData(labelDB_);
69  LogVerbatim(metname_) << "[DTt0DBValidation] T0 to validate version: " << tZeroMap_->version();
70 
71  // book&reset the summary histos
72  for (int wheel = -2; wheel <= 2; wheel++) {
74  wheelSummary_[wheel]->Reset();
75  }
76 
77  // Get the geometry
78  dtGeom = &setup.getData(muonGeomToken_);
79 
80  // Loop over Ref DB entries
82  // t0s and rms are TDC counts
83  // @@@ NEW DTT0 FORMAT
84  // DTWireId wireId((*tzero).first.wheelId,
85  // (*tzero).first.stationId,
86  // (*tzero).first.sectorId,
87  // (*tzero).first.slId,
88  // (*tzero).first.layerId,
89  // (*tzero).first.cellId);
90  int channelId = tzero->channelId;
91  if (channelId == 0)
92  continue;
93  DTWireId wireId(channelId);
94  // @@@ NEW DTT0 END
95  float t0mean;
96  float t0rms;
97  tZeroRefMap_->get(wireId, t0mean, t0rms, DTTimeUnits::counts);
98  LogTrace(metname_) << "Ref Wire: " << wireId << endl
99  << " T0 mean (TDC counts): " << t0mean << " T0_rms (TDC counts): " << t0rms;
100 
101  t0RefMap_[wireId].push_back(t0mean);
102  t0RefMap_[wireId].push_back(t0rms);
103  }
104 
105  // Loop over Ref DB entries
107  // t0s and rms are TDC counts
108  // @@@ NEW DTT0 FORMAT
109  // DTWireId wireId((*tzero).first.wheelId,
110  // (*tzero).first.stationId,
111  // (*tzero).first.sectorId,
112  // (*tzero).first.slId,
113  // (*tzero).first.layerId,
114  // (*tzero).first.cellId);
115  int channelId = tzero->channelId;
116  if (channelId == 0)
117  continue;
118  DTWireId wireId(channelId);
119  // @@@ NEW DTT0 END
120  float t0mean;
121  float t0rms;
122  tZeroMap_->get(wireId, t0mean, t0rms, DTTimeUnits::counts);
123  LogTrace(metname_) << "Wire: " << wireId << endl
124  << " T0 mean (TDC counts): " << t0mean << " T0_rms (TDC counts): " << t0rms;
125 
126  t0Map_[wireId].push_back(t0mean);
127  t0Map_[wireId].push_back(t0rms);
128  }
129 
130  double difference = 0;
131  for (map<DTWireId, vector<float>>::const_iterator theMap = t0RefMap_.begin(); theMap != t0RefMap_.end(); theMap++) {
132  if (t0Map_.find((*theMap).first) != t0Map_.end()) {
133  // Compute the difference
134  difference = t0Map_[(*theMap).first][0] - (*theMap).second[0];
135 
136  // book histo
137  DTLayerId layerId = (*theMap).first.layerId();
138  if (t0DiffHistos_.find(layerId) == t0DiffHistos_.end()) {
139  const DTTopology &dtTopo = dtGeom->layer(layerId)->specificTopology();
140  const int firstWire = dtTopo.firstChannel();
141  const int lastWire = dtTopo.lastChannel();
142  bookHistos(layerId, firstWire, lastWire);
143  }
144 
145  LogTrace(metname_) << "Filling the histo for wire: " << (*theMap).first << " difference: " << difference;
146  t0DiffHistos_[layerId]->Fill((*theMap).first.wire(), difference);
147  }
148  } // Loop over the t0 map reference
149 }
Log< level::Info, true > LogVerbatim
std::map< DTLayerId, MonitorElement * > t0DiffHistos_
edm::ESGetToken< DTT0, DTT0Rcd > labelDB_
std::map< int, MonitorElement * > wheelSummary_
const DTT0 * tZeroRefMap_
const_iterator end() const
Definition: DTT0.cc:147
std::string metname_
std::vector< DTT0Data >::const_iterator const_iterator
Access methods to data.
Definition: DTT0.h:122
#define LogTrace(id)
const_iterator begin() const
Definition: DTT0.cc:145
int firstChannel() const
Returns the wire number of the first wire.
Definition: DTTopology.h:79
std::map< DTWireId, std::vector< float > > t0RefMap_
const DTTopology & specificTopology() const
Definition: DTLayer.cc:37
const DTT0 * tZeroMap_
edm::ESGetToken< DTGeometry, MuonGeometryRecord > muonGeomToken_
const DTGeometry * dtGeom
const std::string & version() const
access version
Definition: DTT0.cc:82
edm::ESGetToken< DTT0, DTT0Rcd > labelDBRef_
int get(int wheelId, int stationId, int sectorId, int slId, int layerId, int cellId, float &t0mean, float &t0rms, DTTimeUnits::type unit) const
Definition: DTT0.cc:48
std::map< DTWireId, std::vector< float > > t0Map_
void bookHistos(DTLayerId lId, int firstWire, int lastWire)
int lastChannel() const
Returns the wire number of the last wire.
Definition: DTTopology.h:81
static const double tzero[3]
const DTLayer * layer(const DTLayerId &id) const
Return a layer given its id.
Definition: DTGeometry.cc:96

◆ bookHistos() [1/2]

void DTt0DBValidation::bookHistos ( DTLayerId  lId,
int  firstWire,
int  lastWire 
)
private

Definition at line 187 of file DTt0DBValidation.cc.

References dqm::implementation::IBooker::book1D(), DTSuperLayerId::chamberId(), dbe_, nano_mu_digi_cff::layer, DTLayerId::layer(), LogTrace, metname_, nano_mu_digi_cff::sector, DTChamberId::sector(), dqm::implementation::DQMStore::setCurrentFolder(), DTChamberId::station(), relativeConstraints::station, nano_mu_digi_cff::superLayer, DTSuperLayerId::superlayer(), DTLayerId::superlayerId(), t0DiffHistos_, DTChamberId::wheel(), and makeMuonMisalignmentScenario::wheel.

Referenced by beginRun().

187  {
188  LogTrace(metname_) << " Booking histos for L: " << lId;
189 
190  // Compose the chamber name
191  stringstream wheel;
192  wheel << lId.superlayerId().chamberId().wheel();
193  stringstream station;
194  station << lId.superlayerId().chamberId().station();
195  stringstream sector;
196  sector << lId.superlayerId().chamberId().sector();
197  stringstream superLayer;
199  stringstream layer;
200  layer << lId.layer();
201 
202  string lHistoName = "_W" + wheel.str() + "_St" + station.str() + "_Sec" + sector.str() + "_SL" + superLayer.str() +
203  "_L" + layer.str();
204 
205  dbe_->setCurrentFolder("DT/DtCalib/InterChannelSynchDBValidation/Wheel" + wheel.str() + "/Station" + station.str() +
206  "/Sector" + sector.str() + "/SuperLayer" + superLayer.str());
207  // Create the monitor elements
208  MonitorElement *hDifference;
209  hDifference = dbe_->book1D("T0Difference" + lHistoName,
210  "difference between the two t0 values",
211  lastWire - firstWire + 1,
212  firstWire - 0.5,
213  lastWire + 0.5);
214 
215  t0DiffHistos_[lId] = hDifference;
216 }
int station() const
Return the station number.
Definition: DTChamberId.h:45
std::map< DTLayerId, MonitorElement * > t0DiffHistos_
void setCurrentFolder(std::string const &fullpath) override
Definition: DQMStore.h:656
std::string metname_
#define LogTrace(id)
DTChamberId chamberId() const
Return the corresponding ChamberId.
int superlayer() const
Return the superlayer number (deprecated method name)
int layer() const
Return the layer number.
Definition: DTLayerId.h:45
int wheel() const
Return the wheel number.
Definition: DTChamberId.h:42
int sector() const
Definition: DTChamberId.h:52
DTSuperLayerId superlayerId() const
Return the corresponding SuperLayerId.
Definition: DTLayerId.h:48
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
Definition: DQMStore.h:98

◆ bookHistos() [2/2]

void DTt0DBValidation::bookHistos ( int  wheel)
private

Definition at line 219 of file DTt0DBValidation.cc.

References dqm::implementation::IBooker::book2D(), dbe_, dqm::implementation::DQMStore::setCurrentFolder(), makeMuonMisalignmentScenario::wheel, and wheelSummary_.

219  {
220  dbe_->setCurrentFolder("DT/DtCalib/InterChannelSynchDBValidation");
221  stringstream wh;
222  wh << wheel;
224  "SummaryWrongT0_W" + wh.str(), "W" + wh.str() + ": summary of wrong t0 differences", 44, 1, 45, 14, 1, 15);
225  wheelSummary_[wheel]->setBinLabel(1, "M1L1", 1);
226  wheelSummary_[wheel]->setBinLabel(2, "M1L2", 1);
227  wheelSummary_[wheel]->setBinLabel(3, "M1L3", 1);
228  wheelSummary_[wheel]->setBinLabel(4, "M1L4", 1);
229  wheelSummary_[wheel]->setBinLabel(5, "M1L5", 1);
230  wheelSummary_[wheel]->setBinLabel(6, "M1L6", 1);
231  wheelSummary_[wheel]->setBinLabel(7, "M1L7", 1);
232  wheelSummary_[wheel]->setBinLabel(8, "M1L8", 1);
233  wheelSummary_[wheel]->setBinLabel(9, "M1L9", 1);
234  wheelSummary_[wheel]->setBinLabel(10, "M1L10", 1);
235  wheelSummary_[wheel]->setBinLabel(11, "M1L11", 1);
236  wheelSummary_[wheel]->setBinLabel(12, "M1L12", 1);
237  wheelSummary_[wheel]->setBinLabel(13, "M2L1", 1);
238  wheelSummary_[wheel]->setBinLabel(14, "M2L2", 1);
239  wheelSummary_[wheel]->setBinLabel(15, "M2L3", 1);
240  wheelSummary_[wheel]->setBinLabel(16, "M2L4", 1);
241  wheelSummary_[wheel]->setBinLabel(17, "M2L5", 1);
242  wheelSummary_[wheel]->setBinLabel(18, "M2L6", 1);
243  wheelSummary_[wheel]->setBinLabel(19, "M2L7", 1);
244  wheelSummary_[wheel]->setBinLabel(20, "M2L8", 1);
245  wheelSummary_[wheel]->setBinLabel(21, "M2L9", 1);
246  wheelSummary_[wheel]->setBinLabel(22, "M2L10", 1);
247  wheelSummary_[wheel]->setBinLabel(23, "M2L11", 1);
248  wheelSummary_[wheel]->setBinLabel(24, "M2L12", 1);
249  wheelSummary_[wheel]->setBinLabel(25, "M3L1", 1);
250  wheelSummary_[wheel]->setBinLabel(26, "M3L2", 1);
251  wheelSummary_[wheel]->setBinLabel(27, "M3L3", 1);
252  wheelSummary_[wheel]->setBinLabel(28, "M3L4", 1);
253  wheelSummary_[wheel]->setBinLabel(29, "M3L5", 1);
254  wheelSummary_[wheel]->setBinLabel(30, "M3L6", 1);
255  wheelSummary_[wheel]->setBinLabel(31, "M3L7", 1);
256  wheelSummary_[wheel]->setBinLabel(32, "M3L8", 1);
257  wheelSummary_[wheel]->setBinLabel(33, "M3L9", 1);
258  wheelSummary_[wheel]->setBinLabel(34, "M3L10", 1);
259  wheelSummary_[wheel]->setBinLabel(35, "M3L11", 1);
260  wheelSummary_[wheel]->setBinLabel(36, "M3L12", 1);
261  wheelSummary_[wheel]->setBinLabel(37, "M4L1", 1);
262  wheelSummary_[wheel]->setBinLabel(38, "M4L2", 1);
263  wheelSummary_[wheel]->setBinLabel(39, "M4L3", 1);
264  wheelSummary_[wheel]->setBinLabel(40, "M4L4", 1);
265  wheelSummary_[wheel]->setBinLabel(41, "M4L5", 1);
266  wheelSummary_[wheel]->setBinLabel(42, "M4L6", 1);
267  wheelSummary_[wheel]->setBinLabel(43, "M4L7", 1);
268  wheelSummary_[wheel]->setBinLabel(44, "M4L8", 1);
269 }
std::map< int, MonitorElement * > wheelSummary_
void setCurrentFolder(std::string const &fullpath) override
Definition: DQMStore.h:656
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:221

◆ endJob()

void DTt0DBValidation::endJob ( void  )
overridevirtual

Reimplemented from edm::one::EDAnalyzerBase.

Definition at line 180 of file DTt0DBValidation.cc.

References dbe_, outputFileName_, outputMEsInRootFile_, and dqm::implementation::DQMStore::save().

180  {
181  // Write the histos on a file
184 }
std::string outputFileName_
DQM_DEPRECATED void save(std::string const &filename, std::string const &path="")
Definition: DQMStore.cc:824

◆ endRun()

void DTt0DBValidation::endRun ( edm::Run const &  run,
edm::EventSetup const &  setup 
)
override

Definition at line 151 of file DTt0DBValidation.cc.

References MonitorElementData::QReport::getBadChannels(), MonitorElementData::QReport::getMessage(), MonitorElementData::QReport::getQTresult(), MonitorElementData::QReport::getStatus(), metname_, t0DiffHistos_, t0TestName_, wheelSummary_, and photonAnalyzer_cfi::xBin.

151  {
152  // Check the histos
153  string testCriterionName = t0TestName_;
154  for (map<DTLayerId, MonitorElement *>::const_iterator hDiff = t0DiffHistos_.begin(); hDiff != t0DiffHistos_.end();
155  hDiff++) {
156  const QReport *theDiffQReport = (*hDiff).second->getQReport(testCriterionName);
157  if (theDiffQReport) {
158  int xBin = ((*hDiff).first.station() - 1) * 12 + (*hDiff).first.layer() + 4 * ((*hDiff).first.superlayer() - 1);
159  if ((*hDiff).first.station() == 4 && (*hDiff).first.superlayer() == 3)
160  xBin = ((*hDiff).first.station() - 1) * 12 + (*hDiff).first.layer() + 4 * ((*hDiff).first.superlayer() - 2);
161 
162  int qReportStatus = theDiffQReport->getStatus() / 100;
163  wheelSummary_[(*hDiff).first.wheel()]->setBinContent(xBin, (*hDiff).first.sector(), qReportStatus);
164 
165  LogVerbatim(metname_) << "-------- layer: " << (*hDiff).first << " " << theDiffQReport->getMessage()
166  << " ------- " << theDiffQReport->getStatus() << " ------- " << setprecision(3)
167  << theDiffQReport->getQTresult();
168  vector<dqm::me_util::Channel> badChannels = theDiffQReport->getBadChannels();
169  for (vector<dqm::me_util::Channel>::iterator channel = badChannels.begin(); channel != badChannels.end();
170  channel++) {
171  LogVerbatim(metname_) << "layer: " << (*hDiff).first << " Bad channel: " << (*channel).getBin()
172  << " Contents : " << (*channel).getContents();
173 
174  // wheelSummary_[(*hDiff).first.wheel()]->Fill(xBin,(*hDiff).first.sector());
175  }
176  }
177  }
178 }
Log< level::Info, true > LogVerbatim
std::map< DTLayerId, MonitorElement * > t0DiffHistos_
std::map< int, MonitorElement * > wheelSummary_
float getQTresult() const
get test result i.e. prob value
const std::vector< DQMChannel > & getBadChannels() const
std::string metname_
std::string t0TestName_
const std::string & getMessage() const
get message attached to test
int getStatus() const
get test status

Member Data Documentation

◆ dbe_

DQMStore* DTt0DBValidation::dbe_
private

Definition at line 53 of file DTt0DBValidation.h.

Referenced by bookHistos(), DTt0DBValidation(), and endJob().

◆ dtGeom

const DTGeometry* DTt0DBValidation::dtGeom
private

Definition at line 68 of file DTt0DBValidation.h.

Referenced by beginRun().

◆ labelDB_

edm::ESGetToken<DTT0, DTT0Rcd> DTt0DBValidation::labelDB_
private

Definition at line 58 of file DTt0DBValidation.h.

Referenced by beginRun().

◆ labelDBRef_

edm::ESGetToken<DTT0, DTT0Rcd> DTt0DBValidation::labelDBRef_
private

Definition at line 57 of file DTt0DBValidation.h.

Referenced by beginRun().

◆ metname_

std::string DTt0DBValidation::metname_
private

Definition at line 55 of file DTt0DBValidation.h.

Referenced by beginRun(), bookHistos(), DTt0DBValidation(), and endRun().

◆ muonGeomToken_

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

Definition at line 67 of file DTt0DBValidation.h.

Referenced by beginRun().

◆ outputFileName_

std::string DTt0DBValidation::outputFileName_
private

Definition at line 62 of file DTt0DBValidation.h.

Referenced by DTt0DBValidation(), and endJob().

◆ outputMEsInRootFile_

bool DTt0DBValidation::outputMEsInRootFile_
private

Definition at line 61 of file DTt0DBValidation.h.

Referenced by DTt0DBValidation(), and endJob().

◆ t0DiffHistos_

std::map<DTLayerId, MonitorElement *> DTt0DBValidation::t0DiffHistos_
private

Definition at line 79 of file DTt0DBValidation.h.

Referenced by beginRun(), bookHistos(), and endRun().

◆ t0Map_

std::map<DTWireId, std::vector<float> > DTt0DBValidation::t0Map_
private

Definition at line 76 of file DTt0DBValidation.h.

Referenced by beginRun().

◆ t0RefMap_

std::map<DTWireId, std::vector<float> > DTt0DBValidation::t0RefMap_
private

Definition at line 75 of file DTt0DBValidation.h.

Referenced by beginRun().

◆ t0TestName_

std::string DTt0DBValidation::t0TestName_
private

Definition at line 64 of file DTt0DBValidation.h.

Referenced by DTt0DBValidation(), and endRun().

◆ tZeroMap_

const DTT0* DTt0DBValidation::tZeroMap_
private

Definition at line 72 of file DTt0DBValidation.h.

Referenced by beginRun().

◆ tZeroRefMap_

const DTT0* DTt0DBValidation::tZeroRefMap_
private

Definition at line 71 of file DTt0DBValidation.h.

Referenced by beginRun().

◆ wheelSummary_

std::map<int, MonitorElement *> DTt0DBValidation::wheelSummary_
private

Definition at line 82 of file DTt0DBValidation.h.

Referenced by beginRun(), bookHistos(), and endRun().