- cleaning up debug output
[u/mrichter/AliRoot.git] / HLT / CALO / AliHLTCaloClusterAnalyser.h
CommitLineData
ea367f6a 1//-*- Mode: C++ -*-
2// $Id: AliHLTCaloClusterAnalyser.h 35107 2009-09-30 01:45:06Z phille $
3
4 /**************************************************************************
5 * This file is property of and copyright by the ALICE HLT Project *
6 * All rights reserved. *
7 * *
8 * Primary Authors: Oystein Djuvsland *
9 * *
10 * Permission to use, copy, modify and distribute this software and its *
11 * documentation strictly for non-commercial purposes is hereby granted *
12 * without fee, provided that the above copyright notice appears in all *
13 * copies and that both the copyright notice and this permission notice *
14 * appear in the supporting documentation. The authors make no claims *
15 * about the suitability of this software for any purpose. It is *
16 * provided "as is" without express or implied warranty. *
17 **************************************************************************/
18
19#ifndef ALIHLTCALOCLUSTERANALYSER_H
20#define ALIHLTCALOCLUSTERANALYSER_H
21
7c80a370 22#include "AliHLTLogging.h"
ea367f6a 23
24/**
25 * Class calculates properties of rec points
26 *
27 * @file AliHLTCaloClusterAnalyser.h
28 * @author Oystein Djuvsland
29 * @date
30 * @brief Cluster analyser for CALO HLT
31 */
32
33// see header file for class documentation
34// or
35// refer to README to build package
36// or
37// visit http://web.ift.uib.no/~kjeks/doc/alice-hlt
38
39//#include "AliHLTCaloBase.h"
40
41//class AliHLTCaloPhysicsAnalyzer;
42class AliHLTCaloRecPointHeaderStruct;
43class AliHLTCaloRecPointDataStruct;
7c80a370 44class AliHLTCaloDigitDataStruct;
ea367f6a 45class AliHLTCaloClusterHeaderStruct;
46class AliHLTCaloClusterDataStruct;
7c80a370 47class AliHLTCaloGeometry;
ea367f6a 48
73d6f579 49class TH1F; //DEBUG
50
51
ea367f6a 52/**
53 * @class AliHLTCaloClusterAnalyser
54 * ClusterAnalyser for CALO HLT. Algorithms for center of gravity
55 * and moment calculations are based on classes from the CALO
56 * offline analysis directory
57 *
58 * @ingroup alihlt_calo
59 */
60//class AliHLTCaloClusterAnalyser : public AliHLTCaloBase
7c80a370 61class AliHLTCaloClusterAnalyser : public AliHLTLogging
ea367f6a 62{
63public:
64
65 /** Constructor */
66 AliHLTCaloClusterAnalyser();
67
68 /** Destructor */
69 virtual ~AliHLTCaloClusterAnalyser();
70
ea367f6a 71 /**
72 * Set the rec point data buffer
73 * @param recPointDataPtr is a pointer to the rec points
74 */
7c80a370 75 void SetRecPointArray(AliHLTCaloRecPointDataStruct **recPointDataPtr, Int_t nRecPoints);
ea367f6a 76
77 /**
78 * Set the calo cluster output buffer
79 * @param caloClusterDataPtr is a pointer to the calo cluster buffer
80 */
7c80a370 81 void SetCaloClusterData(AliHLTCaloClusterDataStruct *caloClusterDataPtr);
ea367f6a 82
83 /**
84 * Calculates the center of gravity for the reconstruction points in the container
85 * @return
86 */
87 Int_t CalculateCenterOfGravity();
88
89 /**
90 * Calculates the moments for the reconstruction points in the container
91 * @return
92 */
93 Int_t CalculateRecPointMoments();
94
95 /**
96 * Calculates the moments for a certain cluster
97 * @return
98 */
99 Int_t CalculateClusterMoments(AliHLTCaloRecPointDataStruct *recPointPtr, AliHLTCaloClusterDataStruct* clusterPtr);
100
101 /**
102 * Deconvolute the clusters in an AliHLTCaloRecPointContainerStruct
103 * @return
104 */
105 Int_t DeconvoluteClusters();
106
107 /**
108 * Convert the rec points into calo clusters
109 * @return
110 */
7c80a370 111 Int_t CreateClusters(Int_t nRecPoints, UInt_t availableSize, UInt_t& totSize);
ea367f6a 112
113 /**
114 * Fit a cluster
115 * param recPointPtr is a pointer to the rec point to fit
116 * @return
117 */
118 Int_t FitCluster(AliHLTCaloRecPointDataStruct* /*recPointPtr*/) { return 0; }
119
120 /**
121 * Get the distance to the nearest CPV rec point
122 * param recPointPtr is the pointer to the emc rec point
123 * @return the distance
124 */
125 Float_t GetCPVDistance(AliHLTCaloRecPointDataStruct* /*recPointPtr*/) { return 0; };
126
127 /**
128 * Do partice identification
129 * param clusterPtr is the pointer to the emc cluster
130 * @return
131 */
132 Int_t DoParticleIdentification(AliHLTCaloClusterDataStruct* /*clusterPtr*/) { return 0; }
133
134 /**
135 * Get the distance to the neares bad channel
136 * param clusterPtr is a pointer to the calo cluster
137 * @return the distance
138 */
139 Float_t GetDistanceToBadChannel(AliHLTCaloClusterDataStruct* /*clusterPtr*/) { return 0; }
140
141 /**
142 * Set do cluster fit
143 */
144 void SetDoClusterFit() { fDoClusterFit = true; }
145
146 /**
147 * Set have cpv info
148 */
149 void SetHaveCPVInfo() { fHaveCPVInfo = true; }
150
151 /**
152 * Set do PID
153 */
154 void SetDoPID() { fDoPID = true; }
155
156 /**
157 * Set have distance to bad channel
158 */
159 void SetHaveDistanceToBadChannel() { fHaveDistanceToBadChannel = true; }
160
7c80a370 161 /**
162 * Set the geometry object (different for EMCAL and PHOS)
163 */
164 void SetGeometry(AliHLTCaloGeometry *geometry) { fGeometry = geometry; }
165
166 /**
167 * Set pointer to the digits
168 */
169 void SetDigitDataArray(AliHLTCaloDigitDataStruct *digits);
170
73d6f579 171 /**
172 * Set the cluster type
173 */
174 void SetClusterType(Char_t clusterType) { fClusterType = clusterType; }
7c80a370 175
ea367f6a 176private:
177
178 /** Used for calculation of center of gravity */
179 Float_t fLogWeight; //COMMENT
180
181 /** Pointer to the rec points */
7c80a370 182 AliHLTCaloRecPointDataStruct **fRecPointArray; //! transient
183
184 /** Pointer to the digits */
185 AliHLTCaloDigitDataStruct *fDigitDataArray; //! transient
ea367f6a 186
187 /** Number of rec points */
188 Int_t fNRecPoints; //COMMENT
189
190 /** Pointer to the cluster buffer */
191 AliHLTCaloClusterDataStruct *fCaloClusterDataPtr; //! transient
192
193 /** Pointer to the cluster header */
194 AliHLTCaloClusterHeaderStruct *fCaloClusterHeaderPtr; //! transient
195
ea367f6a 196 /** Should we do cluster fitting? */
197 Bool_t fDoClusterFit; //COMMENT
198
199 /** Do we have CPV info? */
200 Bool_t fHaveCPVInfo; //COMMENT
201
202 /** Should we do PID? */
203 Bool_t fDoPID; //COMMENT
204
205 /** Do we have distance to bad channel? */
206 Bool_t fHaveDistanceToBadChannel; //COMMENT
207
7c80a370 208 /** The geometry object */
73d6f579 209 AliHLTCaloGeometry* fGeometry; //! transient
210
211 /** The cluster type */
212 Char_t fClusterType; //COMMENT
98baf84d 213
214 /** Copy constructor not implemented */
215 AliHLTCaloClusterAnalyser ( const AliHLTCaloClusterAnalyser &); // not implemented
216
217 /** Assignment */
218AliHLTCaloClusterAnalyser & operator = ( const AliHLTCaloClusterAnalyser &); // not implemented
219
ea367f6a 220};
221
222#endif