CMS 3D CMS Logo

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
QTest.h
Go to the documentation of this file.
1 #ifndef DQMSERVICES_CORE_Q_CRITERION_H
2 # define DQMSERVICES_CORE_Q_CRITERION_H
3 
5 # include "TProfile2D.h"
6 # include "TProfile.h"
7 # include "TH2F.h"
8 # include "TH1F.h"
9 # include <sstream>
10 # include <string>
11 # include <map>
12 
13 //#include "DQMServices/Core/interface/DQMStore.h"
14 
24 //class AllContentWithinFixedRange; typedef AllContentWithinFixedRange RuleAllContentWithinFixedRange; typedef AllContentWithinFixedRange AllContentWithinFixedRangeROOT;
25 //class AllContentWithinFloatingRange; typedef AllContentWithinFloatingRange RuleAllContentWithinFloatingRange; typedef AllContentWithinFloatingRange AllContentWithinFloatingRangeROOT;
26 class FlatOccupancy1d; typedef FlatOccupancy1d RuleFlatOccupancy1d; typedef FlatOccupancy1d FlatOccupancy1dROOT;
28 class CSC01; typedef CSC01 RuleCSC01; typedef CSC01 CSC01ROOT;
29 class AllContentAlongDiagonal; typedef AllContentAlongDiagonal RuleAllContentAlongDiagonal; typedef AllContentAlongDiagonal AllContentAlongDiagonalROOT;
31 
45 {
47 
48 public:
49 
51  int getStatus(void) const { return status_; }
53  std::string getMessage(void) const { return message_; }
55  std::string getName(void) const { return qtname_; }
57  std::string algoName(void) const { return algoName_; }
59  void setWarningProb(float prob) { warningProb_ = prob; }
60  void setErrorProb(float prob) { errorProb_ = prob; }
63  virtual std::vector<DQMChannel> getBadChannels(void) const
64  { return std::vector<DQMChannel>(); }
65 
66 protected:
67  QCriterion(std::string qtname) { qtname_ = qtname; init(); }
69  void init(void);
70 
71  virtual ~QCriterion(void) {}
72 
73  virtual float runTest(const MonitorElement *me);
75  void setAlgoName(std::string name) { algoName_ = name; }
76 
77  float runTest(const MonitorElement *me, QReport &qr, DQMNet::QValue &qv) {
78  assert(qr.qcriterion_ == this);
79  assert(qv.qtname == qtname_);
80 
81  prob_ = runTest(me); // this runTest goes to SimpleTest derivates
82 
86 
87  setMessage(); // this goes to SimpleTest derivates
88 
89  if (verbose_==2) std::cout << " Message = " << message_ << std::endl;
90  if (verbose_==2) std::cout << " Name = " << qtname_ <<
91  " / Algorithm = " << algoName_ <<
92  " / Status = " << status_ <<
93  " / Prob = " << prob_ << std::endl;
94 
95  qv.code = status_;
96  qv.message = message_;
97  qv.qtname = qtname_;
98  qv.algorithm = algoName_;
99  qv.qtresult = prob_;
101 
102  return prob_;
103  }
104 
106  virtual void setMessage(void) = 0;
107 
108  std::string qtname_;
109  std::string algoName_;
110  float prob_;
111  int status_;
112  std::string message_;
115  int verbose_;
116 
117 private:
119  static const float WARNING_PROB_THRESHOLD;
120  static const float ERROR_PROB_THRESHOLD;
121 
123  friend class DQMStore;
125  friend class MonitorElement;
126 };
127 
131 
132 class SimpleTest : public QCriterion
133 {
134 public:
135  SimpleTest(const std::string &name, bool keepBadChannels = false) : QCriterion(name),
136  minEntries_ (0),
137  keepBadChannels_ (keepBadChannels)
138  {}
139 
141  void setMinimumEntries(unsigned n) { minEntries_ = n; }
143  virtual std::vector<DQMChannel> getBadChannels(void) const
144  {
146  }
147 
148 protected:
149 
151  virtual void setMessage(void)
152  {
153  message_.clear();
154  }
155 
156  unsigned minEntries_; //< minimum # of entries needed
157  std::vector<DQMChannel> badChannels_;
159  };
160 
161 
162 //===============================================================//
163 //========= Classes for particular QUALITY TESTS ================//
164 //===============================================================//
165 
166 //===================== Comp2RefEqualH ===================//
167 //== Algorithm for comparing equality of histograms ==//
169 {
170 public:
171  Comp2RefEqualH(const std::string &name) : SimpleTest(name,true)
172  {
173  setAlgoName( getAlgoName() );
174  }
175  static std::string getAlgoName(void) { return "Comp2RefEqualH"; }
176  float runTest(const MonitorElement*me);
177 };
178 
179 //===================== Comp2RefChi2 ===================//
180 // comparison to reference using the chi^2 algorithm
181 class Comp2RefChi2 : public SimpleTest
182 {
183 public:
184  Comp2RefChi2(const std::string &name) :SimpleTest(name)
185  {
187  }
188  static std::string getAlgoName(void) { return "Comp2RefChi2"; }
189  float runTest(const MonitorElement*me);
190 
191 protected:
192 
193  void setMessage(void)
194  {
195  std::ostringstream message;
196  message << "chi2/Ndof = " << chi2_ << "/" << Ndof_
197  << ", minimum needed statistics = " << minEntries_
198  << " warning threshold = " << this->warningProb_
199  << " error threshold = " << this->errorProb_;
200  message_ = message.str();
201  }
202 
203  // # of degrees of freedom and chi^2 for test
204  int Ndof_; double chi2_;
205 };
206 
207 //===================== Comp2RefKolmogorov ===================//
210 {
211 public:
212  Comp2RefKolmogorov(const std::string &name) : SimpleTest(name)
213  {
215  }
216  static std::string getAlgoName(void) { return "Comp2RefKolmogorov"; }
217 
218  float runTest(const MonitorElement *me);
219 };
220 
221 //==================== ContentsXRange =========================//
222 //== Check that histogram contents are between [Xmin, Xmax] ==//
224 {
225 public:
226  ContentsXRange(const std::string &name) : SimpleTest(name)
227  {
228  rangeInitialized_ = false;
230  }
231  static std::string getAlgoName(void) { return "ContentsXRange"; }
232  float runTest(const MonitorElement *me) ;
233 
235  virtual void setAllowedXRange(double xmin, double xmax)
236  {
237  xmin_ = xmin; xmax_ = xmax;
238  rangeInitialized_ = true;
239  }
240 
241 protected:
242  double xmin_;double xmax_;
244 };
245 
246 //==================== ContentsYRange =========================//
247 //== Check that histogram contents are between [Ymin, Ymax] ==//
249 {
250 public:
251  ContentsYRange(const std::string &name) : SimpleTest(name,true)
252  {
253  rangeInitialized_ = false;
255  }
256  static std::string getAlgoName(void) { return "ContentsYRange"; }
257  float runTest(const MonitorElement *me);
258 
259  void setUseEmptyBins(unsigned int useEmptyBins) { useEmptyBins_ = useEmptyBins; }
260  virtual void setAllowedYRange(double ymin, double ymax)
261  {
262  ymin_ = ymin; ymax_ = ymax;
263  rangeInitialized_ = true;
264  }
265 
266 protected:
267  double ymin_; double ymax_;
269  unsigned int useEmptyBins_;
270 
271 };
272 
273 //============================== DeadChannel =================================//
275 class DeadChannel : public SimpleTest
276 {
277 public:
278  DeadChannel(const std::string &name) : SimpleTest(name,true)
279  {
280  rangeInitialized_ = false;
282  }
283  static std::string getAlgoName(void) { return "DeadChannel"; }
284  float runTest(const MonitorElement *me);
285 
287  void setThreshold(double ymin)
288  {
289  ymin_ = ymin;
290  rangeInitialized_ = true;
291  }
292 
293 protected:
294  double ymin_;
296 };
297 
298 
299 //==================== NoisyChannel =========================//
301 class NoisyChannel : public SimpleTest
302 {
303 public:
304  NoisyChannel(const std::string &name) : SimpleTest(name,true)
305  {
306  rangeInitialized_ = false;
307  numNeighbors_ = 1;
309  }
310  static std::string getAlgoName(void) { return "NoisyChannel"; }
311  float runTest(const MonitorElement*me);
312 
320  void setNumNeighbors(unsigned n) { if (n > 0) numNeighbors_ = n; }
321 
326  void setTolerance(float percentage)
327  {
328  if (percentage >=0)
329  {
330  tolerance_ = percentage;
331  rangeInitialized_ = true;
332  }
333  }
334 
335 protected:
338  double getAverage(int bin, const TH1 *h) const;
339 
340  float tolerance_; /*< tolerance for considering a channel noisy */
341  unsigned numNeighbors_; /*< # of neighboring channels for calculating average to be used
342  for comparison with channel under consideration */
343  bool rangeInitialized_; /*< init-flag for tolerance */
344 };
345 
346 //==================== ContentsWithinExpected =========================//
347 // Check that every TH2 channel has mean, RMS within allowed range.
349 {
350 public:
351  ContentsWithinExpected(const std::string &name) : SimpleTest(name,true)
352  {
353  checkMean_ = checkRMS_ = false;
354  minMean_ = maxMean_ = minRMS_ = maxRMS_ = 0.0;
355  checkMeanTolerance_ = false;
356  toleranceMean_ = -1.0;
358  }
359  static std::string getAlgoName(void) { return "ContentsWithinExpected"; }
360  float runTest(const MonitorElement *me);
361 
362  void setUseEmptyBins(unsigned int useEmptyBins) {
363  useEmptyBins_ = useEmptyBins;
364  }
365  void setMeanRange(double xmin, double xmax);
366  void setRMSRange(double xmin, double xmax);
367 
369  void setMeanTolerance(float fracTolerance)
370  {
371  if (fracTolerance >= 0.0)
372  {
373  toleranceMean_ = fracTolerance;
374  checkMeanTolerance_ = true;
375  }
376  }
377 
378 protected:
379  bool checkMean_; //< if true, check the mean value
380  bool checkRMS_; //< if true, check the RMS value
381  bool checkMeanTolerance_; //< if true, check mean tolerance
382  float toleranceMean_; //< fractional tolerance on mean (use only if checkMeanTolerance_ = true)
383  float minMean_, maxMean_; //< allowed range for mean (use only if checkMean_ = true)
384  float minRMS_, maxRMS_; //< allowed range for mean (use only if checkRMS_ = true)
385  unsigned int useEmptyBins_;
386 
387 };
388 
389 //==================== MeanWithinExpected =========================//
392 {
393 public:
394  MeanWithinExpected(const std::string &name) : SimpleTest(name)
395  {
397  }
398  static std::string getAlgoName(void) { return "MeanWithinExpected"; }
399  float runTest(const MonitorElement*me);
400 
401  void setExpectedMean(double mean) { expMean_ = mean; }
402  void useRange(double xmin, double xmax);
403  void useSigma(double expectedSigma);
404  void useRMS(void) ;
405 
406 protected:
407  bool useRMS_; //< if true, will use RMS of distribution
408  bool useSigma_; //< if true, will use expected_sigma
409  bool useRange_; //< if true, will use allowed range
410  double sigma_; //< sigma to be used in probability calculation (use only if useSigma_ = true)
411  double expMean_; //< expected mean value (used only if useSigma_ = true or useRMS_ = true)
412  double xmin_, xmax_; //< allowed range for mean (use only if useRange_ = true)
413 
414 };
415 
416 //==================== AllContentWithinFixedRange =========================//
417 /*class AllContentWithinFixedRange : public SimpleTest
418 {
419 public:
420  AllContentWithinFixedRange(const std::string &name) : SimpleTest(name)
421  {
422  setAlgoName(getAlgoName());
423  }
424  static std::string getAlgoName(void) { return "RuleAllContentWithinFixedRange"; }
425  float runTest(const MonitorElement *me);
426 
427  void set_x_min(double x) { x_min = x; }
428  void set_x_max(double x) { x_max = x; }
429  void set_epsilon_max(double epsilon) { epsilon_max = epsilon; }
430  void set_S_fail(double S) { S_fail = S; }
431  void set_S_pass(double S) { S_pass = S; }
432  double get_epsilon_obs(void) { return epsilon_obs; }
433  double get_S_fail_obs(void) { return S_fail_obs; }
434  double get_S_pass_obs(void) { return S_pass_obs; }
435  int get_result(void) { return result; }
436 
437 protected:
438  TH1F *histogram ; //define Test histo
439  double x_min, x_max;
440  double epsilon_max;
441  double S_fail, S_pass;
442  double epsilon_obs;
443  double S_fail_obs, S_pass_obs;
444  int result;
445 };
446 */
447 //==================== AllContentWithinFloatingRange =========================//
448 /*class AllContentWithinFloatingRange : public SimpleTest
449 {
450 public:
451  AllContentWithinFloatingRange(const std::string &name) : SimpleTest(name)
452  {
453  setAlgoName(getAlgoName());
454  }
455  static std::string getAlgoName(void) { return "RuleAllContentWithinFloatingRange"; }
456 
457  void set_Nrange(int N) { Nrange = N; }
458  void set_epsilon_max(double epsilon) { epsilon_max = epsilon; }
459  void set_S_fail(double S) { S_fail = S; }
460  void set_S_pass(double S) { S_pass = S; }
461  double get_epsilon_obs(void) { return epsilon_obs; }
462  double get_S_fail_obs(void) { return S_fail_obs; }
463  double get_S_pass_obs(void) { return S_pass_obs; }
464  int get_result(void) { return result; }
465 
466  float runTest(const MonitorElement *me );
467 
468 protected:
469  TH1F *histogram ; //define Test histo
470  int Nrange;
471  double epsilon_max;
472  double S_fail, S_pass;
473  double epsilon_obs;
474  double S_fail_obs, S_pass_obs;
475  int result;
476 };*/
477 
478 //==================== FlatOccupancy1d =========================//
479 #if 0 // FIXME: need to know what parameters to set before runTest!
480 class FlatOccupancy1d : public SimpleTest
481 {
482 public:
483  FlatOccupancy1d(const std::string &name) : SimpleTest(name)
484  {
485  Nbins = 0;
486  FailedBins[0] = 0;
487  FailedBins[1] = 0;
488  setAlgoName(getAlgoName());
489  }
490 
491  ~FlatOccupancy1d(void)
492  {
493  delete [] FailedBins[0];
494  delete [] FailedBins[1];
495  }
496 
497  static std::string getAlgoName(void) { return "RuleFlatOccupancy1d"; }
498 
499  void set_ExclusionMask(double *mask) { ExclusionMask = mask; }
500  void set_epsilon_min(double epsilon) { epsilon_min = epsilon; }
501  void set_epsilon_max(double epsilon) { epsilon_max = epsilon; }
502  void set_S_fail(double S) { S_fail = S; }
503  void set_S_pass(double S) { S_pass = S; }
504  double get_FailedBins(void) { return *FailedBins[2]; } // FIXME: WRONG! OFF BY ONE!?
505  int get_result() { return result; }
506 
507  float runTest(const MonitorElement*me);
508 
509 protected:
510  double *ExclusionMask;
511  double epsilon_min, epsilon_max;
512  double S_fail, S_pass;
513  double *FailedBins[2];
514  int Nbins;
515  int result;
516 };
517 #endif
518 
519 //==================== FixedFlatOccupancy1d =========================//
521 {
522 public:
523  FixedFlatOccupancy1d(const std::string &name) : SimpleTest(name)
524  {
525  Nbins = 0;
526  FailedBins[0] = 0;
527  FailedBins[1] = 0;
529  }
530 
532  {
533  if( Nbins > 0 )
534  {
535  delete [] FailedBins[0];
536  delete [] FailedBins[1];
537  }
538  }
539 
540  static std::string getAlgoName(void) { return "RuleFixedFlatOccupancy1d"; }
541 
542  void set_Occupancy(double level) { b = level; }
543  void set_ExclusionMask(double *mask) { ExclusionMask = mask; }
546  void set_S_fail(double S) { S_fail = S; }
547  void set_S_pass(double S) { S_pass = S; }
548  double get_FailedBins(void) { return *FailedBins[2]; } // FIXME: WRONG! OFF BY ONE!?
549  int get_result() { return result; }
550 
551  float runTest(const MonitorElement*me);
552 
553 protected:
554  double b;
555  double *ExclusionMask;
557  double S_fail, S_pass;
558  double *FailedBins[2];
559  int Nbins;
560  int result;
561 };
562 
563 //==================== CSC01 =========================//
564 class CSC01 : public SimpleTest
565 {
566 public:
567  CSC01(const std::string &name) : SimpleTest(name)
568  {
570  }
571  static std::string getAlgoName(void) { return "RuleCSC01"; }
572 
574  void set_S_fail(double S) { S_fail = S; }
575  void set_S_pass(double S) { S_pass = S; }
576  double get_epsilon_obs() { return epsilon_obs; }
577  double get_S_fail_obs() { return S_fail_obs; }
578  double get_S_pass_obs() { return S_pass_obs; }
579  int get_result() { return result; }
580 
581  float runTest(const MonitorElement*me);
582 
583 protected:
584  double epsilon_max;
585  double S_fail, S_pass;
586  double epsilon_obs;
588  int result;
589 };
590 
591 //======================== CompareToMedian ====================//
593 {
594 public:
595  //Initialize for TProfile, colRings
596  CompareToMedian(const std::string &name) : SimpleTest(name,true){
597  this->_min = 0.2;
598  this->_max = 3.0;
599  this->_emptyBins = 0;
600  this->_maxMed = 10;
601  this->_minMed = 0;
602  this->nBins = 0;
603  this->_statCut = 0;
604  reset();
606  };
607 
609 
610  static std::string getAlgoName(void) { return "CompareToMedian"; }
611 
612  float runTest(const MonitorElement *me);
613  void setMin(float min){_min = min;};
614  void setMax(float max){_max = max;};
615  void setEmptyBins(int eB){eB > 0 ? _emptyBins = 1 : _emptyBins = 0;};
616  void setMaxMedian(float max){_maxMed = max;};
617  void setMinMedian(float min){_minMed = min;};
618  void setStatCut(float cut){_statCut = (cut > 0) ? cut : 0;};
619 
620 protected :
621  void setMessage(void){
622  std::ostringstream message;
623  message << "Test " << qtname_ << " (" << algoName_
624  << "): Entry fraction within range = " << prob_;
625  message_ = message.str();
626  }
627 
628 private :
629  float _min, _max; //Test values
630  int _emptyBins; //use empty bins
631  float _maxMed,_minMed; //Global max for median&mean
632  float _statCut; //Minimal number of non zero entries needed for the quality test
633 
634  int nBinsX, nBinsY; //Dimensions of hystogram
635 
636  int nBins; //Number of (non empty) bins
637 
638  //Vector contain bin values
639  std::vector<float> binValues;
640 
641  void reset(){binValues.clear();};
642 
643 };
644 
645 //==================== AllContentAlongDiagonal =========================//
646 #if 0 // FIXME: need to know what parameters to set before runTest!
647 class AllContentAlongDiagonal : public SimpleTest
648 
649 public:
650  AllContentAlongDiagonal(const std::string &name) : SimpleTest(name)
651  {
652  setAlgoName(getAlgoName());
653  }
654  static std::string getAlgoName(void) { return "RuleAllContentAlongDiagonal"; }
655 
656  void set_epsilon_max(double epsilon) { epsilon_max = epsilon; }
657  void set_S_fail(double S) { S_fail = S; }
658  void set_S_pass(double S) { S_pass = S; }
659  double get_epsilon_obs() { return epsilon_obs; }
660  double get_S_fail_obs() { return S_fail_obs; }
661  double get_S_pass_obs() { return S_pass_obs; }
662  int get_result() { return result; }
663 
664  //public:
665  //using SimpleTest::runTest;
666  float runTest(const MonitorElement*me);
667 
668 protected:
669  double epsilon_max;
670  double S_fail, S_pass;
671  double epsilon_obs;
672  double S_fail_obs, S_pass_obs;
673  int result;
674 };
675 #endif
676 
677 #endif // DQMSERVICES_CORE_Q_CRITERION_H
ContentsWithinExpected ContentsWithinExpectedROOT
Definition: QTest.h:22
void setErrorProb(float prob)
Definition: QTest.h:60
float runTest(const MonitorElement *me)
std::string getMessage(void) const
get message attached to test
Definition: QTest.h:53
void set_epsilon_min(double epsilon)
Definition: QTest.h:544
FixedFlatOccupancy1d FixedFlatOccupancy1dROOT
Definition: QTest.h:27
QCriterion * qcriterion_
Definition: QReport.h:51
void setStatCut(float cut)
Definition: QTest.h:618
double get_S_pass_obs()
Definition: QTest.h:578
static std::string getAlgoName(void)
Definition: QTest.h:310
double xmin_
Definition: QTest.h:412
double getAverage(int bin, const TH1 *h) const
Definition: QTest.cc:843
void useRMS(void)
Definition: QTest.cc:1247
Comp2RefEqualH(const std::string &name)
Definition: QTest.h:171
float runTest(const MonitorElement *me)
Definition: QTest.cc:547
void setAlgoName(std::string name)
set algorithm name
Definition: QTest.h:75
std::string getName(void) const
get name of quality test
Definition: QTest.h:55
test that histogram contents are above Ymin
Definition: QTest.h:275
double epsilon_max
Definition: QTest.h:556
double ymin_
ymin - threshold
Definition: QTest.h:294
double epsilon_max
Definition: QTest.h:584
CSC01(const std::string &name)
Definition: QTest.h:567
float runTest(const MonitorElement *me)
Definition: QTest.cc:872
SimpleTest(const std::string &name, bool keepBadChannels=false)
Definition: QTest.h:135
std::string algorithm
Definition: DQMNet.h:91
void set_ExclusionMask(double *mask)
Definition: QTest.h:543
float runTest(const MonitorElement *me)
Definition: QTest.cc:626
void setUseEmptyBins(unsigned int useEmptyBins)
Definition: QTest.h:259
void setMin(float min)
Definition: QTest.h:613
double epsilon_obs
Definition: QTest.h:586
int verbose_
Definition: QTest.h:115
static std::string getAlgoName(void)
Definition: QTest.h:359
FlatOccupancy1d FlatOccupancy1dROOT
Definition: QTest.h:26
float _statCut
Definition: QTest.h:632
int status_
Definition: QTest.h:111
virtual void setAllowedXRange(double xmin, double xmax)
set allowed range in X-axis (default values: histogram&#39;s X-range)
Definition: QTest.h:235
float runTest(const MonitorElement *me, QReport &qr, DQMNet::QValue &qv)
Definition: QTest.h:77
FlatOccupancy1d RuleFlatOccupancy1d
Definition: QTest.h:26
double * ExclusionMask
Definition: QTest.h:555
std::string algoName_
name of quality test
Definition: QTest.h:109
Comp2RefChi2 Comp2RefChi2ROOT
Definition: QTest.h:15
static const int WARNING
static std::string getAlgoName(void)
Definition: QTest.h:231
int get_result()
Definition: QTest.h:579
void setRMSRange(double xmin, double xmax)
set expected value for mean
Definition: QTest.cc:1123
void useSigma(double expectedSigma)
Definition: QTest.cc:1236
#define min(a, b)
Definition: mlp_lapack.h:161
CSC01 CSC01ROOT
Definition: QTest.h:28
double S_pass
Definition: QTest.h:585
int _emptyBins
Definition: QTest.h:630
double S_pass_obs
Definition: QTest.h:587
void setMax(float max)
Definition: QTest.h:614
virtual std::vector< DQMChannel > getBadChannels(void) const
get vector of channels that failed test (not always relevant!)
Definition: QTest.h:143
double xmax_
Definition: QTest.h:412
NoisyChannel NoisyChannelROOT
Definition: QTest.h:20
std::string qtname_
Definition: QTest.h:108
void setNumNeighbors(unsigned n)
Definition: QTest.h:320
static std::string getAlgoName(void)
Definition: QTest.h:283
Algorithm for testing if histogram&#39;s mean value is near expected value.
Definition: QTest.h:391
static std::string getAlgoName(void)
Definition: QTest.h:610
DeadChannel(const std::string &name)
Definition: QTest.h:278
float runTest(const MonitorElement *me)
Definition: QTest.cc:293
ContentsXRange(const std::string &name)
Definition: QTest.h:226
Check if any channels are noisy compared to neighboring ones.
Definition: QTest.h:301
AllContentAlongDiagonal RuleAllContentAlongDiagonal
Definition: QTest.h:29
double epsilon_min
Definition: QTest.h:556
int Ndof_
Definition: QTest.h:204
bool rangeInitialized_
Definition: QTest.h:243
Comp2RefEqualH Comp2RefEqualHROOT
Definition: QTest.h:17
ContentsXRange ContentsXRangeROOT
Definition: QTest.h:18
CompareToMedian CompareToMedianROOT
Definition: QTest.h:30
float errorProb_
Definition: QTest.h:113
virtual void setMessage(void)
set status &amp; message after test has run
Definition: QTest.h:151
double get_S_fail_obs()
Definition: QTest.h:577
const T & max(const T &a, const T &b)
FixedFlatOccupancy1d RuleFixedFlatOccupancy1d
Definition: QTest.h:27
double S_fail_obs
Definition: QTest.h:587
float _minMed
Definition: QTest.h:631
FixedFlatOccupancy1d(const std::string &name)
Definition: QTest.h:523
tuple result
Definition: query.py:137
void setEmptyBins(int eB)
Definition: QTest.h:615
Comp2RefKolmogorov Comp2RefKolmogorovROOT
Definition: QTest.h:16
void set_Occupancy(double level)
Definition: QTest.h:542
static std::string getAlgoName(void)
Definition: QTest.h:571
void set_epsilon_max(double epsilon)
Definition: QTest.h:573
static std::string getAlgoName(void)
Definition: QTest.h:216
float _maxMed
Definition: QTest.h:631
float prob_
name of algorithm
Definition: QTest.h:110
~CompareToMedian()
Definition: QTest.h:608
std::string algoName(void) const
get algorithm name
Definition: QTest.h:57
static const float ERROR_PROB_THRESHOLD
Definition: QTest.h:120
void setTolerance(float percentage)
Definition: QTest.h:326
double xmax_
Definition: QTest.h:242
unsigned int useEmptyBins_
Definition: QTest.h:385
CSC01 RuleCSC01
Definition: QTest.h:28
static std::string getAlgoName(void)
Definition: QTest.h:256
void setMinimumEntries(unsigned n)
set minimum # of entries needed
Definition: QTest.h:141
float runTest(const MonitorElement *me)
Definition: QTest.cc:747
double S_fail
Definition: QTest.h:585
MeanWithinExpected MeanWithinExpectedROOT
Definition: QTest.h:23
virtual std::vector< DQMChannel > getBadChannels(void) const
Definition: QTest.h:63
void reset()
Definition: QTest.h:641
bool checkMeanTolerance_
Definition: QTest.h:381
ContentsWithinExpected(const std::string &name)
Definition: QTest.h:351
void setExpectedMean(double mean)
Definition: QTest.h:401
bool keepBadChannels_
Definition: QTest.h:158
double xmin_
Definition: QTest.h:242
std::string qtname
Definition: DQMNet.h:90
AllContentAlongDiagonal AllContentAlongDiagonalROOT
Definition: QTest.h:29
void setUseEmptyBins(unsigned int useEmptyBins)
Definition: QTest.h:362
double sigma_
Definition: QTest.h:410
void setMaxMedian(float max)
Definition: QTest.h:616
std::string message_
quality test status
Definition: QTest.h:112
int result
Definition: QTest.h:588
void useRange(double xmin, double xmax)
Definition: QTest.cc:1226
static std::string getAlgoName(void)
Definition: QTest.h:175
void set_epsilon_max(double epsilon)
Definition: QTest.h:545
int getStatus(void) const
(class should be created by DQMStore class)
Definition: QTest.h:51
tuple cut
Definition: align_tpl.py:88
std::vector< float > binValues
Definition: QTest.h:639
double * FailedBins[2]
Definition: QTest.h:558
NoisyChannel(const std::string &name)
Definition: QTest.h:304
CompareToMedian(const std::string &name)
Definition: QTest.h:596
float runTest(const MonitorElement *me)
Definition: QTest.cc:163
virtual float runTest(const MonitorElement *me)
Definition: QTest.cc:27
double ymin_
Definition: QTest.h:267
void set_S_pass(double S)
Definition: QTest.h:547
std::vector< DQMChannel > badChannels_
Definition: QTest.h:157
void setWarningProb(float prob)
set probability limit for warning and error (default: 90% and 50%)
Definition: QTest.h:59
string message
Definition: argparse.py:126
MeanWithinExpected(const std::string &name)
Definition: QTest.h:394
double get_epsilon_obs()
Definition: QTest.h:576
Comparison to reference using the Kolmogorov algorithm.
Definition: QTest.h:209
static std::string getAlgoName(void)
Definition: QTest.h:540
float tolerance_
Definition: QTest.h:340
void init(void)
initialize values
Definition: QTest.cc:17
void setVerbose(int verbose)
probability limits for warnings, errors
Definition: QTest.h:114
void setMessage(void)
set status &amp; message after test has run
Definition: QTest.h:621
void setMeanRange(double xmin, double xmax)
set expected value for mean
Definition: QTest.cc:1111
float _max
Definition: QTest.h:629
static std::string getAlgoName(void)
Definition: QTest.h:188
float runTest(const MonitorElement *me)
Definition: QTest.cc:1147
void set_S_fail(double S)
Definition: QTest.h:546
bool rangeInitialized_
Definition: QTest.h:268
double expMean_
Definition: QTest.h:411
DeadChannel DeadChannelROOT
Definition: QTest.h:21
QCriterion(std::string qtname)
Definition: QTest.h:67
std::vector< DQMChannel > badChannels_
Definition: QReport.h:52
std::string message
Definition: DQMNet.h:89
static const int STATUS_OK
tuple cout
Definition: gather_cfg.py:41
float runTest(const MonitorElement *me)
Definition: QTest.cc:40
ContentsYRange(const std::string &name)
Definition: QTest.h:251
ContentsYRange ContentsYRangeROOT
Definition: QTest.h:19
unsigned minEntries_
Definition: QTest.h:156
virtual ~QCriterion(void)
Definition: QTest.h:71
tuple level
Definition: testEve_cfg.py:34
float runTest(const MonitorElement *me)
Definition: QTest.cc:1264
void setMeanTolerance(float fracTolerance)
set (fractional) tolerance for mean
Definition: QTest.h:369
const double epsilon
double chi2_
Definition: QTest.h:204
Comp2RefChi2(const std::string &name)
Definition: QTest.h:184
void setThreshold(double ymin)
set Ymin (inclusive) threshold for &quot;dead&quot; channel (default: 0)
Definition: QTest.h:287
void setMessage(void)
set status &amp; message after test has run
Definition: QTest.h:193
void set_S_fail(double S)
Definition: QTest.h:574
bool rangeInitialized_
Definition: QTest.h:295
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
Definition: Activities.doc:4
~FixedFlatOccupancy1d(void)
Definition: QTest.h:531
virtual void setAllowedYRange(double ymin, double ymax)
Definition: QTest.h:260
float qtresult
Definition: DQMNet.h:88
void set_S_pass(double S)
Definition: QTest.h:575
unsigned int useEmptyBins_
Definition: QTest.h:269
float warningProb_
message attached to test
Definition: QTest.h:113
bool rangeInitialized_
Definition: QTest.h:343
float runTest(const MonitorElement *me)
Definition: QTest.h:564
double get_FailedBins(void)
Definition: QTest.h:548
virtual void setMessage(void)=0
set message after test has run
float _min
Definition: QTest.h:629
static const int ERROR
double ymax_
Definition: QTest.h:267
static std::string getAlgoName(void)
Definition: QTest.h:398
float runTest(const MonitorElement *me)
Definition: QTest.cc:477
void setMinMedian(float min)
Definition: QTest.h:617
static const float WARNING_PROB_THRESHOLD
default &quot;probability&quot; values for setting warnings &amp; errors when running tests
Definition: QTest.h:119
unsigned numNeighbors_
Definition: QTest.h:341
Comp2RefKolmogorov(const std::string &name)
Definition: QTest.h:212