File indexing completed on 2025-01-18 10:18:20
0001
0002
0003 void multi_eval(const char *dfname, const char *cfname = 0)
0004 {
0005 auto *reco = new ReconstructionFactory(dfname, cfname, "pfRICH");
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016 auto *a1 = reco->UseRadiator("BelleIIAerogel1");
0017
0018
0019 reco->AddHypothesis("pi+");
0020 reco->AddHypothesis(321);
0021
0022
0023 reco->AddBlackoutRadiator("QuartzWindow");
0024 reco->AddBlackoutRadiator("Acrylic");
0025 reco->AddBlackoutRadiator("GasVolume");
0026
0027 reco->SetBlackoutBlowupValue(3);
0028
0029 auto hmatch = new TH1D("hmatch", "PID evaluation correctness", 2, 0, 2);
0030 auto hthtr1 = new TH1D("thtr1", "Cherenkov angle (track)", 200, 220, 320);
0031
0032
0033
0034 reco->UseAutomaticCalibration();
0035
0036 reco->PerformCalibration(200);
0037 {
0038 CherenkovEvent *event;
0039
0040
0041 while((event = reco->GetNextEvent())) {
0042 for(auto mcparticle: event->ChargedParticles()) {
0043 if (!mcparticle->IsPrimary()) continue;
0044
0045 if (mcparticle->GetPDG() == mcparticle->GetRecoPdgCode()) {
0046 hmatch->Fill(0.5);
0047 } else {
0048 hmatch->Fill(1.5);
0049 }
0050
0051 hthtr1->Fill(1000*mcparticle->GetRecoCherenkovAverageTheta(a1));
0052
0053 }
0054 }
0055 }
0056
0057 auto cv = new TCanvas("cv", "", 1600, 1000);
0058 cv->Divide(4, 3);
0059 cv->cd(1); reco->hthph()->Fit("gaus");
0060 cv->cd(2); reco->hccdfph()->SetMinimum(0); reco->hccdfph()->Draw();
0061 cv->cd(3); reco->hccdftr()->SetMinimum(0); reco->hccdftr()->Draw();
0062 cv->cd(4); reco->hccdfev()->SetMinimum(0); reco->hccdfev()->Draw();
0063 cv->cd(5); reco->hnpetr()->Draw();
0064 cv->cd(6); reco->hmatch()->SetMinimum(0); reco->hmatch()->Draw();
0065 cv->cd(7); hmatch ->SetMinimum(0); hmatch ->Draw();
0066 cv->cd(8); reco->hdtph()->Fit("gaus");
0067 cv->cd(9); hthtr1->Fit("gaus");
0068
0069 cv->cd(10); reco->hwl()->Draw();
0070 cv->cd(11); reco->hvtx()->Draw();
0071 cv->cd(12); reco->hri()->Draw();
0072 }