12 auto prefix_str = name.substr(0, (name.find(
":")));
14 auto const temp_str = name.substr(name.find(
":") + 1);
15 split(temp_str, values,
",");
16 for (
auto&
value : values) {
17 value.insert(0, prefix_str);
26 dir_path = name.substr(0, (name.find(
":")));
28 auto const temp_str = name.substr(name.find(
":") + 1);
29 split(temp_str, values,
",");
35 if (name.find(name) == std::string::npos)
37 auto prefix_str = name.substr(0, (name.find(
":")));
39 auto const temp_str = name.substr(name.find(
":") + 1);
40 std::vector<std::string>
values;
41 split(temp_str, values,
",");
42 for (
auto const&
value : values) {
43 if (
value.find(me_name) != std::string::npos) {
44 full_path = prefix_str +
value;
61 while (std::string::npos != pos || std::string::npos != lastPos) {
63 tokens.push_back(str.substr(lastPos, pos - lastPos));
66 lastPos = str.find_first_not_of(delimiters, pos);
69 pos = str.find_first_of(delimiters, lastPos);
131 if (((status >> 0) & 0
x1) > 0) {
138 if (((status >> 3) & 0
x1) > 0) {
145 if (((status >> 4) & 0
x1) > 0) {
152 if (((status >> 1) & 0
x1) > 0) {
155 if (((status >> 2) & 0
x1) > 0)
188 if (
auto currDir = dqm_store.
pwd(); currDir.find(
"module_") != std::string::npos) {
189 mfolders.push_back(currDir);
192 for (
auto const& subdir : subdirs) {
193 dqm_store.
cd(subdir);
202 std::vector<std::string>& mfolders) {
203 if (
auto currDir = ibooker.
pwd(); currDir.find(
"module_") != std::string::npos) {
204 mfolders.push_back(currDir);
207 for (
auto const& subdir : subdirs) {
222 std::vector<QReport*> qreports = me->
getQReports();
223 bad_channels = qreports[0]->getBadChannels().size();
243 val = val.substr(val.find(
"=") + 1);
252 if (dirName.find(name) == 0) {
256 for (
auto const&
fname : subdirs) {
257 if ((
fname.find(
"Reference") != std::string::npos) || (
fname.find(
"AlCaReco") != std::string::npos) ||
258 (
fname.find(
"HLT") != std::string::npos) || (
fname.find(
"IsolatedBunches") != std::string::npos))
261 if (!
goToDir(dqm_store, name)) {
273 if (dirName.find(name) == 0) {
277 for (
auto const&
fname : subdirs) {
278 if ((
fname.find(
"Reference") != std::string::npos) || (
fname.find(
"AlCaReco") != std::string::npos) ||
279 (
fname.find(
"HLT") != std::string::npos) || (
fname.find(
"IsolatedBunches") != std::string::npos))
282 if (!
goToDir(ibooker, igetter, name)) {
302 if (tTopo->
tidSide(det_id) == 2) {
304 }
else if (tTopo->
tidSide(det_id) == 1) {
314 if (tTopo->
tecSide(det_id) == 2) {
316 }
else if (tTopo->
tecSide(det_id) == 1) {
326 if (hname.find(
"FractionOfBadChannels") != std::string::npos)
328 else if (hname.find(
"NumberOfDigi") != std::string::npos)
330 else if (hname.find(
"NumberOfCluster") != std::string::npos)
332 else if (hname.find(
"ExcludedFedChannel") != std::string::npos)
334 else if (hname.find(
"DCSError") != std::string::npos)
342 message +=
" No Error";
344 if (((flag >> 0) & 0
x1) > 0)
345 message +=
" Fed BadChannel : ";
346 if (((flag >> 1) & 0
x1) > 0)
347 message +=
" # of Digi : ";
348 if (((flag >> 2) & 0
x1) > 0)
349 message +=
" # of Clusters :";
350 if (((flag >> 3) & 0
x1) > 0)
351 message +=
" Excluded FED Channel ";
352 if (((flag >> 4) & 0
x1) > 0)
353 message +=
" DCSError ";
363 dqm_store.
cd(top_dir);
364 path = dqm_store.
pwd();
369 path = dqm_store.
pwd();
370 path = path.substr(0, path.find(mdir) - 1);
384 path = ibooker.
pwd();
389 path = ibooker.
pwd();
390 path = path.substr(0, path.find(tdir) - 1);
static void setBadModuleFlag(std::string &hname, uint16_t &flg)
static constexpr auto TEC
void goUp()
equivalent to "cd .."
static void getModuleFolderList(DQMStore &dqm_store, std::vector< std::string > &m_ids)
static int getMEList(std::string const &name, std::vector< std::string > &values)
static void getDetectorStatusColor(int status, int &rval, int &gval, int &bval)
Kind kind() const
Get the type of the monitor element.
std::string const & pwd() const
bool hasOtherReport() const
true if at least of one of the tests returned some other (non-ok) status
static void getBadModuleStatus(uint16_t flag, std::string &message)
void cd()
go to top directory (ie. root)
static void getMEValue(MonitorElement const *me, std::string &val)
bool hasWarning() const
true if at least of one of the quality tests returned a warning
bool dirExists(std::string const &path)
unsigned int tidSide(const DetId &id) const
const std::string subdet_tag("SubDet")
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum) ...
static constexpr auto TOB
std::vector< QReport * > getQReports() const
get map of QReports
unsigned long long int rval
static constexpr auto TIB
static void getMEStatusColor(int status, int &rval, int &gval, int &bval)
bool hasError() const
true if at least of one of the quality tests returned an error
static void split(std::string const &str, std::vector< std::string > &tokens, std::string const &delimiters=" ")
std::string valueString() const
std::string const & pwd()
std::vector< std::string > getSubdirs() const
static void getSubDetectorTag(uint32_t det_id, std::string &subdet_tag, const TrackerTopology *tTopo)
static bool goToDir(DQMStore &dqm_store, std::string const &name)
static const int STATUS_OK
static bool checkME(std::string const &element, std::string const &name, std::string &full_path)
static int getMEStatus(MonitorElement const *me)
static constexpr auto TID
static void getTopFolderPath(DQMStore &dqm_store, std::string const &top_dir, std::string &path)
unsigned int tecSide(const DetId &id) const
bool dirExists(std::string const &path) const
true if directory exists
std::vector< std::string > getSubdirs()