]>
Commit | Line | Data |
---|---|---|
96624385 | 1 | // |
2 | // Calculate the qa in the forward regions event-by-event | |
3 | // | |
4 | #ifndef ALIFORWARDQATASK_H | |
5 | #define ALIFORWARDQATASK_H | |
6 | /** | |
7 | * @file AliForwardQATask.h | |
8 | * @author Christian Holm Christensen <cholm@dalsgaard.hehi.nbi.dk> | |
9 | * @date Wed Mar 23 14:06:42 2011 | |
10 | * | |
11 | * @brief | |
12 | * | |
13 | * | |
bd6f5206 | 14 | * @ingroup pwglf_forward_aod |
96624385 | 15 | */ |
c8b1a7db | 16 | #include "AliBaseESDTask.h" |
96624385 | 17 | #include "AliFMDEventInspector.h" |
18 | #include "AliFMDSharingFilter.h" | |
19 | #include "AliFMDDensityCalculator.h" | |
20 | #include "AliFMDEnergyFitter.h" | |
21 | #include <AliESDFMD.h> | |
96624385 | 22 | class AliESDEvent; |
23 | class TH2D; | |
96624385 | 24 | class TAxis; |
25 | ||
26 | /** | |
27 | * Calculate the QA in the forward regions | |
28 | * | |
29 | * @par Inputs: | |
30 | * - AliESDEvent | |
31 | * | |
32 | * @par Outputs: | |
33 | * - Histograms | |
34 | * | |
35 | * @par Histograms | |
36 | * | |
37 | * @par Corrections used | |
38 | * | |
bd6f5206 | 39 | * @ingroup pwglf_forward_tasks |
96624385 | 40 | * |
41 | */ | |
c8b1a7db | 42 | class AliForwardQATask : public AliBaseESDTask |
96624385 | 43 | { |
44 | public: | |
45 | /** | |
46 | * Constructor | |
47 | * | |
48 | * @param name Name of task | |
49 | */ | |
50 | AliForwardQATask(const char* name); | |
51 | /** | |
52 | * Constructor | |
53 | */ | |
54 | AliForwardQATask(); | |
55 | /** | |
c8b1a7db | 56 | * @{ |
57 | * @name Interface methods | |
96624385 | 58 | */ |
0b7de667 | 59 | /** |
60 | * Called when initialising the train. | |
61 | * | |
62 | * @return Always true | |
63 | */ | |
64 | virtual Bool_t Setup(); | |
96624385 | 65 | /** |
c8b1a7db | 66 | * Book output objects. Derived class should define this to book |
67 | * output objects on the processing output list @c fList before the | |
68 | * actual event processing. This is called on the master and on | |
69 | * each slave. | |
96624385 | 70 | * |
c8b1a7db | 71 | * If this member function returns false, the execution is stopped |
72 | * with a fatal signal. | |
73 | * | |
74 | * @return true on success. | |
96624385 | 75 | */ |
c8b1a7db | 76 | virtual Bool_t Book(); |
96624385 | 77 | /** |
c8b1a7db | 78 | * Called after reading in the first event. Here we can setup stuff |
79 | * depending on the conditions we're running under. | |
80 | * | |
81 | * @return true on success. If this returns false, then we turn the | |
82 | * task into a zombie and we do no more processing. | |
96624385 | 83 | */ |
c8b1a7db | 84 | virtual Bool_t PreData(const TAxis& vertex, const TAxis& eta); |
85 | ||
96624385 | 86 | /** |
c8b1a7db | 87 | * Called before processing a single event - should not do anything |
88 | * but clear data, etc. | |
96624385 | 89 | * |
c8b1a7db | 90 | * @return true on success |
96624385 | 91 | */ |
c8b1a7db | 92 | virtual Bool_t PreEvent(); |
96624385 | 93 | /** |
94 | * Process each event | |
95 | * | |
c8b1a7db | 96 | * @param esd Event |
97 | * | |
98 | * @return true on success | |
96624385 | 99 | */ |
c8b1a7db | 100 | virtual Bool_t Event(AliESDEvent& esd); |
96624385 | 101 | /** |
102 | * End of job | |
103 | * | |
c8b1a7db | 104 | * @return true on success |
96624385 | 105 | */ |
c8b1a7db | 106 | virtual Bool_t Finalize(); |
96624385 | 107 | /** |
108 | * @} | |
109 | */ | |
c8b1a7db | 110 | /** |
111 | * @{ | |
112 | * @name Default axes | |
113 | */ | |
114 | /** | |
115 | * Set the default eta axis to use in case we didn't get one from | |
116 | * the read-in corretions. Override this if the sub class should go | |
117 | * on even without a valid eta axis from the corrections (e.g. QA | |
118 | * task) | |
119 | * | |
120 | * @return null | |
121 | */ | |
122 | virtual TAxis* DefaultEtaAxis() const; | |
123 | /** | |
124 | * Set the default eta axis to use in case we didn't get one from | |
125 | * the read-in corretions. Override this if the sub class should go | |
126 | * on even without a valid eta axis from the corrections (e.g. QA | |
127 | * task) | |
128 | * | |
129 | * @return null | |
130 | */ | |
131 | virtual TAxis* DefaultVertexAxis() const; | |
132 | /* @} */ | |
96624385 | 133 | /** |
134 | * @{ | |
135 | * @name Access to sub-algorithms | |
136 | */ | |
137 | /** | |
138 | * Get reference to the EventInspector algorithm | |
139 | * | |
140 | * @return Reference to AliFMDEventInspector object | |
141 | */ | |
142 | AliFMDEventInspector& GetEventInspector() { return fEventInspector; } | |
143 | /** | |
144 | * Get reference to the EnergyFitter algorithm | |
145 | * | |
146 | * @return Reference to AliFMDEnergyFitter object | |
147 | */ | |
148 | AliFMDEnergyFitter& GetEnergyFitter() { return fEnergyFitter; } | |
149 | /** | |
150 | * Get reference to the SharingFilter algorithm | |
151 | * | |
152 | * @return Reference to AliFMDSharingFilter object | |
153 | */ | |
154 | AliFMDSharingFilter& GetSharingFilter() { return fSharingFilter; } | |
155 | /** | |
156 | * Get reference to the DensityCalculator algorithm | |
157 | * | |
158 | * @return Reference to AliFMDDensityCalculator object | |
159 | */ | |
160 | AliFMDDensityCalculator& GetDensityCalculator() { return fDensityCalculator; } | |
161 | /** | |
162 | * Get reference to the EventInspector algorithm | |
163 | * | |
164 | * @return Reference to AliFMDEventInspector object | |
165 | */ | |
166 | const AliFMDEventInspector& GetEventInspector() const { return fEventInspector; } | |
167 | /** | |
168 | * Get reference to the EnergyFitter algorithm | |
169 | * | |
170 | * @return Reference to AliFMDEnergyFitter object | |
171 | */ | |
172 | const AliFMDEnergyFitter& GetEnergyFitter() const { return fEnergyFitter; } | |
173 | /** | |
174 | * Get reference to the SharingFilter algorithm | |
175 | * | |
176 | * @return Reference to AliFMDSharingFilter object | |
177 | */ | |
178 | const AliFMDSharingFilter& GetSharingFilter() const { return fSharingFilter; } | |
179 | /** | |
180 | * Get reference to the DensityCalculator algorithm | |
181 | * | |
182 | * @return Reference to AliFMDDensityCalculator object | |
183 | */ | |
184 | const AliFMDDensityCalculator& GetDensityCalculator() const { return fDensityCalculator; } | |
185 | /** | |
186 | * @} | |
187 | */ | |
188 | /** | |
189 | * Set debug level | |
190 | * | |
191 | * @param dbg Debug level | |
192 | */ | |
193 | void SetDebug(Int_t dbg); | |
290052e7 | 194 | /** |
195 | * Print information | |
196 | * | |
197 | * @param option Not used | |
198 | */ | |
96624385 | 199 | void Print(Option_t* option="") const; |
200 | protected: | |
201 | /** | |
c8b1a7db | 202 | * Copy constructor |
96624385 | 203 | * |
c8b1a7db | 204 | * @param o Object to copy from |
205 | */ | |
206 | AliForwardQATask(const AliForwardQATask& o); | |
290052e7 | 207 | /** |
c8b1a7db | 208 | * Assignment operator |
290052e7 | 209 | * |
c8b1a7db | 210 | * @param o Object to assign from |
290052e7 | 211 | * |
c8b1a7db | 212 | * @return Reference to this object |
96624385 | 213 | */ |
c8b1a7db | 214 | AliForwardQATask& operator=(const AliForwardQATask& o); |
96624385 | 215 | |
c8b1a7db | 216 | Bool_t fEnableLowFlux;// Whether to use low-flux code |
217 | AliESDFMD fESDFMD; // Sharing corrected ESD object | |
218 | AliForwardUtil::Histos fHistos; // Cache histograms | |
96624385 | 219 | AliFMDEventInspector fEventInspector; // Algorithm |
220 | AliFMDEnergyFitter fEnergyFitter; // Algorithm | |
221 | AliFMDSharingFilter fSharingFilter; // Algorithm | |
222 | AliFMDDensityCalculator fDensityCalculator; // Algorithm | |
223 | ||
c8b1a7db | 224 | ClassDef(AliForwardQATask,3) // Forward QA class |
96624385 | 225 | }; |
226 | ||
227 | #endif | |
228 | // Local Variables: | |
229 | // mode: C++ | |
230 | // End: | |
231 |