9#include <top/dbobjects/TOPCalPhotonYields.h>
10#include <framework/logging/Logger.h>
21 const TH1F* activePixels,
const TH2F* pulseHeights,
const TH1F* muonZ)
23 string slotName = (slot < 10) ?
"_0" + to_string(slot) :
"_" + to_string(slot);
26 (
"Photon yields for slot " + to_string(slot) +
"; pixel column; pixel row").c_str(),
31 (
"Background yields for slot " + to_string(slot) +
"; pixel column; pixel row").c_str(),
35 m_alphaRatio.push_back(TH2F((
"alphaRatio" + slotName).c_str(),
36 (
"Equalized alpha ratio for slot " + to_string(slot) +
"; pixel column; pixel row").c_str(),
41 (
"Active pixels for slot " + to_string(slot) +
"; pixel column; pixel row").c_str(),
53 for (
int bin = 1; bin <= input->GetNbinsX(); bin++) {
54 int row = (bin - 1) / 64 + 1;
55 int col = (bin - 1) % 64 + 1;
56 output.SetBinContent(col, row, input->GetBinContent(bin));
57 output.SetBinError(col, row, input->GetBinError(bin));
64 unsigned index = slot - 1;
72 unsigned index = slot - 1;
80 unsigned index = slot - 1;
88 unsigned index = slot - 1;
96 unsigned index = slot - 1;
104 unsigned index = slot - 1;
std::vector< TH2F > m_activePixels
active pixels (index = slot - 1)
std::vector< TH2F > m_pulseHeights
pixel pulse-heights (index = slot - 1)
std::vector< TH1F > m_muonZ
local z distribution of tracks (index = slot - 1)
std::vector< TH2F > m_alphaRatio
equalized alpha ratio per pixel (index = slot - 1)
std::vector< TH2F > m_photonYields
photon yields per pixel (index = slot - 1)
std::vector< TH2F > m_backgroundYields
background yields per pixel (index = slot - 1)
@ c_numCols
number of pixel columns
@ c_numRows
number of pixel rows
void set(int slot, const TH1F *photonYields, const TH1F *backgroundYields, const TH1F *alphaRatio, const TH1F *activePixels, const TH2F *pulseHeights, const TH1F *muonZ)
Sets the data of a given slot.
const TH2F * getAlphaRatio(int slot) const
Returns a 2D histogram of equalized pixel alpha ratio.
const TH1F * getMuonZ(int slot) const
Returns z distribution of tracks used to determine pixel yields.
const TH2F * getActivePixels(int slot) const
Returns a 2D histogram of active pixels.
const TH2F * getPulseHeights(int slot) const
Returns a 2D histogram of pixel pulse-heights.
const TH2F * getBackgroundYields(int slot) const
Returns a 2D histogram of background pixel yields.
void copyContent(const TH1F *input, TH2F &output)
Copy content of 1D histogram into 2D histogram.
const TH2F * getPhotonYields(int slot) const
Returns a 2D histogram of photon pixel yields.
Abstract base class for different kinds of events.