diff --git a/sim/detectors/much/qa/CbmMuchDigitizerQa.cxx b/sim/detectors/much/qa/CbmMuchDigitizerQa.cxx index 3215a4f4b6da210c63582b8ee31452163b1b9274..69fa3bcc08c4debcc862a16454b9c237665bb1c7 100644 --- a/sim/detectors/much/qa/CbmMuchDigitizerQa.cxx +++ b/sim/detectors/much/qa/CbmMuchDigitizerQa.cxx @@ -120,7 +120,6 @@ InitStatus CbmMuchDigitizerQa::Init() { printf("Init: fNstations = %i\n", fNstations); //fVerbose = 3; - InitCounters(); InitCanvases(); InitChargeHistos(); InitLengthHistos(); @@ -133,32 +132,6 @@ InitStatus CbmMuchDigitizerQa::Init() { return kSUCCESS; } -void CbmMuchDigitizerQa::InitCounters() { - - fNall = new Int_t[fNstations]; - fNpr = new Int_t[fNstations]; - fNpi = new Int_t[fNstations]; - fNel = new Int_t[fNstations]; - fNmu = new Int_t[fNstations]; - fNka = new Int_t[fNstations]; - fNprimary = new Int_t[fNstations]; - fNsecondary = new Int_t[fNstations]; - - for (Int_t i = 0; i < fNstations; i++) { - fNall[i] = 0; - fNpr[i] = 0; - fNpi[i] = 0; - fNel[i] = 0; - fNmu[i] = 0; - fNka[i] = 0; - fNprimary[i] = 0; - fNsecondary[i] = 0; - } - fPointsTotal = 0; - fPointsUnderCounted = 0; - fPointsOverCounted = 0; -} - void CbmMuchDigitizerQa::InitChannelPadInfo() { fPadMinLx = std::numeric_limits<Double_t>::max(); @@ -672,7 +645,6 @@ void CbmMuchDigitizerQa::FinishTask() { if (fVerbose > 1) { OutputNvsS(); - PrintCounters(); } FairSink* sink = FairRootManager::Instance()->GetSink(); sink->WriteObject(&fOutFolder, nullptr); @@ -715,50 +687,6 @@ void CbmMuchDigitizerQa::OutputNvsS() { fOutFolder.Add(c); } -void CbmMuchDigitizerQa::PrintCounters() { - - printf("All tracks: ;"); - for (Int_t i = 0; i < fNstations; i++) - printf("%8i;", fNall[i]); - printf("\n"); - printf("------------;"); - for (Int_t i = 0; i < fNstations; i++) - printf("---------"); - printf("\n"); - printf("Primary: ;"); - for (Int_t i = 0; i < fNstations; i++) - printf("%8i;", fNprimary[i]); - printf("\n"); - printf("Secondary: ;"); - for (Int_t i = 0; i < fNstations; i++) - printf("%8i;", fNsecondary[i]); - printf("\n"); - printf("-------------"); - for (Int_t i = 0; i < fNstations; i++) - printf("---------"); - printf("\n"); - printf("Protons: ;"); - for (Int_t i = 0; i < fNstations; i++) - printf("%8i;", fNpr[i]); - printf("\n"); - printf("Pions: ;"); - for (Int_t i = 0; i < fNstations; i++) - printf("%8i;", fNpi[i]); - printf("\n"); - printf("Electrons: ;"); - for (Int_t i = 0; i < fNstations; i++) - printf("%8i;", fNel[i]); - printf("\n"); - printf("Muons: ;"); - for (Int_t i = 0; i < fNstations; i++) - printf("%8i;", fNmu[i]); - printf("\n"); - printf("Kaons: ;"); - for (Int_t i = 0; i < fNstations; i++) - printf("%8i;", fNka[i]); - printf("\n"); -} - // ------------------------------------------------------------------------- Double_t CbmMuchDigitizerQa::LandauMPV(Double_t* lg_x, Double_t* par) { Double_t gaz_gain_mean = 1.7e+4; @@ -803,10 +731,6 @@ void CbmMuchDigitizerQa::DigitizerQa() { continue; } - if (CbmMuchAddress::GetLayerIndex(point->GetDetectorID()) == 0) { - UpdateParticleCounters(stId, pdgCode, motherId); - } - Double_t mass = particle->Mass(); point->PositionIn(vIn); point->PositionOut(vOut); @@ -826,28 +750,6 @@ void CbmMuchDigitizerQa::DigitizerQa() { } // ------------------------------------------------------------------------- -void CbmMuchDigitizerQa::UpdateParticleCounters(Int_t stId, - Int_t pdgCode, - Int_t motherId) { - - fNall[stId]++; - if (pdgCode == 2212) - fNpr[stId]++; - else if (pdgCode == -211 || pdgCode == 211) - fNpi[stId]++; - else if (pdgCode == -11 || pdgCode == 11) - fNel[stId]++; - else if (pdgCode == -13 || pdgCode == 13) - fNmu[stId]++; - else if (pdgCode == -321 || pdgCode == 321) - fNka[stId]++; - - if (motherId == -1) - fNprimary[stId]++; - else - fNsecondary[stId]++; -} - void CbmMuchDigitizerQa::FillChargePerPoint() { for (Int_t i = 0; i < fDigiManager->GetNofDigis(ECbmModuleId::kMuch); i++) { CbmMuchDigi* digi = (CbmMuchDigi*) fDigiManager->Get<CbmMuchDigi>(i); diff --git a/sim/detectors/much/qa/CbmMuchDigitizerQa.h b/sim/detectors/much/qa/CbmMuchDigitizerQa.h index 7349ead879e8b58dc09ae03dbfe940b46288289c..5d2e00ba5f438e177ce6e94d650a2739b84c11b1 100644 --- a/sim/detectors/much/qa/CbmMuchDigitizerQa.h +++ b/sim/detectors/much/qa/CbmMuchDigitizerQa.h @@ -65,7 +65,6 @@ private: CbmMuchDigitizerQa& operator=(const CbmMuchDigitizerQa&); TFolder* histFolder; - void InitCounters(); void InitCanvases(); void InitChargeHistos(); void InitLengthHistos(); @@ -76,10 +75,8 @@ private: void FillTotalPadsHistos(); void DrawCanvases(); - void PrintCounters(); void OutputNvsS(); - void UpdateParticleCounters(Int_t stId, Int_t pdgCode, Int_t motherId); void FillChargePerPoint(); void FillDigitizerPerformancePlots(); @@ -150,20 +147,6 @@ private: Int_t fnPadSizesX = 0; Int_t fnPadSizesY = 0; - Int_t* fNall = nullptr; // number of all tracks at the first station - Int_t* fNpr = nullptr; // number of protons at the first station - Int_t* fNpi = nullptr; // number of pions at the first station - Int_t* fNel = nullptr; // number of electrons at the first station - Int_t* fNmu = nullptr; // number of muons at the first station - Int_t* fNka = nullptr; // number of kaons at the first station - Int_t* fNprimary = nullptr; // number of primary tracks at the first station - Int_t* fNsecondary = - nullptr; // number of secondary tracks at the first station - - Int_t fPointsTotal = 0; - Int_t fPointsUnderCounted = 0; - Int_t fPointsOverCounted = 0; - Double_t fPadMinLx = 0.; Double_t fPadMinLy = 0.; Double_t fPadMaxLx = 0.;