CbmRoot
Loading...
Searching...
No Matches
CbmTofGeometryQa.h
Go to the documentation of this file.
1/* Copyright (C) 2015-2017 Facility for Antiproton and Ion Research in Europe, Darmstadt
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Pierre-Alain Loizeau [committer] */
4
15#ifndef _CbmTofGeometryQa_H_
16#define _CbmTofGeometryQa_H_
17
18#include "FairTask.h"
19
20class FairMCEventHeader;
22class CbmTofCell;
23// Geometry
26class CbmTofCell;
27
28class CbmTofDigiPar;
30
31class TClonesArray;
32class TH1;
33class TH2;
34class TH3;
35class TProfile2D;
36class TString;
37
38class CbmTofGeometryQa : public FairTask {
39
40public:
42 CbmTofGeometryQa(const char* name, Int_t verbose = 1);
43 virtual ~CbmTofGeometryQa();
44
45 virtual InitStatus Init();
46 virtual void Exec(Option_t* option);
47 virtual void Finish();
48
52 virtual void SetParContainers();
53
54 Bool_t RegisterInputs();
55
56 Bool_t SetHistoFileName(TString sFilenameIn);
57
58 Bool_t SetWallPosZ(Double_t dWallPosCm = 1000);
59
60 void SetCentralityDepFlag(Bool_t bFlag = kTRUE) { fbCentDepOn = bFlag; }
61 void SetSphereApproxCheckFlag(Bool_t bFlag = kTRUE) { fbSphAppOn = bFlag; }
62
63private:
64 Bool_t CreateHistos();
65 Bool_t FillHistos();
68 Bool_t WriteHistos();
69 Bool_t DeleteHistos();
70
74 Bool_t LoadGeometry();
75
78
79 Int_t fEvents; // Number of processed events
80
81 // Geometry infos
85 Int_t iNbSmTot;
86 std::vector<Int_t> fvTypeSmOffs; // Offset in SM index for first SM of each SM type
87 Int_t iNbRpcTot;
88 std::vector<std::vector<Int_t>> fvSmRpcOffs; // Offset in RPC index for first RPC of each SM
89 Int_t fiNbChTot;
90 std::vector<std::vector<std::vector<Int_t>>> fvRpcChOffs; // Offset in channel index for first channel of each RPC
91
92 // Parameters
93
94 // Data IO
95 FairMCEventHeader* fMCEventHeader; // MC event header
96 // TClonesArray * fStsPointsColl; // STS MC points
97 TClonesArray* fTofPointsColl; // TOF MC points
98 TClonesArray* fMcTracksColl; // MC tracks
99 TClonesArray* fRealTofPointsColl; // Realistics TOF MC points
100 TClonesArray* fRealTofMatchColl; // Index of Realistics TOF MC points for each MC Point (CbmMatch)
102
103 // Histograms
104 // Output file name and path
106 // Position of the TOF wall on Z axis for centering histos with Z
107 Double_t fdWallPosZ;
108 // Geometric Mapping
109 Bool_t fbCentDepOn; // Switch on study of dependence on centrality
110 std::vector<TH2*> fvhTrackAllStartZCent; // Dependence of Track origin on centrality, if TOF points
111 std::vector<TH2*> fvhTrackSecStartZCent; // Dependence of Track origin on centrality, if TOF points
112 std::vector<TH3*> fvhTrackAllStartXZCent; // Dependence of Track origin on centrality, if TOF points
113 std::vector<TH3*> fvhTofPntAllAngCent; // Dependence of Tof Point position (angular) on centrality
114 std::vector<TH2*> fvhTrackAllStartXZ; // Track origin mapping, if TOF points
115 std::vector<TH2*> fvhTrackAllStartYZ; // Track origin mapping, if TOF points
116 TH2* fhTrackMapXY; // Only when creating normalization histos
117 TH2* fhTrackMapXZ; // Only when creating normalization histos
118 TH2* fhTrackMapYZ; // Only when creating normalization histos
119 TH2* fhTrackMapAng; // Only when creating normalization histos
120 TH2* fhTrackMapSph; // Only when creating normalization histos
121 TH2* fhTrackMapAngPrimAll; // For angular acceptance study
122 TH2* fhTrackMapAngPrimSts; // For angular acceptance study
123 TH2* fhTrackMapAngPrimRich; // For angular acceptance study
124 TH2* fhTrackMapAngPrimMuch; // For angular acceptance study
125 TH2* fhTrackMapAngPrimTrd; // For angular acceptance study
126 TH2* fhTrackMapAngPrimTof; // For angular acceptance study
127 /*
128 TH2 * fhTrackMapAngSecAll; // For angular acceptance study
129 TH2 * fhTrackMapAngSecSts; // For angular acceptance study
130 TH2 * fhTrackMapAngSecRich; // For angular acceptance study
131 TH2 * fhTrackMapAngSecMuch; // For angular acceptance study
132 TH2 * fhTrackMapAngSecTrd; // For angular acceptance study
133 TH2 * fhTrackMapAngSecTof; // For angular acceptance study
134*/
145 TH2* fhPointMapAngWithSts; // For angular acceptance study
146 TH2* fhPointMapAngWithRich; // For angular acceptance study
147 TH2* fhPointMapAngWithMuch; // For angular acceptance study
148 TH2* fhPointMapAngWithTrd; // For angular acceptance study
149
150 // Errors relative to spherical approx
162
163 // Physics coord mapping, 1 per particle type
164 // Phase space
165 // Primary tracks
166 std::vector<TH2*> fvhPtmRapGenTrk;
167 std::vector<TH2*> fvhPtmRapStsPnt;
168 std::vector<TH2*> fvhPtmRapTofPnt;
169 // Secondary tracks
170 std::vector<TH2*> fvhPtmRapSecGenTrk;
171 std::vector<TH2*> fvhPtmRapSecStsPnt;
172 std::vector<TH2*> fvhPtmRapSecTofPnt;
173
174 // PLab
175 // Primary tracks
176 std::vector<TH1*> fvhPlabGenTrk;
177 std::vector<TH1*> fvhPlabStsPnt;
178 std::vector<TH1*> fvhPlabTofPnt;
179 // Secondary tracks
180 std::vector<TH1*> fvhPlabSecGenTrk;
181 std::vector<TH1*> fvhPlabSecStsPnt;
182 std::vector<TH1*> fvhPlabSecTofPnt;
183
184 // MC Tracks losses
185 // Primary tracks
186 std::vector<TH2*> fvhPtmRapGenTrkTofPnt;
187 std::vector<TH1*> fvhPlabGenTrkTofPnt;
188 std::vector<TH1*> fvhPlabStsTrkTofPnt;
189 // Secondary tracks
190 std::vector<TH2*> fvhPtmRapSecGenTrkTofPnt;
191 std::vector<TH1*> fvhPlabSecGenTrkTofPnt;
192 std::vector<TH1*> fvhPlabSecStsTrkTofPnt;
193
195};
196
197#endif
Parameters class for the CBM ToF digitizer using beam data distributions.
QA class for the TOF event based Hit finder tasks (clusterizers, ...)
CbmTofGeometryQa(const CbmTofGeometryQa &)
std::vector< TH2 * > fvhTrackSecStartZCent
std::vector< TH2 * > fvhPtmRapSecGenTrk
std::vector< TH1 * > fvhPlabStsTrkTofPnt
TProfile2D * fhPointSphAprZposErrMapXZ
std::vector< TH2 * > fvhPtmRapSecStsPnt
std::vector< TH1 * > fvhPlabSecStsPnt
std::vector< TH2 * > fvhPtmRapStsPnt
std::vector< TH1 * > fvhPlabTofPnt
TProfile2D * fhPointSphAprRadiusErrMapAng
TClonesArray * fMcTracksColl
std::vector< TH1 * > fvhPlabSecStsTrkTofPnt
TProfile2D * fhPointSphAprZposErrMapXY
std::vector< TH3 * > fvhTofPntAllAngCent
Bool_t LoadGeometry()
Load the geometry: for now just resizing the Digis temporary vectors.
TProfile2D * fhPointSphAprRadiusErrMapXZ
std::vector< TH2 * > fvhPtmRapSecGenTrkTofPnt
TClonesArray * fRealTofMatchColl
TProfile2D * fhPointSphAprZposErrMapSph
std::vector< TH1 * > fvhPlabSecGenTrk
std::vector< TH2 * > fvhTrackAllStartYZ
std::vector< Int_t > fvTypeSmOffs
std::vector< TH2 * > fvhPtmRapGenTrkTofPnt
CbmTofDetectorId * fTofId
Bool_t SetHistoFileName(TString sFilenameIn)
std::vector< TH1 * > fvhPlabGenTrkTofPnt
virtual void Finish()
std::vector< TH2 * > fvhPtmRapSecTofPnt
std::vector< TH2 * > fvhTrackAllStartXZ
std::vector< TH2 * > fvhTrackAllStartZCent
virtual void Exec(Option_t *option)
TProfile2D * fhPointSphAprZposErrMapYZ
FairMCEventHeader * fMCEventHeader
Bool_t NormalizeNormHistos()
std::vector< TH1 * > fvhPlabStsPnt
virtual void SetParContainers()
Inherited from FairTask.
Bool_t NormalizeMapHistos()
CbmTofGeoHandler * fGeoHandler
TProfile2D * fhPointSphAprRadiusErrMapYZ
CbmTofGeometryQa operator=(const CbmTofGeometryQa &)
virtual InitStatus Init()
std::vector< TH2 * > fvhPtmRapGenTrk
TClonesArray * fRealTofPointsColl
TProfile2D * fhPointSphAprZposErrMapAng
TClonesArray * fTofPointsColl
void SetCentralityDepFlag(Bool_t bFlag=kTRUE)
std::vector< std::vector< Int_t > > fvSmRpcOffs
std::vector< std::vector< std::vector< Int_t > > > fvRpcChOffs
CbmTofCell * fChannelInfo
void SetSphereApproxCheckFlag(Bool_t bFlag=kTRUE)
std::vector< TH3 * > fvhTrackAllStartXZCent
Bool_t SetWallPosZ(Double_t dWallPosCm=1000)
std::vector< TH1 * > fvhPlabSecGenTrkTofPnt
std::vector< TH1 * > fvhPlabGenTrk
TProfile2D * fhPointSphAprRadiusErrMapSph
TProfile2D * fhPointSphAprRadiusErrMapXY
std::vector< TH1 * > fvhPlabSecTofPnt
std::vector< TH2 * > fvhPtmRapTofPnt
ClassDef(CbmTofGeometryQa, 1)