CbmRoot
Loading...
Searching...
No Matches
CbmRichRecoTbQa.h
Go to the documentation of this file.
1/* Copyright (C) 2018-2020 GSI/JINR-LIT, Darmstadt/Dubna
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Andrey Lebedev [committer] */
4
5#ifndef CBM_RICH_RECO_TB_QA
6#define CBM_RICH_RECO_TB_QA
7
8#include "FairTask.h"
10class TClonesArray;
11class CbmHistManager;
12class CbmRichPoint;
13class CbmMCTrack;
14class CbmMCEventList;
15class CbmDigiManager;
16class CbmLink;
17
18#include <map>
19#include <vector>
20
21using namespace std;
22
23class CbmRichRecoTbQa : public FairTask {
24
25 public:
30
34 virtual ~CbmRichRecoTbQa() {}
35
39 virtual InitStatus Init();
40
44 virtual void Exec(Option_t* option);
45
49 virtual void Finish();
50
51
56 void SetOutputDir(const string& dir) { fOutputDir = dir; }
57
61 void DrawFromFile(const string& fileName, const string& outputDir);
62
63 private:
67 void InitHistograms();
68
69 void DrawHist();
70
71 void Process();
72
73 void ProcessMc();
74
75 void RingRecoEfficiency();
76
77 Int_t GetNofPrimaryMcTracks(Int_t iEv);
78
79 Bool_t IsCherenkovPhoton(const CbmRichPoint* point, Int_t fileId, Int_t eventId);
80
81 Bool_t IsCherenkovPhotonFromPrimaryElectron(const CbmRichPoint* point, Int_t fileId, Int_t eventId);
82
83 Bool_t IsCherenkovPhotonFromSecondaryElectron(const CbmRichPoint* point, Int_t fileId, Int_t eventId);
84
85 Bool_t IsMcPrimaryElectron(const CbmMCTrack* mctrack);
86
87 Bool_t IsCherenkovPhotonFromPion(const CbmRichPoint* point, Int_t fileId, Int_t eventId);
88
89 Bool_t IsMcPion(const CbmMCTrack* mctrack);
90
91 void DrawTimeLog(const string& hMainName, Int_t nofLogEvents, bool withNoise = false);
92
97
102
103
105
107
109 string fOutputDir; // output dir for results
110
115 TClonesArray* fRichHits;
116 TClonesArray* fRichRings;
117 TClonesArray* fRichRingMatches;
119
120 vector<CbmLink> fRecRings;
121
122 ClassDef(CbmRichRecoTbQa, 1)
123};
124
125#endif
CbmDigiManager.
Histogram manager.
Access to a MC data branch for time-based analysis.
Container class for MC events with number, file and start time.
Bool_t IsCherenkovPhotonFromPrimaryElectron(const CbmRichPoint *point, Int_t fileId, Int_t eventId)
virtual ~CbmRichRecoTbQa()
Standard destructor.
void SetOutputDir(const string &dir)
Set output directory where you want to write results (figures and json).
Bool_t IsMcPrimaryElectron(const CbmMCTrack *mctrack)
CbmRichRecoTbQa(const CbmRichRecoTbQa &)
Copy constructor.
TClonesArray * fRichRings
TClonesArray * fRichRingMatches
CbmMCDataArray * fStsPoints
void InitHistograms()
Initialize histograms.
virtual InitStatus Init()
Inherited from FairTask.
CbmRichRecoTbQa & operator=(const CbmRichRecoTbQa &)
Assignment operator.
CbmMCDataArray * fRichPoints
void DrawTimeLog(const string &hMainName, Int_t nofLogEvents, bool withNoise=false)
Int_t GetNofPrimaryMcTracks(Int_t iEv)
Bool_t IsCherenkovPhoton(const CbmRichPoint *point, Int_t fileId, Int_t eventId)
CbmRichRecoTbQa()
Standard constructor.
virtual void Exec(Option_t *option)
Inherited from FairTask.
CbmHistManager * fHM
Bool_t IsCherenkovPhotonFromPion(const CbmRichPoint *point, Int_t fileId, Int_t eventId)
TClonesArray * fRichHits
CbmDigiManager * fDigiMan
CbmMCDataArray * fMCTracks
vector< CbmLink > fRecRings
Bool_t IsCherenkovPhotonFromSecondaryElectron(const CbmRichPoint *point, Int_t fileId, Int_t eventId)
CbmMCEventList * fEventList
Bool_t IsMcPion(const CbmMCTrack *mctrack)
virtual void Finish()
Inherited from FairTask.
void DrawFromFile(const string &fileName, const string &outputDir)
Draw histogram from file.
Hash for CbmL1LinkKey.