1 #ifndef DQMSERVICES_CORE_Q_CRITERION_H 2 #define DQMSERVICES_CORE_Q_CRITERION_H 5 #include "TProfile2D.h" 49 virtual std::vector<DQMChannel>
getBadChannels()
const {
return std::vector<DQMChannel>(); }
82 <<
" / Prob = " <<
prob_ << std::endl;
247 if (percentage >= 0) {
308 if (factorNoisy >= 0) {
314 if (factorDead >= 0) {
383 if (fracTolerance >= 0.0) {
409 void useSigma(
double expectedSigma);
484 #if 0 // FIXME: need to know what parameters to set before runTest! 496 ~FlatOccupancy1d(
void)
498 delete [] FailedBins[0];
499 delete [] FailedBins[1];
502 static std::string getAlgoName(
void) {
return "RuleFlatOccupancy1d"; }
504 void set_ExclusionMask(
double *
mask) { ExclusionMask =
mask; }
507 void set_S_fail(
double S) { S_fail =
S; }
508 void set_S_pass(
double S) { S_pass =
S; }
509 double get_FailedBins(
void) {
return *FailedBins[1]; }
510 int get_result() {
return result; }
515 double *ExclusionMask;
516 double epsilon_min, epsilon_max;
517 double S_fail, S_pass;
518 double *FailedBins[2];
619 std::ostringstream message;
662 std::ostringstream message;
663 message <<
"Test " <<
qtname_ <<
" (" <<
algoName_ <<
"): Last Bin filled with desired value = " <<
prob_;
673 #if 0 // FIXME: need to know what parameters to set before runTest! 674 class AllContentAlongDiagonal :
public SimpleTest 677 AllContentAlongDiagonal(const std::string &name) :
SimpleTest(name)
681 static std::string getAlgoName(
void) {
return "RuleAllContentAlongDiagonal"; }
684 void set_S_fail(
double S) { S_fail =
S; }
685 void set_S_pass(
double S) { S_pass =
S; }
686 double get_epsilon_obs() {
return epsilon_obs; }
687 double get_S_fail_obs() {
return S_fail_obs; }
688 double get_S_pass_obs() {
return S_pass_obs; }
689 int get_result() {
return result; }
697 double S_fail, S_pass;
699 double S_fail_obs, S_pass_obs;
712 #endif // DQMSERVICES_CORE_Q_CRITERION_H
void setErrorProb(float prob)
MonitorElementData::QReport::DQMChannel DQMChannel
void set_epsilon_min(double epsilon)
void setAlgoName(std::string name)
set algorithm name
std::string getName() 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)
void setXMax(unsigned xMax)
virtual void setAllowedXRange(double xmin, double xmax)
set allowed range in X-axis (default values: histogram's X-range)
void setMessage() override
set status & message after test has run
double getAverage(int bin, const TH1 *h) const
float runTest(const MonitorElement *me, QReport &qr, DQMNet::QValue &qv)
std::string algoName_
name of quality test
double getAverage2D(int binX, int binY, const TH2 *h) const
void setRMSRange(double xmin, double xmax)
set expected value for mean
void useSigma(double expectedSigma)
float runTest(const MonitorElement *me) override
virtual ~QCriterion()=default
float runTest(const MonitorElement *me) override
float runTest(const MonitorElement *me) override
void setNumNeighbors(unsigned n)
void init()
initialize values
Algorithm for testing if histogram's mean value is near expected value.
~CompareLastFilledBin() override=default
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.
ContentSigma(const std::string &name)
double getNeighborSigma(double average, unsigned groupx, unsigned groupy, unsigned Xblocks, unsigned Yblocks, unsigned neighborsX, unsigned neighborsY, const TH1 *h) const
float runTest(const MonitorElement *me) override
void setYMax(unsigned yMax)
int getStatus() const
get test status
static std::string getAlgoName()
float runTest(const MonitorElement *me) override
FixedFlatOccupancy1d(const std::string &name)
void setYMin(unsigned yMin)
void set_Occupancy(double level)
void set_epsilon_max(double epsilon)
float prob_
name of algorithm
dqm::legacy::MonitorElement MonitorElement
(class should be created by DQMStore class)
static std::string getAlgoName()
CompareLastFilledBin(const std::string &name)
static const float ERROR_PROB_THRESHOLD
void setTolerance(float percentage)
void setMessage() override
set status & message after test has run
unsigned int useEmptyBins_
float runTest(const MonitorElement *me) override
void setMinimumEntries(unsigned n)
set minimum # of entries needed
ContentsWithinExpected(const std::string &name)
float runTest(const MonitorElement *me) override
void setBadChannels(std::vector< DQMChannel > badChannels)
void setExpectedMean(double mean)
void setUseEmptyBins(unsigned int useEmptyBins)
std::string message_
quality test status
void useRange(double xmin, double xmax)
void set_epsilon_max(double epsilon)
void setNumNeighborsX(unsigned ncx)
void setToleranceNoisy(float factorNoisy)
Check the sigma of each bin against the rest of the chamber by a factor of tolerance/.
MonitorElementData::QReport QReport
static std::string getAlgoName()
NoisyChannel(const std::string &name)
virtual void setMessage()=0
set message after test has run
float runTest(const MonitorElement *me) override
~FixedFlatOccupancy1d() override
float runTest(const MonitorElement *me) override
void set_S_pass(double S)
std::vector< DQMChannel > badChannels_
void setNumYblocks(unsigned ncy)
void setWarningProb(float prob)
set probability limit for warning and error (default: 90% and 50%)
std::vector< DQMChannel > getBadChannels() const override
get vector of channels that failed test (not always relevant!)
static std::string getAlgoName()
MeanWithinExpected(const std::string &name)
void setVerbose(int verbose)
probability limits for warnings, errors
void setMeanRange(double xmin, double xmax)
set expected value for mean
static std::string getAlgoName()
static std::string getAlgoName()
get algorithm name
void set_S_fail(double S)
float runTest(const MonitorElement *me) override
void setNoisy(bool noisy)
QCriterion(std::string qtname)
void setNumNeighborsY(unsigned ncy)
static const int STATUS_OK
double getNeighborSum(unsigned groupx, unsigned groupy, unsigned Xblocks, unsigned Yblocks, unsigned neighborsX, unsigned neighborsY, const TH1 *h) const
for each bin get sum of the surrounding neighbors
ContentsYRange(const std::string &name)
float runTest(const MonitorElement *me) override
void setXMin(unsigned xMin)
static std::string getAlgoName()
void setMeanTolerance(float fracTolerance)
set (fractional) tolerance for mean
void setThreshold(double ymin)
set Ymin (inclusive) threshold for "dead" channel (default: 0)
void set_S_fail(double S)
void setNumXblocks(unsigned ncx)
void setAverage(float average)
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
void setToleranceDead(float factorDead)
virtual void setAllowedYRange(double ymin, double ymax)
static std::string getAlgoName()
void set_S_pass(double S)
unsigned int useEmptyBins_
virtual std::vector< DQMChannel > getBadChannels() const
float warningProb_
message attached to test
std::string getMessage() const
get message attached to test
std::string algoName() const
get algorithm name
static std::string getAlgoName()
static const float WARNING_PROB_THRESHOLD
default "probability" values for setting warnings & errors when running tests
static std::string getAlgoName()
static std::string getAlgoName()