#include <TileBinsOutRange.h>
Definition at line 13 of file TileBinsOutRange.h.
◆ TileBinsOutRange()
dqm_algorithms::TileBinsOutRange::TileBinsOutRange |
( |
| ) |
|
◆ ~TileBinsOutRange()
virtual dqm_algorithms::TileBinsOutRange::~TileBinsOutRange |
( |
| ) |
|
|
virtualdefault |
◆ clone()
◆ execute()
dqm_core::Result * dqm_algorithms::TileBinsOutRange::execute |
( |
const std::string & |
name, |
|
|
const TObject & |
object, |
|
|
const dqm_core::AlgorithmConfig & |
config |
|
) |
| |
|
overridevirtual |
Definition at line 32 of file TileBinsOutRange.cxx.
38 if(
object.
IsA()->InheritsFrom(
"TH1" )) {
41 throw dqm_core::BadConfig( ERS_HERE,
name,
"dimension > 2 " );
44 throw dqm_core::BadConfig( ERS_HERE,
name,
"does not inherit from TH2");
54 const TProfile2D* profile2D(
nullptr);
56 if(minBinEntries > 0) {
58 else if (
object.InheritsFrom(
"TProfile2D")) profile2D =
dynamic_cast<const TProfile2D*
>(&
object);
70 double greenThreshold;
76 }
catch( dqm_core::Exception & ex ) {
77 throw dqm_core::BadConfig( ERS_HERE,
name, ex.what(), ex );
80 TH1* resultHistogram =
nullptr;
81 if (publishHistogram) {
83 resultHistogram =
static_cast<TH1*
>(
histogram->Clone());
85 throw dqm_core::BadConfig( ERS_HERE,
name,
"does not inherit from TH1" );
87 resultHistogram->Reset();
97 if (minBinEntries > 0) {
100 if (
profile->GetBinEntries(
bin) < minBinEntries) {
104 }
else if (profile2D) {
105 if (profile2D->GetBinEntries(
bin) < minBinEntries) {
112 double binValue =
histogram->GetBinContent(
i, j);
113 if((binValue == ignoreValue) || (binValue >
minValue && binValue <
maxValue ))
continue;
116 if (resultHistogram){
117 resultHistogram->SetBinContent(
i, binValue);
118 if (publish &&
nBins < maxPublish) {
125 ERS_DEBUG(1,
"Number of bad bins is " <<
nBins );
126 ERS_DEBUG(1,
"Green threshold: " << greenThreshold <<
" bin(s); Red threshold : " << redThreshold <<
" bin(s) ");
129 result->tags_[
"NSkippedBins"] = nSkippedBins;
130 if (resultHistogram)
result->object_ = boost::shared_ptr<TObject>(resultHistogram);
132 if (greenThreshold > redThreshold) {
133 if (
nBins >= greenThreshold) {
135 }
else if (
nBins > redThreshold) {
136 result->status_ = dqm_core::Result::Yellow;
141 if (
nBins <= greenThreshold) {
143 }
else if (
nBins < redThreshold) {
144 result->status_ = dqm_core::Result::Yellow;
◆ printDescription()
void dqm_algorithms::TileBinsOutRange::printDescription |
( |
std::ostream & |
out | ) |
|
Definition at line 153 of file TileBinsOutRange.cxx.
155 out <<
m_name <<
": Check number of bins which are out of range (MinValue, MaxValue) " << std::endl;
156 out <<
"Mandatory Green Threshold: MinValue: minimum value of range" << std::endl;
157 out <<
"Mandatory Green Threshold: MaxValue: maximum value of range" << std::endl;
158 out <<
"Mandatory Green/Red Threshold: NBins: Number of non-empty bins to give Green/Red result\n" << std::endl;
159 out <<
"Optional Parameter: MinStat: Minimum histogram statistics needed to perform Algorithm" << std::endl;
160 out <<
"Optional Parameter: IgnoreValue: valued to be ignored for being processed" << std::endl;
161 out <<
"Optional Parameter: MaxPublish: Max number of bins to save (default 20)" << std::endl;
162 out <<
"Optional Parameter: MinBinEntries: Minimum bin entries in profile histogram needed to check this bin (by default: -1)" << std::endl;
◆ m_name
std::string dqm_algorithms::TileBinsOutRange::m_name |
|
private |
The documentation for this class was generated from the following files: