]>
Commit | Line | Data |
---|---|---|
7984e5f7 | 1 | // Histogram and fit the energy loss distributions for the FMD |
2 | // | |
3 | // Wraps AliFMDEnergyFitter | |
4 | #ifndef ALIFMDENERGYFITTERTASK_H | |
5 | #define ALIFMDENERGYFITTERTASK_H | |
ffca499d | 6 | /** |
7 | * @file AliFMDEnergyFitterTask.h | |
8 | * @author Christian Holm Christensen <cholm@dalsgaard.hehi.nbi.dk> | |
9 | * @date Wed Mar 23 14:02:39 2011 | |
10 | * | |
11 | * @brief | |
12 | * | |
bd6f5206 | 13 | * @ingroup pwglf_forward_eloss |
ffca499d | 14 | * |
15 | */ | |
c8b1a7db | 16 | #include "AliBaseESDTask.h" |
0bd4b00f | 17 | #include "AliFMDEventInspector.h" |
18 | #include "AliFMDEnergyFitter.h" | |
0bd4b00f | 19 | class AliESDEvent; |
20 | class TH2D; | |
21 | class TList; | |
22 | class TTree; | |
23 | ||
24 | ||
0bd4b00f | 25 | /** |
26 | * Histogram and fit the energy loss distributions for the FMD | |
27 | * | |
28 | * @par Inputs: | |
29 | * - AliESDEvent | |
30 | * | |
31 | * @par Outputs: | |
32 | * - None | |
33 | * | |
34 | * @par Histograms | |
35 | * | |
36 | * @par Corrections used | |
37 | * - None | |
38 | * | |
bd6f5206 | 39 | * @ingroup pwglf_forward_tasks |
40 | * @ingroup pwglf_forward_eloss | |
0bd4b00f | 41 | * |
42 | */ | |
c8b1a7db | 43 | class AliFMDEnergyFitterTask : public AliBaseESDTask |
0bd4b00f | 44 | { |
45 | public: | |
46 | /** | |
47 | * Constructor | |
48 | * | |
49 | * @param name Name of task | |
50 | */ | |
51 | AliFMDEnergyFitterTask(const char* name); | |
52 | /** | |
53 | * Constructor | |
54 | */ | |
55 | AliFMDEnergyFitterTask(); | |
0bd4b00f | 56 | /** |
57 | * @{ | |
58 | * @name Interface methods | |
59 | */ | |
0b7de667 | 60 | /** |
61 | * Called on master when setting up the train. | |
62 | * | |
63 | * @return Always true | |
64 | */ | |
65 | virtual Bool_t Setup(); | |
0bd4b00f | 66 | /** |
c8b1a7db | 67 | * Book output objects. Derived class should define this to book |
68 | * output objects on the processing output list @c fList before the | |
69 | * actual event processing. This is called on the master and on | |
70 | * each slave. | |
0bd4b00f | 71 | * |
c8b1a7db | 72 | * If this member function returns false, the execution is stopped |
73 | * with a fatal signal. | |
74 | * | |
75 | * @return true on success. | |
0bd4b00f | 76 | */ |
c8b1a7db | 77 | virtual Bool_t Book(); |
0bd4b00f | 78 | /** |
c8b1a7db | 79 | * Called after reading in the first event. Here we can setup stuff |
80 | * depending on the conditions we're running under. | |
0bd4b00f | 81 | * |
c8b1a7db | 82 | * @return true on success. If this returns false, then we turn the |
83 | * task into a zombie and we do no more processing. | |
0bd4b00f | 84 | */ |
c8b1a7db | 85 | virtual Bool_t PreData(const TAxis& vertex, const TAxis& eta); |
0bd4b00f | 86 | /** |
87 | * Process each event | |
88 | * | |
c8b1a7db | 89 | * @param esd Event to analyse |
90 | * @return true on success | |
0bd4b00f | 91 | */ |
c8b1a7db | 92 | virtual Bool_t Event(AliESDEvent& esd); |
0bd4b00f | 93 | /** |
94 | * End of job | |
95 | * | |
c8b1a7db | 96 | * @return true on success |
db298fc6 | 97 | */ |
c8b1a7db | 98 | virtual Bool_t Finalize(); |
0bd4b00f | 99 | /** |
100 | * @} | |
101 | */ | |
102 | /** | |
103 | * Print information | |
104 | * | |
105 | * @param option Not used | |
106 | */ | |
107 | void Print(Option_t* option="") const; | |
108 | /** | |
109 | * @{ | |
110 | * @name Access to sub-algorithms | |
111 | */ | |
112 | /** | |
113 | * Get reference to the EventInspector algorithm | |
114 | * | |
115 | * @return Reference to AliFMDEventInspector object | |
116 | */ | |
117 | AliFMDEventInspector& GetEventInspector() { return fEventInspector; } | |
c8b1a7db | 118 | /** |
119 | * Get reference to the EventInspector algorithm | |
120 | * | |
121 | * @return Reference to AliFMDEventInspector object | |
122 | */ | |
123 | const AliFMDEventInspector& GetEventInspector() const{return fEventInspector;} | |
0bd4b00f | 124 | /** |
125 | * Get reference to the EnergyFitter algorithm | |
126 | * | |
127 | * @return Reference to AliFMDEnergyFitter object | |
128 | */ | |
129 | AliFMDEnergyFitter& GetEnergyFitter() { return fEnergyFitter; } | |
130 | /** | |
131 | * @} | |
132 | */ | |
c8b1a7db | 133 | /** |
134 | * @{ | |
135 | * @name Settings | |
136 | */ | |
7984e5f7 | 137 | /** |
138 | * Set the debug level | |
139 | * | |
140 | * @param dbg Debug level | |
141 | */ | |
0bd4b00f | 142 | void SetDebug(Int_t dbg); |
290052e7 | 143 | /** |
a03f01f7 | 144 | * Set whether to only look at MB (INEL) data, so as to avoid |
145 | * bias from different trigger scalars. | |
290052e7 | 146 | * |
a03f01f7 | 147 | * @param onlyMB if true, only analyse MB events |
290052e7 | 148 | */ |
a03f01f7 | 149 | void SetOnlyMB(Bool_t onlyMB) { fOnlyMB = onlyMB; } |
c8b1a7db | 150 | /* @} */ |
151 | /** | |
152 | * @{ | |
153 | * @name Default axes | |
154 | */ | |
155 | /** | |
156 | * Set the default eta axis to use in case we didn't get one from | |
157 | * the read-in corretions. Override this if the sub class should go | |
158 | * on even without a valid eta axis from the corrections (e.g. QA | |
159 | * task) | |
160 | * | |
161 | * @return null | |
162 | */ | |
163 | virtual TAxis* DefaultEtaAxis() const; | |
164 | /** | |
165 | * Set the default eta axis to use in case we didn't get one from | |
166 | * the read-in corretions. Override this if the sub class should go | |
167 | * on even without a valid eta axis from the corrections (e.g. QA | |
168 | * task) | |
169 | * | |
170 | * @return null | |
171 | */ | |
172 | virtual TAxis* DefaultVertexAxis() const; | |
173 | /* @} */ | |
0bd4b00f | 174 | protected: |
175 | /** | |
c8b1a7db | 176 | * Copy constructor |
0bd4b00f | 177 | * |
c8b1a7db | 178 | * @param o Object to copy from |
0bd4b00f | 179 | */ |
c8b1a7db | 180 | AliFMDEnergyFitterTask(const AliFMDEnergyFitterTask& o); |
181 | /** | |
182 | * Assignment operator | |
183 | * | |
184 | * @param o Object to assign from | |
185 | * | |
186 | * @return Reference to this object | |
187 | */ | |
188 | AliFMDEnergyFitterTask& operator=(const AliFMDEnergyFitterTask& o); | |
0bd4b00f | 189 | |
0bd4b00f | 190 | AliFMDEventInspector fEventInspector; // Algorithm |
191 | AliFMDEnergyFitter fEnergyFitter; // Algorithm | |
a03f01f7 | 192 | Bool_t fOnlyMB; // Only MB flag |
193 | ||
194 | ClassDef(AliFMDEnergyFitterTask,4) // Forward multiplicity class | |
0bd4b00f | 195 | }; |
196 | ||
197 | #endif | |
198 | // Local Variables: | |
199 | // mode: C++ | |
200 | // End: | |
201 |