Commit 00a99df5 authored by dauncey's avatar dauncey
Browse files

Add Hack.hh for Mac ROOT problem and Gaussian PU mean

parent 89394d5a
No preview for this file type
......@@ -196,6 +196,7 @@ i_x \\ i_y
\end{pmatrix}
\end{equation}
\newpage
\section{Optimisation of layer weights}
Each event $e$ gives some values $d_{e,i}$ of the deposited energy in
layer $i$; these
......
......@@ -18,7 +18,7 @@ public:
const std::string &sRoot="",
const std::string &sOut="") // ctor
: fTwoPi(2.0*acos(-1.0)), fName(sName),
fTFileHandler((sOut==""?"":sOut+"/")+fName+(sRoot==""?sRoot:"_"+sRoot)) {
fTFileHandler((sOut==""?"":sOut+"/")+fName+(sRoot==""?"/Base":"/"+sRoot)) {
fEventSelect=0;
fPrintLevel=0;
......
// Run this using: trgAnalysis.exe -a 64 -s 1
// Run this using: trgAnalysis.exe -a 64 -s 5
/* TODO
Sort out BH
......@@ -6,7 +6,8 @@
Add one channel per FE ASIC always on
Wafer DAQ plots
Wafer max files
Make sensors 120mu thick
Shift pedestal up to ~50
BEFORE
Margin for error in point2DToSensorCell
......@@ -66,18 +67,6 @@ public:
kTpgCutLo=3,
kTpgCutHi=4,
// All three noise levels
//kNoiseLo=0,
//kNoiseHi=3,
// Unirradiated-only
//kNoiseLo=1,
//kNoiseHi=2,
// Irradiated-only
kNoiseLo=2,
kNoiseHi=3,
kNumberOfTpgMethods=4,
kNumberOfDaqMethods=7
};
......@@ -420,18 +409,18 @@ public:
if(sAnal>=100000) {
/*
std::ostringstream sout;
sout << "AnalysisOccupancy" << std::setw(2) << std::setfill('0')
<< sAnal << ".cfg";
std::cout << "Reading file " << sout.str() << std::endl;
std::ifstream fin(sout.str().c_str());
BACKTRACE_AND_ASSERT(fin);
unsigned xxx;
fin >> xxx;
std::cout << " Argument parameter = " << xxx << std::endl;
BACKTRACE_AND_ASSERT(fin);
fin.close();
std::ostringstream sout;
sout << "AnalysisOccupancy" << std::setw(2) << std::setfill('0')
<< sAnal << ".cfg";
std::cout << "Reading file " << sout.str() << std::endl;
std::ifstream fin(sout.str().c_str());
BACKTRACE_AND_ASSERT(fin);
unsigned xxx;
fin >> xxx;
std::cout << " Argument parameter = " << xxx << std::endl;
BACKTRACE_AND_ASSERT(fin);
fin.close();
*/
nDaqTh=sAnal%10;
nTpgTh=(sAnal/10)%10;
......@@ -471,7 +460,6 @@ public:
";Layer;#rho (cm);Number",
40,0.0,40.0,200,0.0,200.0);
std::vector<std::string> sNse(numbers("Noise",3));
std::vector<std::string> sNum(numbers("MIPs",max(unsigned(kDaqCutHi),unsigned(kTpgCutHi))+1));
std::vector<std::string> sThk(numbers("Thick",3));
std::vector<std::string> sWz(numbers("Wafer",Geometry::kMaximumNumberOfWafersPerSextant+1));
......@@ -480,44 +468,42 @@ public:
";Layer;#rho (cm);Occupancy",
40,0.0,40.0,200,0.0,200.0);
for(unsigned n(kNoiseLo);n<kNoiseHi;n++) {
hThresholdOfWafer[n]=new TH2X((fName+"_"+sNse[n]+"ThresholdOfWafer").c_str(),
";Layer;#rho (cm);Threshold (MIPs)",
40,0.0,40.0,50,0.0,200.0);
hThresholdOfWafer=new TH2X((fName+"_"+"ThresholdOfWafer").c_str(),
";Layer;#rho (cm);Threshold (MIPs)",
40,0.0,40.0,50,0.0,200.0);
for(unsigned i(kDaqCutLo);i<kDaqCutHi;i++) {
hNumberOfWaferHits[n][i]=new TH2F((fName+"_"+sNse[n]+sNum[i+1]+"NumberOfWaferHits").c_str(),
";Layer;#rho (cm);Occupancy",
40,0.0,40.0,50,0.0,200.0);
hNumberOfCellHits[n][i]=new TH2F((fName+"_"+sNse[n]+sNum[i+1]+"NumberOfCellHits").c_str(),
";Layer;#rho (cm);Occupancy",
40,0.0,40.0,200,0.0,200.0);
hNumberOfWaferBits[n][i]=new TH2F((fName+"_"+sNse[n]+sNum[i+1]+"NumberOfWaferBits").c_str(),
";Layer;#rho (cm);Data bits/event",
40,0.0,40.0,50,0.0,200.0);
}
for(unsigned i(kDaqCutLo);i<kDaqCutHi;i++) {
hNumberOfWaferHits[i]=new TH2F((fName+"_"+sNum[i+1]+"NumberOfWaferHits").c_str(),
";Layer;#rho (cm);Occupancy",
40,0.0,40.0,50,0.0,200.0);
hNumberOfCellHits[i]=new TH2F((fName+"_"+sNum[i+1]+"NumberOfCellHits").c_str(),
";Layer;#rho (cm);Occupancy",
40,0.0,40.0,200,0.0,200.0);
hNumberOfWaferBits[i]=new TH2F((fName+"_"+sNum[i+1]+"NumberOfWaferBits").c_str(),
";Layer;#rho (cm);Data bits/event",
40,0.0,40.0,50,0.0,200.0);
}
for(unsigned i(kTpgCutLo);i<kTpgCutHi;i++) {
for(unsigned j(0);j<3;j++) {
hFractionOfWaferTrgsMip[j][n][i]=new TH2A((fName+"_"+sThk[j]+sNse[n]+sNum[i+1]+"FractionOfWaferTrgsMip").c_str(),
";Layer;#rho (cm);Fractional occupancy",
52,0.0,52.0,60,0.0,300.0);
hNumberOfWaferTrgsMip[j][n][i]=new TH2A((fName+"_"+sThk[j]+sNse[n]+sNum[i+1]+"NumberOfWaferTrgsMip").c_str(),
";Layer;#rho (cm);Number",
52,0.0,52.0,60,0.0,300.0);
hNMaxOfWaferTrgsMip[j][n][i]=new TH2X((fName+"_"+sThk[j]+sNse[n]+sNum[i+1]+"NMaxOfWaferTrgsMip").c_str(),
";Layer;#rho (cm);Maximum number",
52,0.0,52.0,60,0.0,300.0);
hFractionOfWaferTrgsMpT[j][n][i]=new TH2A((fName+"_"+sThk[j]+sNse[n]+sNum[i+1]+"FractionOfWaferTrgsMpT").c_str(),
";Layer;#rho (cm);Fractional occupancy",
52,0.0,52.0,60,0.0,300.0);
hNumberOfWaferTrgsMpT[j][n][i]=new TH2A((fName+"_"+sThk[j]+sNse[n]+sNum[i+1]+"NumberOfWaferTrgsMpT").c_str(),
";Layer;#rho (cm);Number",
52,0.0,52.0,60,0.0,300.0);
hNMaxOfWaferTrgsMpT[j][n][i]=new TH2X((fName+"_"+sThk[j]+sNse[n]+sNum[i+1]+"NMaxOfWaferTrgsMpT").c_str(),
";Layer;#rho (cm);Maximum number",
52,0.0,52.0,60,0.0,300.0);
}
for(unsigned i(kTpgCutLo);i<kTpgCutHi;i++) {
for(unsigned j(0);j<3;j++) {
hFractionOfWaferTrgsMip[j][i]=new TH2A((fName+"_"+sThk[j]+sNum[i+1]+"FractionOfWaferTrgsMip").c_str(),
";Layer;#rho (cm);Fractional occupancy",
52,0.0,52.0,60,0.0,300.0);
hNumberOfWaferTrgsMip[j][i]=new TH2A((fName+"_"+sThk[j]+sNum[i+1]+"NumberOfWaferTrgsMip").c_str(),
";Layer;#rho (cm);Number",
52,0.0,52.0,60,0.0,300.0);
hNMaxOfWaferTrgsMip[j][i]=new TH2X((fName+"_"+sThk[j]+sNum[i+1]+"NMaxOfWaferTrgsMip").c_str(),
";Layer;#rho (cm);Maximum number",
52,0.0,52.0,60,0.0,300.0);
hFractionOfWaferTrgsMpT[j][i]=new TH2A((fName+"_"+sThk[j]+sNum[i+1]+"FractionOfWaferTrgsMpT").c_str(),
";Layer;#rho (cm);Fractional occupancy",
52,0.0,52.0,60,0.0,300.0);
hNumberOfWaferTrgsMpT[j][i]=new TH2A((fName+"_"+sThk[j]+sNum[i+1]+"NumberOfWaferTrgsMpT").c_str(),
";Layer;#rho (cm);Number",
52,0.0,52.0,60,0.0,300.0);
hNMaxOfWaferTrgsMpT[j][i]=new TH2X((fName+"_"+sThk[j]+sNum[i+1]+"NMaxOfWaferTrgsMpT").c_str(),
";Layer;#rho (cm);Maximum number",
52,0.0,52.0,60,0.0,300.0);
}
}
......@@ -557,968 +543,997 @@ public:
std::vector<std::string> sMethod(numbers("Method",kNumberOfDaqMethods));
std::vector<std::string> sGran(numbers("Granularity",3));
for(unsigned n(kNoiseLo);n<kNoiseHi;n++) {
// TOT
hDaqTotPerHgcal=new TH1F((fName+"_"+"DaqTotPerHgcal").c_str(),
";Number of TOT hits/HGCal",
100,0.0,2000.0);
hDaqTotPerLayerVsLayer=new TH2F((fName+"_"+"DaqTotPerLayerVsLayer").c_str(),
";Layer number;Number of TOT hits/layer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
100,0.0,50.0);
hDaqTotPerLayerVsLayerA=new TH1A((fName+"_"+"DaqTotPerLayerVsLayer").c_str(),
";Layer number;Number of TOT hits/layer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2);
hDaqTotPerLayerVsLayerX=new TH1X((fName+"_"+"DaqTotPerLayerVsLayerX").c_str(),
";Layer number;Number of TOT hits/layer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2);
hDaqTotPerPanelVsPanelLayerA=new TH2A((fName+"_"+"DaqTotPerPanelVsPanelLayer").c_str(),
";Layer number;Panel number;Average number of TOT hits/panel",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqTotPerPanelVsPanelLayerX=new TH2X((fName+"_"+"DaqTotPerPanelVsPanelLayerX").c_str(),
";Layer number;Panel number;Maximum number of TOT hits/panel",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
for(unsigned l(0);l<Geometry::kNumberOfLayers;l++) {
hDaqTotPerLayer[l]=new TH1F((fName+"_"+sLayerLabel[l]+"DaqTotPerLayer").c_str(),
";Number of TOT hits/layer",
100,0.0,100.0);
hDaqTotPerPanelVsPanel[l]=new TH2F((fName+"_"+sLayerLabel[l]+"DaqTotPerPanelVsPanel").c_str(),
(sLayerTitle[l]+";Panel number;Number of TOT hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6,100,0.0,100.0);
hDaqTotPerPanelVsPanelA[l]=new TH1A((fName+"_"+sLayerLabel[l]+"DaqTotPerPanelVsPanel").c_str(),
(sLayerTitle[l]+";Panel number;Average number of TOT hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqTotPerPanelVsPanelX[l]=new TH1X((fName+"_"+sLayerLabel[l]+"DaqTotPerPanelVsPanelX").c_str(),
(sLayerTitle[l]+";Panel number;Maximum number of TOT hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
for(unsigned p(0);p<Geometry::kMaximumNumberOfPanelsPerLayer/6;p++) {
hDaqTotPerPanel[l][p]=new TH1F((fName+"_"+sLayerLabel[l]+sPanelLabel[p]+"DaqTotPerPanel").c_str(),
";Number of TOT hits/panel",
100,0.0,100.0);
}
}
// TOT
// TOA
hDaqToaPerHgcal=new TH1F((fName+"_"+"DaqToaPerHgcal").c_str(),
";Number of TOA hits/HGCal",
100,0.0,100000.0);
hDaqToaPerLayerVsLayer=new TH2F((fName+"_"+"DaqToaPerLayerVsLayer").c_str(),
";Layer number;Number of TOA hits/layer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
100,0.0,5000.0);
hDaqToaPerLayerVsLayerA=new TH1A((fName+"_"+"DaqToaPerLayerVsLayer").c_str(),
";Layer number;Number of TOA hits/layer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2);
hDaqToaPerLayerVsLayerX=new TH1X((fName+"_"+"DaqToaPerLayerVsLayerX").c_str(),
";Layer number;Number of TOA hits/layer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2);
hDaqToaPerPanelVsPanelLayerA=new TH2A((fName+"_"+"DaqToaPerPanelVsPanelLayer").c_str(),
";Layer number;Panel number;Average number of TOA hits/panel",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqToaPerPanelVsPanelLayerX=new TH2X((fName+"_"+"DaqToaPerPanelVsPanelLayerX").c_str(),
";Layer number;Panel number;Maximum number of TOA hits/panel",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqTotPerHgcal[n]=new TH1F((fName+"_"+sNse[n]+"DaqTotPerHgcal").c_str(),
";Number of TOT hits/HGCal",
100,0.0,5000.0);
for(unsigned l(0);l<Geometry::kNumberOfLayers;l++) {
hDaqToaPerLayer[l]=new TH1F((fName+"_"+sLayerLabel[l]+"DaqToaPerLayer").c_str(),
";Number of TOA hits/layer",
100,0.0,100.0);
hDaqTotPerLayerVsLayer[n]=new TH2F((fName+"_"+sNse[n]+"DaqTotPerLayerVsLayer").c_str(),
";Layer number;Number of TOT hits/layer",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers,
hDaqToaPerPanelVsPanel[l]=new TH2F((fName+"_"+sLayerLabel[l]+"DaqToaPerPanelVsPanel").c_str(),
(sLayerTitle[l]+";Panel number;Number of TOA hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6,
100,0.0,100.0);
hDaqTotPerLayerVsLayerA[n]=new TH1A((fName+"_"+sNse[n]+"DaqTotPerLayerVsLayer").c_str(),
";Layer number;Number of TOT hits/layer",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers);
hDaqTotPerLayerVsLayerX[n]=new TH1X((fName+"_"+sNse[n]+"DaqTotPerLayerVsLayerX").c_str(),
";Layer number;Number of TOT hits/layer",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers);
hDaqToaPerPanelVsPanelA[l]=new TH1A((fName+"_"+sLayerLabel[l]+"DaqToaPerPanelVsPanel").c_str(),
(sLayerTitle[l]+";Panel number;Average number of TOA hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqToaPerPanelVsPanelX[l]=new TH1X((fName+"_"+sLayerLabel[l]+"DaqToaPerPanelVsPanelX").c_str(),
(sLayerTitle[l]+";Panel number;Maximum number of TOA hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
for(unsigned p(0);p<Geometry::kMaximumNumberOfPanelsPerLayer/6;p++) {
hDaqToaPerPanel[l][p]=new TH1F((fName+"_"+sLayerLabel[l]+sPanelLabel[p]+"DaqToaPerPanel").c_str(),
(sLayerTitle[l]+";Number of TOA hits/panel").c_str(),
100,0.0,100.0);
}
}
hDaqTotPerPanelVsPanelLayerA[n]=new TH2A((fName+"_"+sNse[n]+"DaqTotPerPanelVsPanelLayer").c_str(),
";Layer number;Panel number;Average number of TOT hits/panel",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers,
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqTotPerPanelVsPanelLayerX[n]=new TH2X((fName+"_"+sNse[n]+"DaqTotPerPanelVsPanelLayerX").c_str(),
";Layer number;Panel number;Maximum number of TOT hits/panel",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers,
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
// ABX
hDaqAbxPerHgcal=new TH1F((fName+"_"+"DaqAbxPerHgcal").c_str(),
";Number of TOA hits/HGCal",
100,0.0,500000.0);
hDaqAbxPerLayerVsLayer=new TH2F((fName+"_"+"DaqAbxPerLayerVsLayer").c_str(),
";Layer number;Number of TOA hits/layer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
100,0.0,10000.0);
hDaqAbxPerLayerVsLayerA=new TH1A((fName+"_"+"DaqAbxPerLayerVsLayer").c_str(),
";Layer number;Number of TOA hits/layer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2);
hDaqAbxPerLayerVsLayerX=new TH1X((fName+"_"+"DaqAbxPerLayerVsLayerX").c_str(),
";Layer number;Number of TOA hits/layer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2);
for(unsigned l(0);l<Geometry::kNumberOfLayers;l++) {
hDaqTotPerLayer[n][l]=new TH1F((fName+"_"+sNse[n]+sLayerLabel[l]+"DaqTotPerLayer").c_str(),
";Number of TOT hits/layer",
100,0.0,100.0);
hDaqAbxPerPanelVsPanelLayerA=new TH2A((fName+"_"+"DaqAbxPerPanelVsPanelLayer").c_str(),
";Layer number;Panel number;Average number of TOA hits/panel",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqAbxPerPanelVsPanelLayerX=new TH2X((fName+"_"+"DaqAbxPerPanelVsPanelLayerX").c_str(),
";Layer number;Panel number;Maximum number of TOA hits/panel",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqTotPerPanelVsPanel[n][l]=new TH2F((fName+"_"+sNse[n]+sLayerLabel[l]+"DaqTotPerPanelVsPanel").c_str(),
(sLayerTitle[l]+";Panel number;Number of TOT hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6,100,0.0,100.0);
hDaqTotPerPanelVsPanelA[n][l]=new TH1A((fName+"_"+sNse[n]+sLayerLabel[l]+"DaqTotPerPanelVsPanel").c_str(),
(sLayerTitle[l]+";Panel number;Average number of TOT hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqTotPerPanelVsPanelX[n][l]=new TH1X((fName+"_"+sNse[n]+sLayerLabel[l]+"DaqTotPerPanelVsPanelX").c_str(),
(sLayerTitle[l]+";Panel number;Maximum number of TOT hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
for(unsigned l(0);l<Geometry::kNumberOfLayers;l++) {
hDaqAbxPerLayer[l]=new TH1F((fName+"_"+sLayerLabel[l]+"DaqAbxPerLayer").c_str(),
";Number of TOA hits/layer",
100,0.0,100.0);
hDaqAbxPerPanelVsPanel[l]=new TH2F((fName+"_"+sLayerLabel[l]+"DaqAbxPerPanelVsPanel").c_str(),
(sLayerTitle[l]+";Panel number;Number of TOA hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6,
100,0.0,100.0);
hDaqAbxPerPanelVsPanelA[l]=new TH1A((fName+"_"+sLayerLabel[l]+"DaqAbxPerPanelVsPanel").c_str(),
(sLayerTitle[l]+";Panel number;Average number of TOA hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqAbxPerPanelVsPanelX[l]=new TH1X((fName+"_"+sLayerLabel[l]+"DaqAbxPerPanelVsPanelX").c_str(),
(sLayerTitle[l]+";Panel number;Maximum number of TOA hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
for(unsigned p(0);p<Geometry::kMaximumNumberOfPanelsPerLayer/6;p++) {
hDaqTotPerPanel[n][l][p]=new TH1F((fName+"_"+sNse[n]+sLayerLabel[l]+sPanelLabel[p]+"DaqTotPerPanel").c_str(),
";Number of TOT hits/panel",
100,0.0,100.0);
}
for(unsigned p(0);p<Geometry::kMaximumNumberOfPanelsPerLayer/6;p++) {
hDaqAbxPerPanel[l][p]=new TH1F((fName+"_"+sLayerLabel[l]+sPanelLabel[p]+"DaqAbxPerPanel").c_str(),
(sLayerTitle[l]+";Number of TOA hits/panel").c_str(),
100,0.0,100.0);
}
}
// ADC
// TOA
hDaqPrePerLayerVsLayerA=new TH1A((fName+"_"+"DaqPrePerLayerVsLayer").c_str(),
";Layer number;Number of previous ADC hits/layer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2);
hDaqToaPerHgcal[n]=new TH1F((fName+"_"+sNse[n]+"DaqToaPerHgcal").c_str(),
";Number of TOA hits/HGCal",
100,0.0,100000.0);
for(unsigned i(kDaqCutLo);i<kDaqCutHi;i++) {
hDaqAdcValues[i]=new TH1D((fName+"_"+sNum[i+1]+"DaqAdcValues").c_str(),
";ADC values",
2048,0.0,2048.0);
for(unsigned j(0);j<3;j++) {
hDaqAdcValuesThickness[i][j]=new TH1D((fName+"_"+sNum[i+1]+sThk[j]+"DaqAdcValues").c_str(),
";ADC values",
2048,0.0,2048.0);
}
hDaqToaPerLayerVsLayer[n]=new TH2F((fName+"_"+sNse[n]+"DaqToaPerLayerVsLayer").c_str(),
";Layer number;Number of TOA hits/layer",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers,
100,0.0,2000.0);
hDaqToaPerLayerVsLayerA[n]=new TH1A((fName+"_"+sNse[n]+"DaqToaPerLayerVsLayer").c_str(),
";Layer number;Number of TOA hits/layer",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers);
hDaqToaPerLayerVsLayerX[n]=new TH1X((fName+"_"+sNse[n]+"DaqToaPerLayerVsLayerX").c_str(),
";Layer number;Number of TOA hits/layer",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers);
hDaqToaPerPanelVsPanelLayerA[n]=new TH2A((fName+"_"+sNse[n]+"DaqToaPerPanelVsPanelLayer").c_str(),
";Layer number;Panel number;Average number of TOA hits/panel",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers,
hDaqAdcPerHgcal[i]=new TH1F((fName+"_"+sNum[i+1]+"DaqAdcPerHgcal").c_str(),
";Number of ADC hits/HGCal",
100,0.0,1000000.0);
hDaqAdcPerHgcalVsPu[i]=new TH2F((fName+"_"+sNum[i+1]+"DaqAdcPerHgcalVsPu").c_str(),
";Number of PU interactions;Number of ADC hits/HGCal",
100,0.0,500.0,
100,0.0,1000000.0);
hDaqAdcPerHgcalVsPuA[i]=new TH1A((fName+"_"+sNum[i+1]+"DaqAdcPerHgcalVsPu").c_str(),
";Number of PU interactions;Number of ADC hits/HGCal",
100,0.0,500.0);
hDaqAdcPerLayerVsLayer[i]=new TH2F((fName+"_"+sNum[i+1]+"DaqAdcPerLayerVsLayer").c_str(),
";Layer number;Number of ADC hits/layer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
100,0.0,20000.0);
hDaqAdcPerLayerVsLayerA[i]=new TH1A((fName+"_"+sNum[i+1]+"DaqAdcPerLayerVsLayer").c_str(),
";Layer number;Number of ADC hits/layer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2);
hDaqAdcPerLayerVsLayerX[i]=new TH1X((fName+"_"+sNum[i+1]+"DaqAdcPerLayerVsLayerX").c_str(),
";Layer number;Maximum number of ADC hits/layer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2);
hDaqAdcPerPanelVsPanelLayerA[i]=new TH2A((fName+"_"+sNum[i+1]+"DaqAdcPerPanelVsPanelLayer").c_str(),
";Layer number;Panel number;Average number of ADC hits/panel",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqToaPerPanelVsPanelLayerX[n]=new TH2X((fName+"_"+sNse[n]+"DaqToaPerPanelVsPanelLayerX").c_str(),
";Layer number;Panel number;Maximum number of TOA hits/panel",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers,
hDaqAdcPerPanelVsPanelLayerX[i]=new TH2X((fName+"_"+sNum[i+1]+"DaqAdcPerPanelVsPanelLayerX").c_str(),
";Layer number;Panel number;Maximum number of ADC hits/panel",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
for(unsigned l(0);l<Geometry::kNumberOfLayers;l++) {
hDaqToaPerLayer[n][l]=new TH1F((fName+"_"+sNse[n]+sLayerLabel[l]+"DaqToaPerLayer").c_str(),
";Number of TOA hits/layer",
100,0.0,100.0);
hDaqAdcPerWaferVsWaferLayerA[i]=new TH2A((fName+"_"+sNum[i+1]+"DaqAdcPerWaferVsWaferLayer").c_str(),
";Layer number;Wafer number;Average number of DAQ ADCs/wafer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
Geometry::kMaximumNumberOfWafersPerSextant,0.0,Geometry::kMaximumNumberOfWafersPerSextant);
hDaqAdcPerWaferVsWaferLayerX[i]=new TH2X((fName+"_"+sNum[i+1]+"DaqAdcPerWaferVsWaferLayerX").c_str(),
";Layer number;Wafer number;Maximum number of DAQ ADCs/wafer",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
Geometry::kMaximumNumberOfWafersPerSextant,0.0,Geometry::kMaximumNumberOfWafersPerSextant);
for(unsigned wz(0);wz<Geometry::kMaximumNumberOfWafersPerSextant;wz++) {
hDaqAdcPerWafer[i][wz]=new TH1F((fName+"_"+sNum[i+1]+"Layer04"+sWz[wz]+"DaqAdcPerWafer").c_str(),
";Number of DAQ ADCs/wafer",
Geometry::kMaximumNumberOfSensorCellsPerWafer,0.0,Geometry::kMaximumNumberOfSensorCellsPerWafer);
}
hDaqToaPerPanelVsPanel[n][l]=new TH2F((fName+"_"+sNse[n]+sLayerLabel[l]+"DaqToaPerPanelVsPanel").c_str(),
(sLayerTitle[l]+";Panel number;Number of TOA hits/panel").c_str(),
hDaqAdcPerAsicVsAsicLayerA[i]=new TH2A((fName+"_"+sNum[i+1]+"DaqAdcPerAsicVsAsicLayer").c_str(),
";Layer number;ASIC number;Average number of DAQ ADCs/ASIC",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
kMaxAsicsPerSextant,0.0,kMaxAsicsPerSextant);
hDaqAdcPerAsicVsAsicLayerX[i]=new TH2X((fName+"_"+sNum[i+1]+"DaqAdcPerAsicVsAsicLayerX").c_str(),
";Layer number;ASIC number;Maximum number of DAQ ADCs/ASIC",
Geometry::kNumberOfLayers+2,0.0,Geometry::kNumberOfLayers+2,
kMaxAsicsPerSextant,0.0,kMaxAsicsPerSextant);
for(unsigned l(0);l<Geometry::kNumberOfLayers;l++) {
hDaqAdcRatioVsRho[i][l]=new TH1R((fName+"_"+sNum[i+1]+sLayerLabel[l]+"DaqAdcRatioVsRho").c_str(),
";#rho (cm);ADC hits",
100,0.0,200.0);
hDaqAdcRatioVsSensorCell[i][l][0]=new TH1R((fName+"_"+sNum[i+1]+sLayerLabel[l]+"DaqAdcRatioVsSensorCell0").c_str(),
";Thickness 0 sensor cell;ADC hits",
Geometry::numberOfSensorCellsPerWafer(1),0.0,Geometry::numberOfSensorCellsPerWafer(1));
hDaqAdcRatioVsSensorCell[i][l][1]=new TH1R((fName+"_"+sNum[i+1]+sLayerLabel[l]+"DaqAdcRatioVsSensorCell1").c_str(),
";Thickness 1 sensor cell;ADC hits",
Geometry::numberOfSensorCellsPerWafer(0),0.0,Geometry::numberOfSensorCellsPerWafer(0));
hDaqAdcRatioVsSensorCell[i][l][2]=new TH1R((fName+"_"+sNum[i+1]+sLayerLabel[l]+"DaqAdcRatioVsSensorCell2").c_str(),
";Thickness 2 sensor cell;ADC hits",
Geometry::numberOfSensorCellsPerWafer(0),0.0,Geometry::numberOfSensorCellsPerWafer(0));
hDaqAdcPerLayer[i][l]=new TH1F((fName+"_"+sNum[i+1]+sLayerLabel[l]+"DaqAdcPerLayer").c_str(),
";Number of ADC hits/layer",
100,0.0,10000.0);
hDaqAdcPerPanelVsPanel[i][l]=new TH2F((fName+"_"+sNum[i+1]+sLayerLabel[l]+"DaqAdcPerPanelVsPanel").c_str(),
(sLayerTitle[l]+";Panel number;Number of ADC hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6,
100,0.0,100.0);
hDaqToaPerPanelVsPanelA[n][l]=new TH1A((fName+"_"+sNse[n]+sLayerLabel[l]+"DaqToaPerPanelVsPanel").c_str(),
(sLayerTitle[l]+";Panel number;Average number of TOA hits/panel").c_str(),
100,0.0,2000.0);
hDaqAdcPerPanelVsPanelA[i][l]=new TH1A((fName+"_"+sNum[i+1]+sLayerLabel[l]+"DaqAdcPerPanelVsPanel").c_str(),
(sLayerTitle[l]+";Panel number;Average number of ADC hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqToaPerPanelVsPanelX[n][l]=new TH1X((fName+"_"+sNse[n]+sLayerLabel[l]+"DaqToaPerPanelVsPanelX").c_str(),
(sLayerTitle[l]+";Panel number;Maximum number of TOA hits/panel").c_str(),
hDaqAdcPerPanelVsPanelX[i][l]=new TH1X((fName+"_"+sNum[i+1]+sLayerLabel[l]+"DaqAdcPerPanelVsPanelX").c_str(),
(sLayerTitle[l]+";Panel number;Maximum number of ADC hits/panel").c_str(),
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
for(unsigned p(0);p<Geometry::kMaximumNumberOfPanelsPerLayer/6;p++) {
hDaqToaPerPanel[n][l][p]=new TH1F((fName+"_"+sNse[n]+sLayerLabel[l]+sPanelLabel[p]+"DaqToaPerPanel").c_str(),
(sLayerTitle[l]+";Number of TOA hits/panel").c_str(),
100,0.0,100.0);
hDaqAdcPerPanel[i][l][p]=new TH1F((fName+"_"+sNum[i+1]+sLayerLabel[l]+sPanelLabel[p]+"DaqAdcPerPanel").c_str(),
(sLayerTitle[l]+";Number of ADC hits/panel").c_str(),
100,0.0,2000.0);
}
}
// ADC
hDaqPrePerLayerVsLayerA[n]=new TH1A((fName+"_"+sNse[n]+"DaqPrePerLayerVsLayer").c_str(),
";Layer number;Number of previous ADC hits/layer",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers);
for(unsigned i(kDaqCutLo);i<kDaqCutHi;i++) {
hDaqAdcValues[n][i]=new TH1D((fName+"_"+sNse[n]+sNum[i+1]+"DaqAdcValues").c_str(),
";ADC values",
2048,0.0,2048.0);
for(unsigned j(0);j<3;j++) {
hDaqAdcValuesThickness[n][i][j]=new TH1D((fName+"_"+sNse[n]+sNum[i+1]+sThk[j]+"DaqAdcValues").c_str(),
";ADC values",
2048,0.0,2048.0);
}
hDaqAdcPerHgcal[n][i]=new TH1F((fName+"_"+sNse[n]+sNum[i+1]+"DaqAdcPerHgcal").c_str(),
";Number of ADC hits/HGCal",
100,0.0,2000000.0);
hDaqAdcPerLayerVsLayer[n][i]=new TH2F((fName+"_"+sNse[n]+sNum[i+1]+"DaqAdcPerLayerVsLayer").c_str(),
";Layer number;Number of ADC hits/layer",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers,
100,0.0,2000.0);
hDaqAdcPerLayerVsLayerA[n][i]=new TH1A((fName+"_"+sNse[n]+sNum[i+1]+"DaqAdcPerLayerVsLayer").c_str(),
";Layer number;Number of ADC hits/layer",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers);
hDaqAdcPerLayerVsLayerX[n][i]=new TH1X((fName+"_"+sNse[n]+sNum[i+1]+"DaqAdcPerLayerVsLayerX").c_str(),
";Layer number;Maximum number of ADC hits/layer",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers);
hDaqAdcPerPanelVsPanelLayerA[n][i]=new TH2A((fName+"_"+sNse[n]+sNum[i+1]+"DaqAdcPerPanelVsPanelLayer").c_str(),
";Layer number;Panel number;Average number of ADC hits/panel",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers,
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqAdcPerPanelVsPanelLayerX[n][i]=new TH2X((fName+"_"+sNse[n]+sNum[i+1]+"DaqAdcPerPanelVsPanelLayerX").c_str(),
";Layer number;Panel number;Maximum number of ADC hits/panel",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers,
Geometry::kMaximumNumberOfPanelsPerLayer/6,0.0,Geometry::kMaximumNumberOfPanelsPerLayer/6);
hDaqAdcPerWaferVsWaferLayerA[n][i]=new TH2A((fName+"_"+sNse[n]+sNum[i+1]+"DaqAdcPerWaferVsWaferLayer").c_str(),
";Layer number;Wafer number;Average number of DAQ ADCs/wafer",
Geometry::kNumberOfLayers,0.0,Geometry::kNumberOfLayers,