|
 |
Go to the documentation of this file.
33 edm::LogInfo(
"SiStripDaqInfo") <<
"SiStripDaqInfo::Deleting SiStripDaqInfo ";
47 if (!strip_dir.empty())
55 if (!strip_dir.empty())
60 std::vector<std::string> det_types;
61 det_types.push_back(
"TIB");
62 det_types.push_back(
"TOB");
63 det_types.push_back(
"TIDF");
64 det_types.push_back(
"TIDB");
65 det_types.push_back(
"TECF");
66 det_types.push_back(
"TECB");
68 for (
auto const& det : det_types) {
86 pr.second.daqFractionME->Reset();
87 pr.second.daqFractionME->Fill(-1.0);
94 edm::LogInfo(
"SiStripDaqInfo") <<
"SiStripDaqInfo:: Begining of Run";
111 edm::LogInfo(
"SiStripDaqInfo") <<
" SiStripDaqInfo::No FEDs Connected!!!";
115 float nFEDConnected = 0.0;
124 runInfoRec->get(sumFED);
129 auto const& fedsInIds = sumFED->
m_fed_in;
130 for (
auto const fedID : fedsInIds) {
131 if (fedID >= siStripFedIdMin && fedID <= siStripFedIdMax)
136 if (nFEDConnected > 0) {
157 for (
auto const fed :
feds) {
159 for (
auto const&
conn : fedChannels) {
160 if (!
conn.isConnected())
162 uint32_t detId =
conn.detId();
163 if (detId == 0 || detId == 0xFFFFFFFF)
176 std::vector<int>
const& fed_ids,
188 auto const&
name =
pr.first;
192 iPos->second.connectedFeds = 0;
200 iPos->second.connectedFeds = 0;
201 for (
auto const subdetId : subdetIds) {
202 bool fedid_found =
false;
203 for (
auto const fedId : fed_ids) {
204 if (fedId < siStripFedIdMin || fedId > siStripFedIdMax)
206 if (subdetId ==
fedId) {
208 iPos->second.connectedFeds++;
215 if (
auto nFedSubDet = subdetIds.size(); nFedSubDet > 0) {
216 iPos->second.daqFractionME->Reset();
217 int const nFedsConnected = iPos->second.connectedFeds;
218 iPos->second.daqFractionME->Fill(nFedsConnected * 1.0 / nFedSubDet);
226 unsigned short const fed_id,
238 for (
auto const&
conn : fedChannels) {
239 if (!
conn.isConnected())
241 uint32_t detId =
conn.detId();
242 if (detId == 0 || detId == 0xFFFFFFFF)
250 if (!dqm_store.
dirExists(subdet_folder)) {
251 subdet_folder = mechanical_dir + subdet_folder.substr(subdet_folder.find(mdir) + mdir.size());
253 bad_module_folder = subdet_folder +
"/" +
"BadModuleList";
256 std::ostringstream detid_str;
258 std::string full_path = bad_module_folder +
"/" + detid_str.str();
T const * product() const
MonitorElement * bookFloat(TString const &name, FUNC onbooking=NOOP())
edm::ESHandle< SiStripFedCabling > fedCabling_
void findExcludedModule(DQMStore &dqm_store, unsigned short fed_id, TrackerTopology const *tTopo)
unsigned long long m_cacheID_
std::map< std::string, std::vector< unsigned short > > subDetFedMap_
std::vector< int > m_fed_in
std::optional< T > tryToGet() const
#define DEFINE_FWK_MODULE(type)
SiStripDaqInfo(edm::ParameterSet const &ps)
MonitorElement * daqFraction_
virtual void Reset()
Remove all data from the ME, keept the empty histogram with all its settings.
void setCurrentFolder(std::string const &fullpath) override
void analyze(edm::Event const &, edm::EventSetup const &) override
void fillDummyStatus(DQMStore &dqm_store)
std::string pwd() override
void getSubDetFolder(const uint32_t &detid, const TrackerTopology *tTopo, std::string &folder_name)
static bool goToDir(DQMStore &dqm_store, std::string const &name)
MonitorElement * bookInt(TString const &name, FUNC onbooking=NOOP())
void readSubdetFedFractions(DQMStore &dqm_store, std::vector< int > const &fed_ids, edm::EventSetup const &iSetup)
static void getSubDetectorTag(uint32_t det_id, std::string &subdet_tag, const TrackerTopology *tTopo)
virtual MonitorElement * get(std::string const &fullpath) const
FedsConstIterRange fedIds() const
std::map< std::string, SubDetMEs > subDetMEsMap_
void beginRun(edm::Run const &run, edm::EventSetup const &eSetup) override
const std::string subdet_tag("SubDet")
void bookStatus(DQMStore &dqm_store)
ConnsConstIterRange fedConnections(uint16_t fed_id) const
static void setBadModuleFlag(std::string &hname, uint16_t &flg)
void readFedIds(edm::ESHandle< SiStripFedCabling > const &fedcabling, edm::EventSetup const &iSetup)
virtual bool dirExists(std::string const &path) const
static void getTopFolderPath(DQMStore &dqm_store, std::string const &top_dir, std::string &path)