1 #ifndef DQMSERVICES_CORE_Q_CRITERION_H 2 # define DQMSERVICES_CORE_Q_CRITERION_H 5 # include "TProfile2D.h" 66 {
return std::vector<DQMChannel>(); }
95 " / Prob = " <<
prob_ << std::endl;
139 keepBadChannels_ (keepBadChannels)
198 message <<
"chi2/Ndof = " << chi2_ <<
"/" << Ndof_
199 <<
", minimum needed statistics = " << minEntries_
230 rangeInitialized_ =
false;
240 rangeInitialized_ =
true;
255 rangeInitialized_ =
false;
265 rangeInitialized_ =
true;
282 rangeInitialized_ =
false;
292 rangeInitialized_ =
true;
308 rangeInitialized_ =
false;
332 tolerance_ = percentage;
333 rangeInitialized_ =
true;
340 double getAverage(
int bin,
const TH1 *
h)
const;
355 checkMean_ = checkRMS_ =
false;
356 minMean_ = maxMean_ = minRMS_ = maxRMS_ = 0.0;
357 checkMeanTolerance_ =
false;
358 toleranceMean_ = -1.0;
365 useEmptyBins_ = useEmptyBins;
367 void setMeanRange(
double xmin,
double xmax);
368 void setRMSRange(
double xmin,
double xmax);
373 if (fracTolerance >= 0.0)
375 toleranceMean_ = fracTolerance;
376 checkMeanTolerance_ =
true;
404 void useRange(
double xmin,
double xmax);
405 void useSigma(
double expectedSigma);
481 #if 0 // FIXME: need to know what parameters to set before runTest! 493 ~FlatOccupancy1d(
void)
495 delete [] FailedBins[0];
496 delete [] FailedBins[1];
499 static std::string getAlgoName(
void) {
return "RuleFlatOccupancy1d"; }
501 void set_ExclusionMask(
double *
mask) { ExclusionMask =
mask; }
503 void set_epsilon_max(
double epsilon) { epsilon_max =
epsilon; }
504 void set_S_fail(
double S) { S_fail =
S; }
505 void set_S_pass(
double S) { S_pass =
S; }
506 double get_FailedBins(
void) {
return *FailedBins[1]; }
507 int get_result() {
return result; }
512 double *ExclusionMask;
513 double epsilon_min, epsilon_max;
514 double S_fail, S_pass;
515 double *FailedBins[2];
537 delete [] FailedBins[0];
538 delete [] FailedBins[1];
560 double *FailedBins[2];
601 this->_emptyBins = 0;
626 <<
"): Entry fraction within range = " <<
prob_;
654 this->_average = 0.0;
672 <<
"): Last Bin filled with desired value = " <<
prob_;
682 #if 0 // FIXME: need to know what parameters to set before runTest! 683 class AllContentAlongDiagonal :
public SimpleTest 686 AllContentAlongDiagonal(const std::string &name) :
SimpleTest(name)
690 static std::string getAlgoName(
void) {
return "RuleAllContentAlongDiagonal"; }
693 void set_S_fail(
double S) { S_fail =
S; }
694 void set_S_pass(
double S) { S_pass =
S; }
695 double get_epsilon_obs() {
return epsilon_obs; }
696 double get_S_fail_obs() {
return S_fail_obs; }
697 double get_S_pass_obs() {
return S_pass_obs; }
698 int get_result() {
return result; }
706 double S_fail, S_pass;
708 double S_fail_obs, S_pass_obs;
725 #endif // DQMSERVICES_CORE_Q_CRITERION_H
ContentsWithinExpected ContentsWithinExpectedROOT
void setErrorProb(float prob)
std::string getMessage(void) const
get message attached to test
void set_epsilon_min(double epsilon)
FixedFlatOccupancy1d FixedFlatOccupancy1dROOT
static std::string getAlgoName(void)
get algorithm name
static std::string getAlgoName(void)
Comp2RefEqualH(const std::string &name)
void setAlgoName(std::string name)
set algorithm name
std::string getName(void) const
get name of quality test
test that histogram contents are above Ymin
double ymin_
ymin - threshold
CSC01(const std::string &name)
SimpleTest(const std::string &name, bool keepBadChannels=false)
void set_ExclusionMask(double *mask)
void setUseEmptyBins(unsigned int useEmptyBins)
static std::string getAlgoName(void)
FlatOccupancy1d FlatOccupancy1dROOT
virtual void setAllowedXRange(double xmin, double xmax)
set allowed range in X-axis (default values: histogram's X-range)
float runTest(const MonitorElement *me, QReport &qr, DQMNet::QValue &qv)
FlatOccupancy1d RuleFlatOccupancy1d
std::string algoName_
name of quality test
Comp2RefChi2 Comp2RefChi2ROOT
static std::string getAlgoName(void)
virtual std::vector< DQMChannel > getBadChannels(void) const
get vector of channels that failed test (not always relevant!)
NoisyChannel NoisyChannelROOT
void setNumNeighbors(unsigned n)
static std::string getAlgoName(void)
Algorithm for testing if histogram's mean value is near expected value.
CheckVariance(const std::string &name)
DeadChannel(const std::string &name)
ContentsXRange(const std::string &name)
Check if any channels are noisy compared to neighboring ones.
AllContentAlongDiagonal RuleAllContentAlongDiagonal
Comp2RefEqualH Comp2RefEqualHROOT
ContentsXRange ContentsXRangeROOT
CompareToMedian CompareToMedianROOT
virtual void setMessage(void)
set status & message after test has run
CompareLastFilledBin CompareLastFilledBinROOT
FixedFlatOccupancy1d RuleFixedFlatOccupancy1d
CheckVariance CheckVarianceROOT
FixedFlatOccupancy1d(const std::string &name)
Comp2RefKolmogorov Comp2RefKolmogorovROOT
void set_Occupancy(double level)
static std::string getAlgoName(void)
void set_epsilon_max(double epsilon)
static std::string getAlgoName(void)
float prob_
name of algorithm
std::string algoName(void) const
get algorithm name
CompareLastFilledBin(const std::string &name)
static const float ERROR_PROB_THRESHOLD
void setTolerance(float percentage)
unsigned int useEmptyBins_
static std::string getAlgoName(void)
void setMinimumEntries(unsigned n)
set minimum # of entries needed
MeanWithinExpected MeanWithinExpectedROOT
virtual std::vector< DQMChannel > getBadChannels(void) const
ContentsWithinExpected(const std::string &name)
void setExpectedMean(double mean)
AllContentAlongDiagonal AllContentAlongDiagonalROOT
void setUseEmptyBins(unsigned int useEmptyBins)
std::string message_
quality test status
bin
set the eta bin as selection string.
static std::string getAlgoName(void)
void set_epsilon_max(double epsilon)
int getStatus(void) const
(class should be created by DQMStore class)
NoisyChannel(const std::string &name)
virtual float runTest(const MonitorElement *me)
void set_S_pass(double S)
std::vector< DQMChannel > badChannels_
void setWarningProb(float prob)
set probability limit for warning and error (default: 90% and 50%)
double S(const TLorentzVector &, const TLorentzVector &)
MeanWithinExpected(const std::string &name)
Comparison to reference using the Kolmogorov algorithm.
static std::string getAlgoName(void)
void init(void)
initialize values
void setVerbose(int verbose)
probability limits for warnings, errors
static std::string getAlgoName(void)
void set_S_fail(double S)
DeadChannel DeadChannelROOT
QCriterion(std::string qtname)
std::vector< DQMChannel > badChannels_
static const int STATUS_OK
ContentsYRange(const std::string &name)
ContentsYRange ContentsYRangeROOT
virtual ~QCriterion(void)
void setMeanTolerance(float fracTolerance)
set (fractional) tolerance for mean
Comp2RefChi2(const std::string &name)
void setThreshold(double ymin)
set Ymin (inclusive) threshold for "dead" channel (default: 0)
void setMessage(void)
set status & message after test has run
void set_S_fail(double S)
void setAverage(float average)
~FixedFlatOccupancy1d(void)
virtual void setAllowedYRange(double ymin, double ymax)
void reset(double vett[256])
void set_S_pass(double S)
unsigned int useEmptyBins_
float warningProb_
message attached to test
double get_FailedBins(void)
virtual void setMessage(void)=0
set message after test has run
static std::string getAlgoName(void)
static std::string getAlgoName(void)
static const float WARNING_PROB_THRESHOLD
default "probability" values for setting warnings & errors when running tests
Comp2RefKolmogorov(const std::string &name)
void setMessage(void)
set status & message after test has run