CMS 3D CMS Logo

List of all members | Classes | Public Types | Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes
SiStripDcsInfo Class Reference

#include <SiStripDcsInfo.h>

Inheritance diagram for SiStripDcsInfo:
edm::EDAnalyzer edm::EDConsumerBase

Classes

struct  SubDetMEs
 

Public Types

typedef dqm::harvesting::DQMStore DQMStore
 
typedef dqm::harvesting::MonitorElement MonitorElement
 
- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 

Public Member Functions

 SiStripDcsInfo (const edm::ParameterSet &ps)
 
- Public Member Functions inherited from edm::EDAnalyzer
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzer ()
 
SerialTaskQueueglobalLuminosityBlocksQueue ()
 
SerialTaskQueueglobalRunsQueue ()
 
ModuleDescription const & moduleDescription () const
 
std::string workerType () const
 
 ~EDAnalyzer () override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase &&)=default
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
ESProxyIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESProxyIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex > const & esGetTokenRecordIndicesVector (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector< ProductResolverIndexAndSkipBit > const & itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::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
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Private Member Functions

void addBadModules (DQMStore &dqm_store)
 
void analyze (edm::Event const &, edm::EventSetup const &) override
 
void beginJob () override
 
void beginLuminosityBlock (edm::LuminosityBlock const &lumiSeg, edm::EventSetup const &eSetup) override
 
void beginRun (edm::Run const &run, edm::EventSetup const &eSetup) override
 
void bookStatus (DQMStore &dqm_store)
 
void endLuminosityBlock (edm::LuminosityBlock const &lumiSeg, edm::EventSetup const &iSetup) override
 
void endRun (edm::Run const &run, edm::EventSetup const &eSetup) override
 
void fillDummyStatus (DQMStore &dqm_store)
 
void fillStatus (DQMStore &dqm_store)
 
void readCabling (edm::EventSetup const &)
 
void readStatus (edm::EventSetup const &, int transition)
 

Private Attributes

bool bookedStatus_ {false}
 
MonitorElementDcsFraction_ {nullptr}
 
const SiStripDetCablingdetCabling_
 
edm::ESGetToken< SiStripDetCabling, SiStripDetCablingRcddetCablingToken_
 
edm::ESGetToken< SiStripDetVOff, SiStripDetVOffRcddetVOffToken0_
 
edm::ESGetToken< SiStripDetVOff, SiStripDetVOffRcddetVOffToken1_
 
edm::ESGetToken< SiStripDetVOff, SiStripDetVOffRcddetVOffToken2_
 
edm::ESWatcher< SiStripFedCablingRcdfedCablingWatcher_
 
bool IsLumiGoodDcs_ {false}
 
unsigned long long m_cacheIDDcs_ {}
 
int nFEDConnected_ {}
 
int nGoodDcsLumi_ {}
 
int nLumiAnalysed_ {}
 
edm::ESGetToken< RunInfo, RunInfoRcdrunInfoToken_
 
std::map< std::string, SubDetMEsSubDetMEsMap {}
 
edm::ESGetToken< TrackerTopology, TrackerTopologyRcdtTopoToken0_
 
edm::ESGetToken< TrackerTopology, TrackerTopologyRcdtTopoToken1_
 
edm::ESGetToken< TrackerTopology, TrackerTopologyRcdtTopoToken2_
 
edm::ESGetToken< TrackerTopology, TrackerTopologyRcdtTopoToken3_
 

Static Private Attributes

static constexpr float MaxAcceptableBadDcsLumi_ {2}
 
static constexpr float MinAcceptableDcsDetFrac_ {0.90}
 

Additional Inherited Members

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

Detailed Description

DQM/SiStripMonitorCluster/interface/SiStripDcsInfo.h

Description: Checks the # of SiStrip FEDs from DAQ Usage: <usage>

Definition at line 50 of file SiStripDcsInfo.h.

Member Typedef Documentation

◆ DQMStore

Definition at line 53 of file SiStripDcsInfo.h.

◆ MonitorElement

Definition at line 52 of file SiStripDcsInfo.h.

Constructor & Destructor Documentation

◆ SiStripDcsInfo()

SiStripDcsInfo::SiStripDcsInfo ( const edm::ParameterSet ps)

Definition at line 22 of file SiStripDcsInfo.cc.

23  : tTopoToken0_(esConsumes<edm::Transition::BeginLuminosityBlock>()),
24  tTopoToken1_(esConsumes<edm::Transition::EndLuminosityBlock>()),
25  tTopoToken2_(esConsumes<edm::Transition::EndRun>()),
26  tTopoToken3_(esConsumes<edm::Transition::BeginRun>()),
27  detVOffToken0_(esConsumes<edm::Transition::BeginLuminosityBlock>()),
28  detVOffToken1_(esConsumes<edm::Transition::EndLuminosityBlock>()),
29  detVOffToken2_(esConsumes<edm::Transition::EndRun>()),
30  detCablingToken_(esConsumes<edm::Transition::BeginRun>()),
31  runInfoToken_(esConsumes<edm::Transition::BeginRun>()) {
32  LogDebug("SiStripDcsInfo") << "SiStripDcsInfo::Deleting SiStripDcsInfo ";
33 }

References LogDebug.

Member Function Documentation

◆ addBadModules()

void SiStripDcsInfo::addBadModules ( DQMStore dqm_store)
private

Definition at line 265 of file SiStripDcsInfo.cc.

265  {
266  dqm_store.cd();
267  std::string mdir = "MechanicalView";
268  if (!SiStripUtility::goToDir(dqm_store, mdir)) {
269  dqm_store.setCurrentFolder("SiStrip/" + mdir);
270  }
271  std::string mechanical_dir = dqm_store.pwd();
272  std::string tag = "DCSError";
273 
274  for (auto const& pr : SubDetMEsMap) {
275  auto const& lumiCountBadModules = pr.second.NLumiDetectorIsFaulty;
276  for (auto const [ibad, nBadLumi] : lumiCountBadModules) {
277  if (nBadLumi <= MaxAcceptableBadDcsLumi_)
278  continue;
279  std::string bad_module_folder = mechanical_dir + "/" + pr.second.folder_name +
280  "/"
281  "BadModuleList";
282  dqm_store.setCurrentFolder(bad_module_folder);
283 
284  std::ostringstream detid_str;
285  detid_str << ibad;
286  std::string full_path = bad_module_folder + "/" + detid_str.str();
287  MonitorElement* me = dqm_store.get(full_path);
288  uint16_t flag = 0;
289  if (me) {
290  flag = me->getIntValue();
291  me->Reset();
292  } else
293  me = dqm_store.bookInt(detid_str.str());
295  me->Fill(flag);
296  }
297  }
298  dqm_store.cd();
299 }

References dqm::implementation::IBooker::bookInt(), dqm::implementation::DQMStore::cd(), RemoveAddSevLevel::flag, dqm::implementation::IGetter::get(), SiStripUtility::goToDir(), MaxAcceptableBadDcsLumi_, hlt_dqm_clientPB-live_cfg::me, dqm::implementation::DQMStore::pwd(), SiStripUtility::setBadModuleFlag(), dqm::implementation::DQMStore::setCurrentFolder(), AlCaHLTBitMon_QueryRunRegistry::string, SubDetMEsMap, and GlobalPosition_Frontier_DevDB_cff::tag.

Referenced by endRun().

◆ analyze()

void SiStripDcsInfo::analyze ( edm::Event const &  event,
edm::EventSetup const &  eSetup 
)
overrideprivatevirtual

Implements edm::EDAnalyzer.

Definition at line 75 of file SiStripDcsInfo.cc.

75 {}

◆ beginJob()

void SiStripDcsInfo::beginJob ( void  )
overrideprivatevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 35 of file SiStripDcsInfo.cc.

35  {
36  // Since SubDetMEs is a struct, using the brace initialization will
37  // zero-initialize all members that are not specified in the call.
38  SubDetMEsMap.emplace("TIB", SubDetMEs{"TIB", nullptr, 0, {}, {}});
39  SubDetMEsMap.emplace("TOB", SubDetMEs{"TOB", nullptr, 0, {}, {}});
40  SubDetMEsMap.emplace("TECB", SubDetMEs{"TEC/MINUS", nullptr, 0, {}, {}});
41  SubDetMEsMap.emplace("TECF", SubDetMEs{"TEC/PLUS", nullptr, 0, {}, {}});
42  SubDetMEsMap.emplace("TIDB", SubDetMEs{"TID/MINUS", nullptr, 0, {}, {}});
43  SubDetMEsMap.emplace("TIDF", SubDetMEs{"TID/PLUS", nullptr, 0, {}, {}});
44 }

References SubDetMEsMap.

◆ beginLuminosityBlock()

void SiStripDcsInfo::beginLuminosityBlock ( edm::LuminosityBlock const &  lumiSeg,
edm::EventSetup const &  eSetup 
)
overrideprivatevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 77 of file SiStripDcsInfo.cc.

77  {
78  LogDebug("SiStripDcsInfo") << "SiStripDcsInfo::beginLuminosityBlock";
79 
80  if (nFEDConnected_ == 0)
81  return;
82 
83  // initialise BadModule list
84  for (auto& subDetME : SubDetMEsMap) {
85  subDetME.second.FaultyDetectors.clear();
86  }
87  readStatus(eSetup, 0);
89 }

References LogDebug, nFEDConnected_, nLumiAnalysed_, readStatus(), and SubDetMEsMap.

◆ beginRun()

void SiStripDcsInfo::beginRun ( edm::Run const &  run,
edm::EventSetup const &  eSetup 
)
overrideprivatevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 48 of file SiStripDcsInfo.cc.

48  {
49  LogDebug("SiStripDcsInfo") << "SiStripDcsInfo:: Begining of Run";
50  nFEDConnected_ = 0;
51  constexpr int siStripFedIdMin{FEDNumbering::MINSiStripFEDID};
52  constexpr int siStripFedIdMax{FEDNumbering::MAXSiStripFEDID};
53 
54  // Count Tracker FEDs from RunInfo
55  //
56  if (eSetup.tryToGet<RunInfoRcd>()) {
57  if (auto sumFED = eSetup.getHandle(runInfoToken_)) {
58  std::vector<int> FedsInIds = sumFED->m_fed_in;
59  for (unsigned int it = 0; it < FedsInIds.size(); ++it) {
60  int fedID = FedsInIds[it];
61  if (fedID >= siStripFedIdMin && fedID <= siStripFedIdMax)
63  }
64  LogDebug("SiStripDcsInfo") << " SiStripDcsInfo :: Connected FEDs " << nFEDConnected_;
65  }
66  }
67 
68  auto& dqm_store = *edm::Service<DQMStore>{};
69  bookStatus(dqm_store);
70  fillDummyStatus(dqm_store);
71  if (nFEDConnected_ > 0)
72  readCabling(eSetup);
73 }

References bookStatus(), fillDummyStatus(), edm::EventSetup::getHandle(), LogDebug, FEDNumbering::MAXSiStripFEDID, FEDNumbering::MINSiStripFEDID, nFEDConnected_, readCabling(), runInfoToken_, and edm::EventSetup::tryToGet().

◆ bookStatus()

void SiStripDcsInfo::bookStatus ( DQMStore dqm_store)
private

Definition at line 117 of file SiStripDcsInfo.cc.

117  {
118  if (bookedStatus_)
119  return;
120 
121  std::string strip_dir = "";
122  SiStripUtility::getTopFolderPath(dqm_store, "SiStrip", strip_dir);
123  if (!strip_dir.empty())
124  dqm_store.setCurrentFolder(strip_dir + "/EventInfo");
125  else
126  dqm_store.setCurrentFolder("SiStrip/EventInfo");
127 
128  auto scope = DQMStore::UseLumiScope(dqm_store);
129 
130  DcsFraction_ = dqm_store.bookFloat("DCSSummary");
131 
132  dqm_store.cd();
133  if (!strip_dir.empty())
134  dqm_store.setCurrentFolder(strip_dir + "/EventInfo/DCSContents");
135  else
136  dqm_store.setCurrentFolder("SiStrip/EventInfo/DCSContents");
137  for (auto& [suffix, subDetME] : SubDetMEsMap) {
138  std::string const me_name{"SiStrip_" + suffix};
139  subDetME.DcsFractionME = dqm_store.bookFloat(me_name);
140  }
141  bookedStatus_ = true;
142  dqm_store.cd();
143 }

References bookedStatus_, dqm::implementation::IBooker::bookFloat(), dqm::implementation::DQMStore::cd(), DcsFraction_, SiStripUtility::getTopFolderPath(), dqm::implementation::DQMStore::setCurrentFolder(), AlCaHLTBitMon_QueryRunRegistry::string, SubDetMEsMap, and createPayload::suffix.

Referenced by beginRun(), fillDummyStatus(), and fillStatus().

◆ endLuminosityBlock()

void SiStripDcsInfo::endLuminosityBlock ( edm::LuminosityBlock const &  lumiSeg,
edm::EventSetup const &  iSetup 
)
overrideprivatevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 91 of file SiStripDcsInfo.cc.

91  {
92  LogDebug("SiStripDcsInfo") << "SiStripDcsInfo::endLuminosityBlock";
93 
94  if (nFEDConnected_ == 0)
95  return;
96  auto& dqm_store = *edm::Service<DQMStore>{};
97  readStatus(eSetup, 1);
98  fillStatus(dqm_store);
99 }

References fillStatus(), LogDebug, nFEDConnected_, and readStatus().

◆ endRun()

void SiStripDcsInfo::endRun ( edm::Run const &  run,
edm::EventSetup const &  eSetup 
)
overrideprivatevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 101 of file SiStripDcsInfo.cc.

101  {
102  LogDebug("SiStripDcsInfo") << "SiStripDcsInfo::EndRun";
103 
104  if (nFEDConnected_ == 0)
105  return;
106 
107  for (auto& subDetME : SubDetMEsMap) {
108  subDetME.second.FaultyDetectors.clear();
109  }
110  readStatus(eSetup, 2);
111  auto& dqm_store = *edm::Service<DQMStore>{};
112  addBadModules(dqm_store);
113 }

References addBadModules(), LogDebug, nFEDConnected_, readStatus(), and SubDetMEsMap.

◆ fillDummyStatus()

void SiStripDcsInfo::fillDummyStatus ( DQMStore dqm_store)
private

Definition at line 252 of file SiStripDcsInfo.cc.

252  {
253  if (!bookedStatus_)
254  bookStatus(dqm_store);
256 
257  for (auto& pr : SubDetMEsMap) {
258  pr.second.DcsFractionME->Reset();
259  pr.second.DcsFractionME->Fill(-1.0);
260  }
261  DcsFraction_->Reset();
262  DcsFraction_->Fill(-1.0);
263 }

References cms::cuda::assert(), bookedStatus_, bookStatus(), DcsFraction_, dqm::impl::MonitorElement::Fill(), dqm::impl::MonitorElement::Reset(), and SubDetMEsMap.

Referenced by beginRun().

◆ fillStatus()

void SiStripDcsInfo::fillStatus ( DQMStore dqm_store)
private

Definition at line 209 of file SiStripDcsInfo.cc.

209  {
210  if (!bookedStatus_)
211  bookStatus(dqm_store);
213 
214  float total_det = 0.0;
215  float faulty_det = 0.0;
216  float fraction;
217  for (auto const& [name, subDetMEs] : SubDetMEsMap) {
218  int total_subdet = subDetMEs.TotalDetectors;
219  int faulty_subdet = subDetMEs.FaultyDetectors.size();
220  if (nFEDConnected_ == 0 || total_subdet == 0)
221  fraction = -1;
222  else
223  fraction = 1.0 - faulty_subdet * 1.0 / total_subdet;
224  subDetMEs.DcsFractionME->Reset();
225  subDetMEs.DcsFractionME->Fill(fraction);
226  edm::LogInfo("SiStripDcsInfo") << " SiStripDcsInfo::fillStatus : Sub Detector " << name << " Total Number "
227  << total_subdet << " Faulty ones " << faulty_subdet;
228  total_det += total_subdet;
229  faulty_det += faulty_subdet;
230  }
231  if (nFEDConnected_ == 0 || total_det == 0)
232  fraction = -1.0;
233  else
234  fraction = 1 - faulty_det / total_det;
235  DcsFraction_->Reset();
238  if (!IsLumiGoodDcs_)
239  return;
240 
241  ++nGoodDcsLumi_;
242  for (auto& pr : SubDetMEsMap) {
243  for (auto const detId_faulty : pr.second.FaultyDetectors) {
244  pr.second.NLumiDetectorIsFaulty[detId_faulty]++;
245  }
246  }
247 }

References cms::cuda::assert(), bookedStatus_, bookStatus(), DcsFraction_, dqm::impl::MonitorElement::Fill(), HLT_FULL_cff::fraction, IsLumiGoodDcs_, MinAcceptableDcsDetFrac_, Skims_PA_cff::name, nFEDConnected_, nGoodDcsLumi_, dqm::impl::MonitorElement::Reset(), and SubDetMEsMap.

Referenced by endLuminosityBlock().

◆ readCabling()

void SiStripDcsInfo::readCabling ( edm::EventSetup const &  eSetup)
private

Definition at line 145 of file SiStripDcsInfo.cc.

145  {
146  const auto tTopo = &eSetup.getData(tTopoToken3_);
147 
148  if (fedCablingWatcher_.check(eSetup)) {
149  LogDebug("SiStripDcsInfo") << "SiStripDcsInfo::readCabling : "
150  << " Change in Cache";
151  detCabling_ = &eSetup.getData(detCablingToken_);
152 
153  std::vector<uint32_t> SelectedDetIds;
154  detCabling_->addActiveDetectorsRawIds(SelectedDetIds);
155  LogDebug("SiStripDcsInfo") << " SiStripDcsInfo::readCabling : "
156  << " Total Detectors " << SelectedDetIds.size();
157 
158  // initialise total # of detectors first
159  for (std::map<std::string, SubDetMEs>::iterator it = SubDetMEsMap.begin(); it != SubDetMEsMap.end(); it++) {
160  it->second.TotalDetectors = 0;
161  }
162 
163  for (std::vector<uint32_t>::const_iterator idetid = SelectedDetIds.begin(); idetid != SelectedDetIds.end();
164  ++idetid) {
165  uint32_t detId = *idetid;
166  if (detId == 0 || detId == 0xFFFFFFFF)
167  continue;
170 
171  std::map<std::string, SubDetMEs>::iterator iPos = SubDetMEsMap.find(subdet_tag);
172  if (iPos != SubDetMEsMap.end()) {
173  iPos->second.TotalDetectors++;
174  }
175  }
176  }
177 }

References SiStripDetCabling::addActiveDetectorsRawIds(), edm::ESWatcher< T >::check(), detCabling_, detCablingToken_, fedCablingWatcher_, edm::EventSetup::getData(), SiStripUtility::getSubDetectorTag(), LogDebug, AlCaHLTBitMon_QueryRunRegistry::string, xuti::subdet_tag(), SubDetMEsMap, and tTopoToken3_.

Referenced by beginRun().

◆ readStatus()

void SiStripDcsInfo::readStatus ( edm::EventSetup const &  eSetup,
int  transition 
)
private

Definition at line 181 of file SiStripDcsInfo.cc.

181  {
182  const auto tTopo = &eSetup.getData(transition == 0 ? tTopoToken0_ : (transition == 1 ? tTopoToken1_ : tTopoToken2_));
183  const auto& detVOff =
184  eSetup.getData(transition == 0 ? detVOffToken0_ : (transition == 1 ? detVOffToken1_ : detVOffToken2_));
185  std::vector<uint32_t> FaultyDetIds;
186  detVOff.getDetIds(FaultyDetIds);
187  LogDebug("SiStripDcsInfo") << " SiStripDcsInfo::readStatus : "
188  << " Faulty Detectors " << FaultyDetIds.size();
189  // Read and fille bad modules
190  for (std::vector<uint32_t>::const_iterator ihvoff = FaultyDetIds.begin(); ihvoff != FaultyDetIds.end(); ++ihvoff) {
191  uint32_t detId_hvoff = (*ihvoff);
192  if (!detCabling_->IsConnected(detId_hvoff))
193  continue;
195  SiStripUtility::getSubDetectorTag(detId_hvoff, subdet_tag, tTopo);
196 
197  std::map<std::string, SubDetMEs>::iterator iPos = SubDetMEsMap.find(subdet_tag);
198  if (iPos != SubDetMEsMap.end()) {
199  std::vector<uint32_t>::iterator ibad =
200  std::find(iPos->second.FaultyDetectors.begin(), iPos->second.FaultyDetectors.end(), detId_hvoff);
201  if (ibad == iPos->second.FaultyDetectors.end())
202  iPos->second.FaultyDetectors.push_back(detId_hvoff);
203  }
204  }
205 }

References detCabling_, detVOffToken0_, detVOffToken1_, detVOffToken2_, spr::find(), edm::EventSetup::getData(), SiStripUtility::getSubDetectorTag(), SiStripDetCabling::IsConnected(), LogDebug, AlCaHLTBitMon_QueryRunRegistry::string, xuti::subdet_tag(), SubDetMEsMap, tTopoToken0_, tTopoToken1_, and tTopoToken2_.

Referenced by beginLuminosityBlock(), endLuminosityBlock(), and endRun().

Member Data Documentation

◆ bookedStatus_

bool SiStripDcsInfo::bookedStatus_ {false}
private

Definition at line 84 of file SiStripDcsInfo.h.

Referenced by bookStatus(), fillDummyStatus(), and fillStatus().

◆ DcsFraction_

MonitorElement* SiStripDcsInfo::DcsFraction_ {nullptr}
private

Definition at line 72 of file SiStripDcsInfo.h.

Referenced by bookStatus(), fillDummyStatus(), and fillStatus().

◆ detCabling_

const SiStripDetCabling* SiStripDcsInfo::detCabling_
private

Definition at line 95 of file SiStripDcsInfo.h.

Referenced by readCabling(), and readStatus().

◆ detCablingToken_

edm::ESGetToken<SiStripDetCabling, SiStripDetCablingRcd> SiStripDcsInfo::detCablingToken_
private

Definition at line 99 of file SiStripDcsInfo.h.

Referenced by readCabling().

◆ detVOffToken0_

edm::ESGetToken<SiStripDetVOff, SiStripDetVOffRcd> SiStripDcsInfo::detVOffToken0_
private

Definition at line 97 of file SiStripDcsInfo.h.

Referenced by readStatus().

◆ detVOffToken1_

edm::ESGetToken<SiStripDetVOff, SiStripDetVOffRcd> SiStripDcsInfo::detVOffToken1_
private

Definition at line 97 of file SiStripDcsInfo.h.

Referenced by readStatus().

◆ detVOffToken2_

edm::ESGetToken<SiStripDetVOff, SiStripDetVOffRcd> SiStripDcsInfo::detVOffToken2_
private

Definition at line 97 of file SiStripDcsInfo.h.

Referenced by readStatus().

◆ fedCablingWatcher_

edm::ESWatcher<SiStripFedCablingRcd> SiStripDcsInfo::fedCablingWatcher_
private

Definition at line 98 of file SiStripDcsInfo.h.

Referenced by readCabling().

◆ IsLumiGoodDcs_

bool SiStripDcsInfo::IsLumiGoodDcs_ {false}
private

Definition at line 90 of file SiStripDcsInfo.h.

Referenced by fillStatus().

◆ m_cacheIDDcs_

unsigned long long SiStripDcsInfo::m_cacheIDDcs_ {}
private

Definition at line 83 of file SiStripDcsInfo.h.

◆ MaxAcceptableBadDcsLumi_

constexpr float SiStripDcsInfo::MaxAcceptableBadDcsLumi_ {2}
staticconstexprprivate

Definition at line 93 of file SiStripDcsInfo.h.

Referenced by addBadModules().

◆ MinAcceptableDcsDetFrac_

constexpr float SiStripDcsInfo::MinAcceptableDcsDetFrac_ {0.90}
staticconstexprprivate

Definition at line 92 of file SiStripDcsInfo.h.

Referenced by fillStatus().

◆ nFEDConnected_

int SiStripDcsInfo::nFEDConnected_ {}
private

◆ nGoodDcsLumi_

int SiStripDcsInfo::nGoodDcsLumi_ {}
private

Definition at line 91 of file SiStripDcsInfo.h.

Referenced by fillStatus().

◆ nLumiAnalysed_

int SiStripDcsInfo::nLumiAnalysed_ {}
private

Definition at line 88 of file SiStripDcsInfo.h.

Referenced by beginLuminosityBlock().

◆ runInfoToken_

edm::ESGetToken<RunInfo, RunInfoRcd> SiStripDcsInfo::runInfoToken_
private

Definition at line 100 of file SiStripDcsInfo.h.

Referenced by beginRun().

◆ SubDetMEsMap

std::map<std::string, SubDetMEs> SiStripDcsInfo::SubDetMEsMap {}
private

◆ tTopoToken0_

edm::ESGetToken<TrackerTopology, TrackerTopologyRcd> SiStripDcsInfo::tTopoToken0_
private

Definition at line 96 of file SiStripDcsInfo.h.

Referenced by readStatus().

◆ tTopoToken1_

edm::ESGetToken<TrackerTopology, TrackerTopologyRcd> SiStripDcsInfo::tTopoToken1_
private

Definition at line 96 of file SiStripDcsInfo.h.

Referenced by readStatus().

◆ tTopoToken2_

edm::ESGetToken<TrackerTopology, TrackerTopologyRcd> SiStripDcsInfo::tTopoToken2_
private

Definition at line 96 of file SiStripDcsInfo.h.

Referenced by readStatus().

◆ tTopoToken3_

edm::ESGetToken<TrackerTopology, TrackerTopologyRcd> SiStripDcsInfo::tTopoToken3_
private

Definition at line 96 of file SiStripDcsInfo.h.

Referenced by readCabling().

edm::ESWatcher::check
bool check(const edm::EventSetup &iSetup)
Definition: ESWatcher.h:52
SiStripDetCabling::addActiveDetectorsRawIds
void addActiveDetectorsRawIds(std::vector< uint32_t > &) const
Definition: SiStripDetCabling.cc:134
dqm::implementation::IBooker::bookFloat
MonitorElement * bookFloat(TString const &name, FUNC onbooking=NOOP())
Definition: DQMStore.h:80
cms::cuda::assert
assert(be >=bs)
dqm::legacy::MonitorElement
Definition: MonitorElement.h:462
SiStripDcsInfo::nGoodDcsLumi_
int nGoodDcsLumi_
Definition: SiStripDcsInfo.h:91
edm::LogInfo
Log< level::Info, false > LogInfo
Definition: MessageLogger.h:125
spr::find
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:19
createPayload.suffix
suffix
Definition: createPayload.py:281
SiStripDcsInfo::MaxAcceptableBadDcsLumi_
static constexpr float MaxAcceptableBadDcsLumi_
Definition: SiStripDcsInfo.h:93
SiStripDcsInfo::readCabling
void readCabling(edm::EventSetup const &)
Definition: SiStripDcsInfo.cc:145
SiStripDcsInfo::tTopoToken2_
edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > tTopoToken2_
Definition: SiStripDcsInfo.h:96
SiStripDcsInfo::detVOffToken0_
edm::ESGetToken< SiStripDetVOff, SiStripDetVOffRcd > detVOffToken0_
Definition: SiStripDcsInfo.h:97
SiStripDcsInfo::nFEDConnected_
int nFEDConnected_
Definition: SiStripDcsInfo.h:86
SiStripDcsInfo::detVOffToken1_
edm::ESGetToken< SiStripDetVOff, SiStripDetVOffRcd > detVOffToken1_
Definition: SiStripDcsInfo.h:97
SiStripDcsInfo::readStatus
void readStatus(edm::EventSetup const &, int transition)
Definition: SiStripDcsInfo.cc:181
SiStripDcsInfo::tTopoToken3_
edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > tTopoToken3_
Definition: SiStripDcsInfo.h:96
SiStripDcsInfo::bookedStatus_
bool bookedStatus_
Definition: SiStripDcsInfo.h:84
GlobalPosition_Frontier_DevDB_cff.tag
tag
Definition: GlobalPosition_Frontier_DevDB_cff.py:11
HLT_FULL_cff.fraction
fraction
Definition: HLT_FULL_cff.py:52802
dqm::impl::MonitorElement::Fill
void Fill(long long x)
Definition: MonitorElement.h:290
SiStripDcsInfo::bookStatus
void bookStatus(DQMStore &dqm_store)
Definition: SiStripDcsInfo.cc:117
SiStripDcsInfo::addBadModules
void addBadModules(DQMStore &dqm_store)
Definition: SiStripDcsInfo.cc:265
dqm::impl::MonitorElement::Reset
virtual void Reset()
Remove all data from the ME, keept the empty histogram with all its settings.
Definition: MonitorElement.cc:354
SiStripDcsInfo::nLumiAnalysed_
int nLumiAnalysed_
Definition: SiStripDcsInfo.h:88
dqm::implementation::DQMStore::setCurrentFolder
void setCurrentFolder(std::string const &fullpath) override
Definition: DQMStore.h:569
SiStripDetCabling::IsConnected
bool IsConnected(const uint32_t &det_id) const
Definition: SiStripDetCabling.cc:375
SiStripDcsInfo::fedCablingWatcher_
edm::ESWatcher< SiStripFedCablingRcd > fedCablingWatcher_
Definition: SiStripDcsInfo.h:98
SiStripDcsInfo::runInfoToken_
edm::ESGetToken< RunInfo, RunInfoRcd > runInfoToken_
Definition: SiStripDcsInfo.h:100
SiStripDcsInfo::SubDetMEsMap
std::map< std::string, SubDetMEs > SubDetMEsMap
Definition: SiStripDcsInfo.h:82
RunInfoRcd
Definition: RunSummaryRcd.h:26
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
dqm::implementation::DQMStore::pwd
std::string pwd() override
Definition: DQMStore.h:567
FEDNumbering::MAXSiStripFEDID
Definition: FEDNumbering.h:30
LogDebug
#define LogDebug(id)
Definition: MessageLogger.h:233
SiStripDcsInfo::tTopoToken0_
edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > tTopoToken0_
Definition: SiStripDcsInfo.h:96
sipixeldigitoraw
Definition: SiPixelDigiToRaw.cc:39
SiStripDcsInfo::fillStatus
void fillStatus(DQMStore &dqm_store)
Definition: SiStripDcsInfo.cc:209
SiStripDcsInfo::fillDummyStatus
void fillDummyStatus(DQMStore &dqm_store)
Definition: SiStripDcsInfo.cc:252
SiStripDcsInfo::IsLumiGoodDcs_
bool IsLumiGoodDcs_
Definition: SiStripDcsInfo.h:90
SiStripUtility::goToDir
static bool goToDir(DQMStore &dqm_store, std::string const &name)
Definition: SiStripUtility.cc:252
dqm::implementation::IBooker::bookInt
MonitorElement * bookInt(TString const &name, FUNC onbooking=NOOP())
Definition: DQMStore.h:73
edm::Service
Definition: Service.h:30
SiStripDcsInfo::DcsFraction_
MonitorElement * DcsFraction_
Definition: SiStripDcsInfo.h:72
dqm::implementation::IBooker::UseLumiScope
UseScope< MonitorElementData::Scope::LUMI > UseLumiScope
Definition: DQMStore.h:463
SiStripUtility::getSubDetectorTag
static void getSubDetectorTag(uint32_t det_id, std::string &subdet_tag, const TrackerTopology *tTopo)
Definition: SiStripUtility.cc:296
SiStripDcsInfo::tTopoToken1_
edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > tTopoToken1_
Definition: SiStripDcsInfo.h:96
dqm::implementation::IGetter::get
virtual MonitorElement * get(std::string const &fullpath) const
Definition: DQMStore.cc:651
SiStripDcsInfo::detCabling_
const SiStripDetCabling * detCabling_
Definition: SiStripDcsInfo.h:95
Skims_PA_cff.name
name
Definition: Skims_PA_cff.py:17
SiStripDcsInfo::MinAcceptableDcsDetFrac_
static constexpr float MinAcceptableDcsDetFrac_
Definition: SiStripDcsInfo.h:92
SiStripDcsInfo::detCablingToken_
edm::ESGetToken< SiStripDetCabling, SiStripDetCablingRcd > detCablingToken_
Definition: SiStripDcsInfo.h:99
hlt_dqm_clientPB-live_cfg.me
me
Definition: hlt_dqm_clientPB-live_cfg.py:61
SiStripDcsInfo::detVOffToken2_
edm::ESGetToken< SiStripDetVOff, SiStripDetVOffRcd > detVOffToken2_
Definition: SiStripDcsInfo.h:97
xuti::subdet_tag
const std::string subdet_tag("SubDet")
SiStripUtility::setBadModuleFlag
static void setBadModuleFlag(std::string &hname, uint16_t &flg)
Definition: SiStripUtility.cc:328
SiStripUtility::getTopFolderPath
static void getTopFolderPath(DQMStore &dqm_store, std::string const &top_dir, std::string &path)
Definition: SiStripUtility.cc:362
dqm::implementation::DQMStore::cd
void cd() override
Definition: DQMStore.h:564
RemoveAddSevLevel.flag
flag
Definition: RemoveAddSevLevel.py:116
FEDNumbering::MINSiStripFEDID
Definition: FEDNumbering.h:29