]> git.uio.no Git - u/mrichter/AliRoot.git/blame - HLT/TPCLib/tracking-ca/AliHLTTPCCAPerformance.h
Fit mathematics improved, obsollete GBTracker cleaned up
[u/mrichter/AliRoot.git] / HLT / TPCLib / tracking-ca / AliHLTTPCCAPerformance.h
CommitLineData
d54804bf 1//-*- Mode: C++ -*-
2// $Id$
ce565086 3// ************************************************************************
4// This file is property of and copyright by the ALICE HLT Project *
5// ALICE Experiment at CERN, All rights reserved. *
6// See cxx source for full Copyright notice *
7// *
8//*************************************************************************
d54804bf 9
10#ifndef ALIHLTTPCCAPERFORMANCE_H
11#define ALIHLTTPCCAPERFORMANCE_H
12
00d07bcd 13#include "AliHLTTPCCADef.h"
ce565086 14#include "Riostream.h"
d54804bf 15
00d07bcd 16class TObject;
d54804bf 17class TParticle;
18class AliHLTTPCCAMCTrack;
eb30eb49 19class AliHLTTPCCAMCPoint;
d54804bf 20class AliHLTTPCCAGBTracker;
21class TDirectory;
22class TH1D;
eb30eb49 23class TH2D;
d54804bf 24class TProfile;
25
26/**
27 * @class AliHLTTPCCAPerformance
28 *
29 * Does performance evaluation of the HLT Cellular Automaton-based tracker
30 * It checks performance for AliHLTTPCCATracker slice tracker
31 * and for AliHLTTPCCAGBTracker global tracker
32 *
33 */
00d07bcd 34class AliHLTTPCCAPerformance
d54804bf 35{
36
37 public:
38
693d2443 39 struct AliHLTTPCCAHitLabel{
40 Int_t fLab[3]; //* array of 3 MC labels
41 };
42
d54804bf 43 AliHLTTPCCAPerformance();
44 AliHLTTPCCAPerformance(const AliHLTTPCCAPerformance&);
ce565086 45 const AliHLTTPCCAPerformance &operator=(const AliHLTTPCCAPerformance&) const;
d54804bf 46
47 virtual ~AliHLTTPCCAPerformance();
48
693d2443 49 static AliHLTTPCCAPerformance &Instance();
50
ce565086 51 void SetTracker( AliHLTTPCCAGBTracker * const Tracker );
d54804bf 52 void StartEvent();
53 void SetNHits( Int_t NHits );
54 void SetNMCTracks( Int_t NMCTracks );
eb30eb49 55 void SetNMCPoints( Int_t NMCPoints );
56
d54804bf 57 void ReadHitLabel( Int_t HitID,
58 Int_t lab0, Int_t lab1, Int_t lab2 );
59 void ReadMCTrack( Int_t index, const TParticle *part );
eb30eb49 60 void ReadMCTPCTrack( Int_t index, Float_t X, Float_t Y, Float_t Z,
61 Float_t Px, Float_t Py, Float_t Pz );
62
63 void ReadMCPoint( Int_t TrackID, Float_t X, Float_t Y, Float_t Z, Float_t Time, Int_t iSlice );
d54804bf 64
65 void CreateHistos();
66 void WriteHistos();
67 void SlicePerformance( Int_t iSlice, Bool_t PrintFlag );
ce565086 68 void SliceTrackletPerformance( Int_t iSlice, Bool_t PrintFlag );
69 void SliceTrackCandPerformance( Int_t iSlice, Bool_t PrintFlag );
70
4687b8fc 71 void Performance( fstream *StatFile = 0);
d54804bf 72
00d07bcd 73 void WriteMCEvent( ostream &out ) const;
eb30eb49 74 void ReadMCEvent( istream &in );
00d07bcd 75 void WriteMCPoints( ostream &out ) const;
eb30eb49 76 void ReadMCPoints( istream &in );
693d2443 77 Bool_t DoClusterPulls() const { return fDoClusterPulls; }
78 void SetDoClusterPulls( Bool_t v ) { fDoClusterPulls = v; }
ce565086 79 AliHLTTPCCAHitLabel *HitLabels() const { return fHitLabels;}
80 AliHLTTPCCAMCTrack *MCTracks() const { return fMCTracks; }
693d2443 81 Int_t NMCTracks() const { return fNMCTracks; }
82
83 TH1D *HNHitsPerSeed() const { return fhNHitsPerSeed;}
84 TH1D *HNHitsPerTrackCand() const { return fhNHitsPerTrackCand; }
eb30eb49 85
ce565086 86 TH1D *LinkChiRight( int i ) const { return fhLinkChiRight[i]; }
87 TH1D *LinkChiWrong( int i ) const { return fhLinkChiWrong[i]; }
88
89 void LinkPerformance( Int_t iSlice );
90
d54804bf 91protected:
92
93 AliHLTTPCCAGBTracker *fTracker; //* pointer to the tracker
94
eb30eb49 95
d54804bf 96 AliHLTTPCCAHitLabel *fHitLabels; //* array of hit MC labels
eb30eb49 97 Int_t fNHits; //* number of hits
98 AliHLTTPCCAMCTrack *fMCTracks; //* array of MC tracks
99 Int_t fNMCTracks; //* number of MC tracks
100 AliHLTTPCCAMCPoint *fMCPoints; //* array of MC points
101 Int_t fNMCPoints; //* number of MC points
102 Bool_t fDoClusterPulls; //* do cluster pulls (very slow)
d54804bf 103 Int_t fStatNEvents; //* n of events proceed
4687b8fc 104 Double_t fStatTime; //* reco time;
ce565086 105
106 Int_t fStatSeedNRecTot; //* total n of reconstructed tracks
107 Int_t fStatSeedNRecOut; //* n of reconstructed tracks in Out set
108 Int_t fStatSeedNGhost;//* n of reconstructed tracks in Ghost set
109 Int_t fStatSeedNMCAll;//* n of MC tracks
110 Int_t fStatSeedNRecAll; //* n of reconstructed tracks in All set
111 Int_t fStatSeedNClonesAll;//* total n of reconstructed tracks in Clone set
112 Int_t fStatSeedNMCRef; //* n of MC reference tracks
113 Int_t fStatSeedNRecRef; //* n of reconstructed tracks in Ref set
114 Int_t fStatSeedNClonesRef; //* n of reconstructed clones in Ref set
115
116 Int_t fStatCandNRecTot; //* total n of reconstructed tracks
117 Int_t fStatCandNRecOut; //* n of reconstructed tracks in Out set
118 Int_t fStatCandNGhost;//* n of reconstructed tracks in Ghost set
119 Int_t fStatCandNMCAll;//* n of MC tracks
120 Int_t fStatCandNRecAll; //* n of reconstructed tracks in All set
121 Int_t fStatCandNClonesAll;//* total n of reconstructed tracks in Clone set
122 Int_t fStatCandNMCRef; //* n of MC reference tracks
123 Int_t fStatCandNRecRef; //* n of reconstructed tracks in Ref set
124 Int_t fStatCandNClonesRef; //* n of reconstructed clones in Ref set
125
d54804bf 126 Int_t fStatNRecTot; //* total n of reconstructed tracks
127 Int_t fStatNRecOut; //* n of reconstructed tracks in Out set
128 Int_t fStatNGhost;//* n of reconstructed tracks in Ghost set
129 Int_t fStatNMCAll;//* n of MC tracks
130 Int_t fStatNRecAll; //* n of reconstructed tracks in All set
131 Int_t fStatNClonesAll;//* total n of reconstructed tracks in Clone set
132 Int_t fStatNMCRef; //* n of MC reference tracks
133 Int_t fStatNRecRef; //* n of reconstructed tracks in Ref set
134 Int_t fStatNClonesRef; //* n of reconstructed clones in Ref set
135
eb30eb49 136 Int_t fStatGBNRecTot; //* global tracker: total n of reconstructed tracks
137 Int_t fStatGBNRecOut; //* global tracker: n of reconstructed tracks in Out set
138 Int_t fStatGBNGhost;//* global tracker: n of reconstructed tracks in Ghost set
139 Int_t fStatGBNMCAll;//* global tracker: n of MC tracks
140 Int_t fStatGBNRecAll; //* global tracker: n of reconstructed tracks in All set
141 Int_t fStatGBNClonesAll;//* global tracker: total n of reconstructed tracks in Clone set
142 Int_t fStatGBNMCRef; //* global tracker: n of MC reference tracks
143 Int_t fStatGBNRecRef; //* global tracker: n of reconstructed tracks in Ref set
144 Int_t fStatGBNClonesRef; //* global tracker: n of reconstructed clones in Ref set
145
d54804bf 146 TDirectory *fHistoDir; //* ROOT directory with histogramms
147
eb30eb49 148 TH1D
149 *fhResY, //* track Y resolution at the TPC entrance
150 *fhResZ, //* track Z resolution at the TPC entrance
151 *fhResSinPhi, //* track SinPhi resolution at the TPC entrance
152 *fhResDzDs, //* track DzDs resolution at the TPC entrance
153 *fhResPt, //* track Pt relative resolution at the TPC entrance
154 *fhPullY, //* track Y pull at the TPC entrance
155 *fhPullZ, //* track Z pull at the TPC entrance
156 *fhPullSinPhi, //* track SinPhi pull at the TPC entrance
157 *fhPullDzDs, //* track DzDs pull at the TPC entrance
693d2443 158 *fhPullQPt, //* track Q/Pt pull at the TPC entrance
159 *fhPullYS, //* sqrt(chi2/ndf) deviation of the track parameters Y and SinPhi at the TPC entrance
160 *fhPullZT; //* sqrt(chi2/ndf) deviation of the track parameters Z and DzDs at the TPC entrance
eb30eb49 161
d54804bf 162 TH1D
163 *fhHitErrY, //* hit error in Y
eb30eb49 164 *fhHitErrZ,//* hit error in Z
d54804bf 165 *fhHitResY,//* hit resolution Y
166 *fhHitResZ,//* hit resolution Z
d54804bf 167 *fhHitPullY,//* hit pull Y
eb30eb49 168 *fhHitPullZ;//* hit pull Z
ce565086 169 TProfile *fhHitShared; //* ratio of the shared clusters
eb30eb49 170
171 TH1D
172 *fhHitResY1,//* hit resolution Y, pt>1GeV
173 *fhHitResZ1,//* hit resolution Z, pt>1GeV
174 *fhHitPullY1,//* hit pull Y, pt>1GeV
175 *fhHitPullZ1;//* hit pull Z, pt>1GeV
176
177 TH1D
d54804bf 178 *fhCellPurity,//* cell purity
179 *fhCellNHits//* cell n hits
180 ;
181
00d07bcd 182 TProfile
183 *fhCellPurityVsN, //* cell purity vs N hits
184 *fhCellPurityVsPt,//* cell purity vs MC Pt
185 *fhEffVsP, //* reconstruction efficiency vs P plot
ce565086 186 *fhSeedEffVsP, //* reconstruction efficiency vs P plot
187 *fhCandEffVsP, //* reconstruction efficiency vs P plot
00d07bcd 188 *fhGBEffVsP, //* global reconstruction efficiency vs P plot
4687b8fc 189 *fhGBEffVsPt, //* global reconstruction efficiency vs P plot
00d07bcd 190 *fhNeighQuality, // quality for neighbours finder
191 *fhNeighEff,// efficiency for neighbours finder
192 *fhNeighQualityVsPt,// quality for neighbours finder vs track Pt
193 *fhNeighEffVsPt;// efficiency for neighbours finder vs track Pt
194 TH1D
195 *fhNeighDy, // dy for neighbours
196 *fhNeighDz,// dz for neighbours
197 *fhNeighChi;// chi2^0.5 for neighbours
198 TH2D
199 *fhNeighDyVsPt, // dy for neighbours vs track Pt
200 *fhNeighDzVsPt,// dz for neighbours vs track Pt
201 *fhNeighChiVsPt, // chi2^0.5 for neighbours vs track Pt
202 *fhNeighNCombVsArea; // N neighbours in the search area
d54804bf 203
693d2443 204 TH1D
205 *fhNHitsPerSeed, // n hits per track seed
206 *fhNHitsPerTrackCand; // n hits per track candidate
207
208 TH1D
209 *fhTrackLengthRef, // reconstructed track length, %
210 *fhRefRecoX,// parameters of non-reconstructed ref. mc track
211 *fhRefRecoY,// parameters of non-reconstructed ref. mc track
212 *fhRefRecoZ,// parameters of non-reconstructed ref. mc track
213 *fhRefRecoP, // parameters of non-reconstructed ref. mc track
214 *fhRefRecoPt,// parameters of non-reconstructed ref. mc track
215 *fhRefRecoAngleY,// parameters of non-reconstructed ref. mc track
216 *fhRefRecoAngleZ,// parameters of non-reconstructed ref. mc track
217 *fhRefRecoNHits,// parameters of non-reconstructed ref. mc track
218 *fhRefNotRecoX,// parameters of non-reconstructed ref. mc track
219 *fhRefNotRecoY,// parameters of non-reconstructed ref. mc track
220 *fhRefNotRecoZ,// parameters of non-reconstructed ref. mc track
221 *fhRefNotRecoP, // parameters of non-reconstructed ref. mc track
222 *fhRefNotRecoPt,// parameters of non-reconstructed ref. mc track
223 *fhRefNotRecoAngleY,// parameters of non-reconstructed ref. mc track
224 *fhRefNotRecoAngleZ,// parameters of non-reconstructed ref. mc track
225 *fhRefNotRecoNHits;// parameters of non-reconstructed ref. mc track
226
ce565086 227 TProfile * fhLinkEff[4]; // link efficiency
228 TH1D *fhLinkAreaY[4]; // area in Y for the link finder
229 TH1D *fhLinkAreaZ[4]; // area in Z for the link finder
230 TH1D *fhLinkChiRight[4]; // sqrt(chi^2) for right neighbours
231 TH1D *fhLinkChiWrong[4]; // sqrt(chi^2) for wrong neighbours
232
d54804bf 233 static void WriteDir2Current( TObject *obj );
234
d54804bf 235};
236
237#endif