#include <Histogram_Not_Empty.h>
Definition at line 16 of file Histogram_Not_Empty.h.
◆ Histogram_Not_Empty()
dqm_algorithms::Histogram_Not_Empty::Histogram_Not_Empty |
( |
| ) |
|
|
inline |
◆ clone()
◆ execute()
Definition at line 46 of file BasicHistoCheck.cxx.
52 if(
object.
IsA()->InheritsFrom(
"TH1" ) ) {
55 throw dqm_core::BadConfig( ERS_HERE,
name,
"dimension > 3 " );
58 throw dqm_core::BadConfig( ERS_HERE,
name,
"does not inherit from TH1" );
69 if (
m_name ==
"Histogram_Not_Empty") {
71 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" is Not Empty");
74 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" is Empty");
77 }
else if (
m_name ==
"No_OverFlows" ) {
78 const unsigned int binsx =
histogram->GetNbinsX()+1;
79 const unsigned int binsy =
histogram->GetNbinsY()+1;
80 const unsigned int binsz =
histogram->GetNbinsZ()+1;
83 if (
histogram->GetBinContent(binsx) != 0) {
84 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has OverFlows X");
89 for (
unsigned int i(0);
i <= binsx; ++
i)
91 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has OverFlows Y");
94 for (
unsigned int i(0);
i <= binsy; ++
i)
96 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has OverFlows X");
101 for (
unsigned int i(0);
i <= binsx; ++
i)
102 for (
unsigned int j(0); j <= binsy; ++j)
103 if (
histogram->GetBinContent(
i,j,binsz) != 0) {
104 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has OverFlows Z");
107 for (
unsigned int i(0);
i <= binsx; ++
i)
108 for (
unsigned int j(0); j <= binsz; ++j)
109 if (
histogram->GetBinContent(
i,binsy,j) != 0) {
110 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has OverFlows Y");
113 for (
unsigned int i(0);
i <= binsz; ++
i)
114 for (
unsigned int j(0); j <= binsy; ++j)
115 if (
histogram->GetBinContent(binsx,j,
i) != 0) {
116 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has OverFlows X");
121 throw dqm_core::BadConfig( ERS_HERE,
name,
"Something is wrong with the Dimension of the Histogram");
123 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" does NOT have OverFlows");
125 }
else if (
m_name ==
"No_UnderFlows") {
126 const unsigned int binsx =
histogram->GetNbinsX()+1;
127 const unsigned int binsy =
histogram->GetNbinsY()+1;
128 const unsigned int binsz =
histogram->GetNbinsZ()+1;
132 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has UnderFlows X");
137 for (
unsigned int i(0);
i <= binsx; ++
i)
139 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has UnderFlows Y");
142 for (
unsigned int i(0);
i <= binsy; ++
i)
144 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has UnderFlows X");
149 for (
unsigned int i(0);
i <= binsx; ++
i)
150 for (
unsigned int j(0); j <= binsy; ++j)
152 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has UnderFlows Z");
155 for (
unsigned int i(0);
i <= binsx; ++
i)
156 for (
unsigned int j(0); j <= binsz; ++j)
158 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has UnderFlows Y");
161 for (
unsigned int i(0);
i <= binsz; ++
i)
162 for (
unsigned int j(0); j <= binsy; ++j)
164 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has UnderFlows X");
169 throw dqm_core::BadConfig( ERS_HERE,
name,
"Something is wrong with the Dimension of the Histogram");
171 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" does NOT have UnderFlows");
173 }
else if (
m_name ==
"All_Bins_Filled" ) {
174 const unsigned int binsx =
histogram->GetNbinsX();
175 const unsigned int binsy =
histogram->GetNbinsY();
176 const unsigned int binsz =
histogram->GetNbinsZ();
177 for (
unsigned int i(1);
i <= binsx; ++
i ) {
178 for (
unsigned int j(1); j <= binsy; ++j ) {
179 for (
unsigned int k(1);
k<= binsz; ++
k ) {
182 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has empty bins");
189 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" has all filled bins");
193 }
else if (
m_name ==
"Histogram_Empty") {
195 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" is Empty");
198 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" is Not Empty");
201 }
else if (
m_name ==
"Histogram_Effective_Empty") {
202 if (
histogram->GetEffectiveEntries() == 0) {
203 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" is Empty");
206 ERS_DEBUG(1,
"Histogram " <<
histogram->GetName()<<
" is Not Empty");
◆ printDescription()
void dqm_algorithms::BasicHistoCheck::printDescription |
( |
std::ostream & |
out | ) |
|
|
inherited |
Definition at line 219 of file BasicHistoCheck.cxx.
221 if (
m_name ==
"All_Bins_Filled"){
222 out<<
"All_Bins_Filled: Checks that all bins of histogram are filled\n"<<std::endl;
223 }
else if (
m_name ==
"Histogram_Not_Empty"){
224 out<<
"Histogram_Not_Empty: Checks that histogram is not empty\n"<<std::endl;
225 }
else if (
m_name ==
"No_UnderFlows"){
226 out<<
"No_UnderFlows: Checks that histogram has no Underflows"<<std::endl;
227 }
else if (
m_name ==
"No_OverFlows"){
228 out<<
"No_OverFlows: Checks that histogram has no Overflows"<<std::endl;
231 }
else if (
m_name ==
"Histogram_Empty"){
232 out<<
"Histogram_Empty: Checks that histogram is empty\n"<<std::endl;
233 }
else if (
m_name ==
"Histogram_Effective_Empty"){
234 out<<
"Histogram_Not_Empty:\tChecks that histogram has no effective entries\n\t\t\t(see ROOT doc -> TH1 -> GetEffectiveEntries())\n"<<std::endl;
237 out<<
"Optional Parameter: MinStat: Minimum histogram statistics needed to perform Algorithm\n"<<std::endl;
◆ m_name
std::string dqm_algorithms::BasicHistoCheck::m_name |
|
privateinherited |
The documentation for this struct was generated from the following file: