31 : FairTask(name, iVerbose)
35 , fMvdMCHitsStations()
36 , fWordsPerRegion(nullptr)
37 , fWordsPerRegion2(nullptr)
38 , fWordsPerWorstRegion(nullptr)
39 , fWordsPerSuperRegion(nullptr)
40 , fWorstSuperPerEvent(nullptr)
41 , fMvdBankDist(nullptr)
42 , fMvdMCWorst(nullptr)
43 , fMvdMCWorstDelta(nullptr)
44 , fMvdDataLoadPerSensor(nullptr)
45 , fMvdDataLoadHotSensor(nullptr)
47 , fMvdDataPerSuperRegion()
79 for (Int_t i = 0; i < 63; i++) {
80 fMvdMCBank[i] =
new TH2F(Form(
"fMvdMCBank%d", i),
"Mvd mc distribution worst spot only delta electrons", 300, -2, 0,
84 fMvdMCHitsStations[0] =
new TH2F(
"fMvdMCStation0",
"Mvd mc distribution", 2, -2.5, -0.5, 3, -0.5, 2.5);
85 fMvdMCHitsStations[1] =
new TH2F(
"fMvdMCStation1",
"Mvd mc distribution", 4, -4.5, -0.5, 6, -0.5, 5.5);
86 fMvdMCHitsStations[2] =
new TH2F(
"fMvdMCStation2",
"Mvd mc distribution", 6, -7.5, -1.5, 9, -1.5, 7.5);
87 fMvdMCHitsStations[3] =
new TH2F(
"fMvdMCStation3",
"Mvd mc distribution", 8, -9.5, -1.5, 12, -1.5, 10.5);
89 fWordsPerRegion =
new TH1F(
"fWordsPerRegion",
"Words send to a region", 65, 0, 64);
94 new TH2F(
"fWordsPerRegion2",
"Words send to a region, errors sigma of gauss fit", 64, 0, 63, 150, 0, 15);
98 fWordsPerWorstRegion =
new TH1F(
"fWordsPerWorstRegion",
"Most worst send to a region per Event", 65, 0, 64);
102 fWordsPerSuperRegion =
new TH1F(
"fWordsPerSuperRegion",
"Words send to a super region", 1000, 0, 400);
106 fWorstSuperPerEvent =
new TH1F(
"fWorstSuperRegion",
"Most words send to super region per Event", 1000, 0, 400);
110 fMvdMCWorst =
new TH2F(
"fMvdMCWorst",
"Mvd mc distribution worst spot", 300, -2, 0, 1500, 3.5, 0);
115 new TH2F(
"fMvdMCWorstDelta",
"Mvd mc distribution worst spot only delta electrons", 300, -2, 0, 1500, 3.5, 0);
123 fMvdDataLoadHotSensor =
new TH1I(
"fMvdDataLoadHotSensor",
"Mvd Dataload in worst Sensor", 2000, 0, 2000);
127 fMvdBankDist =
new TH2I(
"fMvdBankDist",
"Avarage Hits per Region", 63, 0, 63, 50, 0, 50);
131 for (Int_t i = 0; i < 64; i++) {
132 fMvdDataPerRegion[i] =
new TH1F(Form(
"fMvdDataPerRegion[%d]", i), Form(
"Words send to region %d", i), 100, 0, 100);
138 for (Int_t i = 0; i < 16; i++) {
140 new TH1F(Form(
"fMvdDataPerSuperRegion[%d]", i), Form(
"Words send to superregion %d", i), 400, 0, 400);
153 Float_t wordsPerRegion[64] = {0};
154 Float_t wordsPerSuper[16] = {0};
156 Float_t yPosMin = -0.73;
157 Float_t yPosMax = 2.5;
159 for (Int_t k = 0; k <
fMcPoints->GetEntriesFast(); k++) {
163 if (curPoint->GetZ() < 8) {
164 if (curPoint->GetX() > -1.93 && curPoint->GetX() <= -0.55 && curPoint->GetY() >= yPosMin
165 && curPoint->GetY() <= yPosMax) {
166 fMvdMCWorst->Fill(curPoint->GetX(), curPoint->GetY());
167 if (curPoint->GetTrackID() == -3)
fMvdMCWorstDelta->Fill(curPoint->GetX(), curPoint->GetY());
168 for (Int_t nRegion = 0; nRegion < 64; nRegion++) {
169 if (curPoint->GetY() >= (yPosMin + (nRegion * 0.05))
170 && curPoint->GetY() < (yPosMin + ((nRegion + 1) * 0.05))) {
171 fMvdMCBank[nRegion]->Fill(curPoint->GetX(), curPoint->GetY());
172 wordsPerRegion[nRegion] = wordsPerRegion[nRegion] + 1.5;
173 if (wordsPerRegion[nRegion] > 100) LOG(info) <<
" Region " << nRegion <<
" has an overflow";
180 if (curPoint->GetZ() < 8) {
181 if (curPoint->GetX() < -0.5 && curPoint->GetY() > -0.5)
184 else if (curPoint->GetZ() < 13) {
185 if (curPoint->GetX() < -0.5 && curPoint->GetY() > -1.5)
188 else if (curPoint->GetZ() < 18) {
189 if (curPoint->GetX() < -1.5 && curPoint->GetY() > -1.5)
193 if (curPoint->GetX() < -1.5 && curPoint->GetY() > -1.5)
197 LOG(info) <<
"//--------------- New Event " <<
fEventNumber <<
" -----------------------\\";
200 Int_t wordsInWorst = 0;
201 Int_t wordsInWorstReg = 0;
202 Int_t wordsTotal = 0;
204 for (Int_t supReg = 0; supReg < 16; supReg++) {
205 for (Int_t k = 0; k < 4; k++) {
206 wordsPerSuper[supReg] += wordsPerRegion[i];
208 if (wordsPerRegion[i] > wordsInWorstReg) wordsInWorstReg = wordsPerRegion[i];
209 LOG(debug) <<
"Words in Region " << i <<
": " << wordsPerRegion[i];
213 LOG(debug) <<
" Words in super region " << supReg <<
": " << wordsPerSuper[supReg];
214 if (wordsPerSuper[supReg] > 400) LOG(info) <<
"SuperRegion " << supReg <<
" has an overflow";
218 if (wordsPerSuper[supReg] > wordsInWorst) wordsInWorst = wordsPerSuper[supReg];
220 wordsTotal += wordsPerSuper[supReg];
227 LOG(info) <<
"//--------------- End Event -----------------------\\";
253 for (Int_t iPad = 0; iPad < 4; iPad++) {
269 for (Int_t i = 0; i < 64; i++) {
272 Double_t param0 = func->GetParameter(0);
273 Double_t param1 = func->GetParameter(1);
274 Double_t param2 = func->GetParameter(2);
275 Double_t chi2 = func->GetChisquare();
276 LOG(info) <<
" // - " << i <<
" -- param 0 = " << param0 <<
" -- param 1 = " << param1 <<
" -- param 2 = " << param2
277 <<
" -- chi2 = " << chi2;
284 for (Int_t i = 0; i < 16; i++)
292 TCanvas* mcCanvas1 =
new TCanvas();
293 mcCanvas1->Divide(2, 2);
294 for (Int_t iPad = 0; iPad < 4; iPad++) {
295 mcCanvas1->cd(iPad + 1);
299 TCanvas* dataLoad =
new TCanvas();
300 dataLoad->Divide(2, 1);
306 TCanvas* mcCanvas2 =
new TCanvas();
307 mcCanvas2->Divide(1, 2);
335 TCanvas* regionCanvas =
new TCanvas();
336 regionCanvas->Divide(1, 2);
342 TCanvas* regionsCanvas[64];
343 TCanvas* supregionsCanvas[16];
345 for (Int_t i = 0; i < 64; i++) {
346 regionsCanvas[i] =
new TCanvas();
347 regionsCanvas[i]->cd();
351 for (Int_t i = 0; i < 16; i++) {
352 supregionsCanvas[i] =
new TCanvas();
353 supregionsCanvas[i]->cd();