adding map include file to solve compilation issue (bug https://savannah.cern.ch...
[u/mrichter/AliRoot.git] / HLT / ITS / AliHLTITSClusterFinderComponent.h
CommitLineData
6e34b293 1//-*- Mode: C++ -*-
2// $Id$
6b7742a2 3#ifndef ALIHLTITSCLUSTERFINDERCOMPONENT_H
4#define ALIHLTITSCLUSTERFINDERCOMPONENT_H
5f2721d5 5
6//* This file is property of and copyright by the ALICE HLT Project *
7//* ALICE Experiment at CERN, All rights reserved. *
8//* See cxx source for full Copyright notice *
9
6b7742a2 10/** @file AliHLTITSClusterFinderComponent.cxx
5f2721d5 11 @author Gaute Øvrebekk <st05886@alf.uib.no>
12 @date
13 @brief Component to run the offline clusterfinder.
14*/
15
16#include "AliHLTProcessor.h"
17#include "AliRawReaderMemory.h"
5f2721d5 18#include "AliITSDetTypeRec.h"
5f2721d5 19#include "AliITSgeom.h"
20#include "AliITSInitGeometry.h"
d293cef8 21#include "TClonesArray.h"
a2a2a7ce 22#include "AliHLTDataTypes.h"
618f422f 23#include "TTree.h"
57a4102f 24#include "AliHLTComponentBenchmark.h"
5f2721d5 25
3f61e9ce 26class AliHLTITSClusterFinderSPD;
a2a2a7ce 27class AliHLTITSClusterFinderSSD;
3f61e9ce 28
29
5f2721d5 30/**
6b7742a2 31 * @class AliHLTITSClusterFinderComponent
32 * HLT Component to run the ITS offline clusterfinders.
21de9ddd 33 *
34 * <h2>General properties:</h2>
35 *
6b7742a2 36 * Component ID: \b ITSClusterFinderSPD or ITSClusterFinderSDD or ITSClusterFinderSSD <br>
21de9ddd 37 * Library: \b libAliHLTITS.so <br>
38 * Input Data Types: <br>
6b7742a2 39 * kAliHLTDataTypeDDLRaw|kAliHLTDataOriginITSSPD or kAliHLTDataTypeDDLRaw|kAliHLTDataOriginITSSDD or kAliHLTDataTypeDDLRaw|kAliHLTDataOriginITSSD <br>
21de9ddd 40 *
41 * Output Data Types: <br>
6b7742a2 42 * kAliHLTDataTypeClusters|kAliHLTDataOriginITSSPD or kAliHLTDataTypeClusters|kAliHLTDataOriginITSSDD or kAliHLTDataTypeClusters|kAliHLTDataOriginITSSSD <br>
21de9ddd 43 *
44 * <h2>Mandatory arguments:</h2>
45 * <!-- NOTE: ignore the \li. <i> and </i>: it's just doxygen formatting -->
46 *
47 * <h2>Optional arguments:</h2>
48 * <!-- NOTE: ignore the \li. <i> and </i>: it's just doxygen formatting -->
49 *
50 * <h2>Configuration:</h2>
51 * <!-- NOTE: ignore the \li. <i> and </i>: it's just doxygen formatting -->
52 * \li -config1 <i> teststring </i> <br>
53 * a configuration argument with one parameter
54 * \li -config2 <br>
55 * a configuration argument without parameters
56 *
57 * <h2>Default CDB entries:</h2>
2bd1335e 58 * ITS/Calib/SPDNoisy
59 * ITS/Calib/SPDDead
60 * TRIGGER/SPD/PITConditions
61 * ITS/Calib/CalibSDD
62 * ITS/Calib/RespSDD
63 * ITS/Calib/DriftSpeedSDD
64 * ITS/Calib/DDLMapSDD
65 * ITS/Calib/MapsTimeSDD
66 * ITS/Calib/NoiseSSD
67 * ITS/Calib/GainSSD
68 * ITS/Calib/BadChannelsSSD
69 * GRP/CTP/Scalers
21de9ddd 70 *
71 * <h2>Performance:</h2>
72 * TODO
73 *
74 * <h2>Memory consumption:</h2>
75 * TODO
76 *
77 * <h2>Output size:</h2>
78 * TODO
5f2721d5 79 *
80 * @ingroup alihlt_its_components
81 */
6b7742a2 82class AliHLTITSClusterFinderComponent : public AliHLTProcessor
5f2721d5 83{
84 public:
6b7742a2 85 /**
86 * Defines for selecting clusterfinder for SPD, SDD or SSD.
87 */
88 enum {
89 kClusterFinderSPD,
90 kClusterFinderSDD,
618f422f 91 kClusterFinderSSD,
92 kClusterFinderDigits
6b7742a2 93 };
5f2721d5 94 /*
95 * ---------------------------------------------------------------------------------
96 * Constructor / Destructor
97 * ---------------------------------------------------------------------------------
98 */
99
6b7742a2 100 /** constructor
101 * @param mode input type see e.g. @ref kClusterFinderSPD
102 */
103 AliHLTITSClusterFinderComponent(int mode);
5f2721d5 104
105 /** destructor */
6b7742a2 106 virtual ~AliHLTITSClusterFinderComponent();
5f2721d5 107
108 /*
109 * ---------------------------------------------------------------------------------
110 * Public functions to implement AliHLTComponent's interface.
111 * These functions are required for the registration process
112 * ---------------------------------------------------------------------------------
113 */
114
115 /** interface function, see @ref AliHLTComponent for description */
116 const char* GetComponentID();
117
118 /** interface function, see @ref AliHLTComponent for description */
119 void GetInputDataTypes( vector<AliHLTComponentDataType>& list);
120
121 /** interface function, see @ref AliHLTComponent for description */
122 AliHLTComponentDataType GetOutputDataType();
123
124 /** interface function, see @ref AliHLTComponent for description */
125 virtual void GetOutputDataSize( unsigned long& constBase, double& inputMultiplier );
126
127 /** interface function, see @ref AliHLTComponent for description */
6eb9783a 128 void GetOCDBObjectDescription( TMap* const targetMap);
129
130 /** interface function, see @ref AliHLTComponent for description */
5f2721d5 131 AliHLTComponent* Spawn();
132
133 protected:
134
135 /*
136 * ---------------------------------------------------------------------------------
137 * Protected functions to implement AliHLTComponent's interface.
138 * These functions provide initialization as well as the actual processing
139 * capabilities of the component.
140 * ---------------------------------------------------------------------------------
141 */
142
143 /** Initialization */
144 Int_t DoInit( int argc, const char** argv );
145
146 /** DeInitialization */
147 Int_t DoDeinit();
148
5f2721d5 149 /** EventLoop */
a2a2a7ce 150
151 Int_t DoEvent(
152 const AliHLTComponentEventData& evtData,
153 const AliHLTComponentBlockData* blocks,
154 AliHLTComponentTriggerData& /*trigData*/,
155 AliHLTUInt8_t* outputPtr,
156 AliHLTUInt32_t& size,
157 vector<AliHLTComponentBlockData>& outputBlocks );
5f2721d5 158
a2a2a7ce 159 //Int_t DoEvent( const AliHLTComponentEventData& /*evtData*/, AliHLTComponentTriggerData& /*trigData*/);
6b7742a2 160
161 int Reconfigure(const char* cdbEntry, const char* chainId);
6eb9783a 162
5f2721d5 163 using AliHLTProcessor::DoEvent;
164
165 ///////////////////////////////////////////////////////////////////////////////////
166
6b7742a2 167 private:
168 /** standard constructor prohibited */
169 AliHLTITSClusterFinderComponent();
5f2721d5 170 /** copy constructor prohibited */
6b7742a2 171 AliHLTITSClusterFinderComponent(const AliHLTITSClusterFinderComponent&);
5f2721d5 172 /** assignment operator prohibited */
6b7742a2 173 AliHLTITSClusterFinderComponent& operator=(const AliHLTITSClusterFinderComponent&);
174 /**
175 * Configure the component.
176 * Parse a string for the configuration arguments and set the component
177 * properties.
178 */
179 int Configure(const char* arguments);
618f422f 180
181 void RecPointToSpacePoint(AliHLTUInt8_t* outputPtr,AliHLTUInt32_t& size);
5f2721d5 182 /*
183 * ---------------------------------------------------------------------------------
184 * Members - private
185 * ---------------------------------------------------------------------------------
186 */
187
6b7742a2 188 /**
189 * switch to indicated the ClusterFinder
190 * use fModeSwitch = 0 for SPD
191 * use fModeSwitch = 1 for SDD
192 * use fModeSwitch = 2 for SSD
618f422f 193 * use fModeSwitch = 3 for ClusterFinding on Digits (Full ITS)
6b7742a2 194 */
a2a2a7ce 195 Int_t fModeSwitch; // !
196 AliHLTComponentDataType fInputDataType; // !
197 AliHLTComponentDataType fOutputDataType; // !
198
199 Bool_t fUseOfflineFinder; // flag to use the offline clusterfinder
6b7742a2 200 Int_t fNModules; // total number of modules
201 Int_t fId; // ddl offset
202 Int_t fNddl; // number of ddl's
203
d293cef8 204 TClonesArray** fClusters; //!transient
205
5f2721d5 206 /** the reader object for data decoding */
5f2721d5 207
a2a2a7ce 208 AliRawReaderMemory* fRawReader; //!transient
5f2721d5 209 AliITSDetTypeRec* fDettype; //!transient
5f2721d5 210 AliITSgeom* fgeom; //!transient
5f2721d5 211 AliITSInitGeometry* fgeomInit; //!transient
618f422f 212
213 AliHLTITSClusterFinderSPD *fSPD; //!transient
214 AliHLTITSClusterFinderSSD *fSSD; //!transient
6e34b293 215
618f422f 216 TTree *tD; //!transient
217 TTree *tR; //!transient
3f61e9ce 218
618f422f 219 std::vector<AliITSRecPoint> fclusters; //!transient
57a4102f 220
221 AliHLTComponentBenchmark fBenchmark;// benchmark
3f61e9ce 222
6b7742a2 223 ClassDef(AliHLTITSClusterFinderComponent, 0)
5f2721d5 224
a2a2a7ce 225};
5f2721d5 226#endif