28 <<
"[PedsOnlyAlgorithm::" << __func__ <<
"]" 29 <<
" NULL pointer to Analysis object!";
34 if ( histos.size() != 2 ) {
42 std::vector<TH1*>::const_iterator ihis = histos.begin();
43 for ( ; ihis != histos.end(); ihis++ ) {
46 if ( !(*ihis) ) {
continue; }
58 hPeds_.second = (*ihis)->GetName();
60 hNoise_.second = (*ihis)->GetName();
65 hPeds_.second = (*ihis)->GetName();
68 hNoise_.second = (*ihis)->GetName();
83 <<
"[PedsOnlyAlgorithm::" << __func__ <<
"]" 84 <<
" NULL pointer to base Analysis object!";
92 <<
"[PedsOnlyAlgorithm::" << __func__ <<
"]" 93 <<
" NULL pointer to derived Analysis object!";
107 TProfile* peds_histo =
dynamic_cast<TProfile*
>(
hPeds_.first);
108 TProfile* raw_histo =
dynamic_cast<TProfile*
>(
hNoise_.first);
120 if ( peds_histo->GetNbinsX() != 256 ) {
125 if ( raw_histo->GetNbinsX() != 256 ) {
131 for ( uint16_t iapv = 0; iapv < 2; iapv++ ) {
138 for ( uint16_t istr = 0; istr < 128; istr++ ) {
140 uint16_t
strip = iapv*128 + istr;
144 if ( peds_histo->GetBinEntries(strip+1) ) {
145 anal->
peds_[iapv][istr] = peds_histo->GetBinContent(strip+1);
146 p_sum += anal->
peds_[iapv][istr];
147 p_sum2 += (anal->
peds_[iapv][istr] * anal->
peds_[iapv][istr]);
148 if ( anal->
peds_[iapv][istr] > p_max ) { p_max = anal->
peds_[iapv][istr]; }
149 if ( anal->
peds_[iapv][istr] < p_min ) { p_min = anal->
peds_[iapv][istr]; }
156 if ( raw_histo->GetBinEntries(strip+1) ) {
157 anal->
raw_[iapv][istr] = raw_histo->GetBinContent(strip+1);
158 r_sum += anal->
raw_[iapv][istr];
159 r_sum2 += ( anal->
raw_[iapv][istr] * anal->
raw_[iapv][istr] );
160 if ( anal->
raw_[iapv][istr] > r_max ) { r_max = anal->
raw_[iapv][istr]; }
161 if ( anal->
raw_[iapv][istr] < r_min ) { r_min = anal->
raw_[iapv][istr]; }
166 if ( peds_histo->GetBinEntries(strip+1) ) {
167 anal->
raw_[iapv][istr] = raw_histo->GetBinError(strip+1);
168 r_sum += anal->
raw_[iapv][istr];
169 r_sum2 += ( anal->
raw_[iapv][istr] * anal->
raw_[iapv][istr] );
170 if ( anal->
raw_[iapv][istr] > r_max ) { r_max = anal->
raw_[iapv][istr]; }
171 if ( anal->
raw_[iapv][istr] < r_min ) { r_min = anal->
raw_[iapv][istr]; }
179 if ( !anal->
peds_[iapv].empty() ) {
180 p_sum /=
static_cast<float>( anal->
peds_[iapv].size() );
181 p_sum2 /=
static_cast<float>( anal->
peds_[iapv].size() );
187 if ( !anal->
raw_[iapv].empty() ) {
188 r_sum /=
static_cast<float>( anal->
raw_[iapv].size() );
189 r_sum2 /=
static_cast<float>( anal->
raw_[iapv].size() );
static const char unexpectedTask_[]
Histogram-based analysis for pedestal run.
const uint32_t & fedKey() const
Utility class that holds histogram title.
static const char numberOfHistos_[]
void extract(const std::vector< TH1 * > &) override
static const char unexpectedExtraInfo_[]
static const char numberOfBins_[]
static const char mlCommissioning_[]
uint32_t extractFedKey(const TH1 *const )
static const uint16_t maximum_
virtual void addErrorCode(const std::string &error)
static const uint16_t invalid_
std::vector< std::vector< double > > tmp
Abstract base for derived classes that provide analysis of commissioning histograms.
CommissioningAnalysis *const anal() const
static const char nullPtr_[]