1 #ifndef ALIALIGNMENTTRACKS_H
2 #define ALIALIGNMENTTRACKS_H
4 //*************************************************************************
5 // AliAlignmentTracks: main steering class which deals with the alignment *
6 // procedures based on reconstructed tracks. *
7 // More comments will come with the development of the interfaces and *
8 // functionalities of the class. *
9 //*************************************************************************
13 #include "AliAlignObj.h"
16 class AliTrackPointArray;
19 class AliTrackResiduals;
21 class AliAlignmentTracks : public TObject {
26 AliAlignmentTracks(TChain *esdchain);
27 AliAlignmentTracks(const char *esdfilename, const char *esdtreename = "esdTree");
28 AliAlignmentTracks(const AliAlignmentTracks & alignment);
29 AliAlignmentTracks& operator= (const AliAlignmentTracks& alignment);
30 virtual ~AliAlignmentTracks();
32 void AddESD(TChain *esdchain);
33 void AddESD(const char *esdfilename, const char *esdtreename = "esdTree");
35 void SetPointsFilename(const char *pointsfilename = "AliTrackPoints.root") { fPointsFilename = pointsfilename; }
37 void ProcessESD(TSelector *selector);
41 /* void BuildIndexLayer(AliAlignObj::ELayerID layer); */
42 /* void BuildIndexVolume(UShort_t volid); */
44 Bool_t ReadAlignObjs(const char *alignobjfilename = "AlignObjs.root");
46 void SetTrackFitter(AliTrackFitter *fitter) { fTrackFitter = fitter; }
47 void SetMinimizer(AliTrackResiduals *minimizer) { fMinimizer = minimizer; }
49 void Align(Int_t iterations = 100);
50 void AlignLayer(AliAlignObj::ELayerID layer,
51 AliAlignObj::ELayerID layerRangeMin = AliAlignObj::kFirstLayer,
52 AliAlignObj::ELayerID layerRangeMax = AliAlignObj::kLastLayer,
53 Int_t iterations = 1);
54 void AlignVolume(UShort_t volid,
55 AliAlignObj::ELayerID layerRangeMin = AliAlignObj::kFirstLayer,
56 AliAlignObj::ELayerID layerRangeMax = AliAlignObj::kLastLayer);
65 void ResetAlignObjs();
66 void DeleteAlignObjs();
68 Int_t LoadPoints(UShort_t volid, AliTrackPointArray** &points);
69 void UnloadPoints(Int_t n, AliTrackPointArray **points);
71 AliTrackFitter *CreateFitter();
72 AliTrackResiduals *CreateMinimizer();
74 TChain *fESDChain; //! Chain with ESDs
75 TString fPointsFilename; // Name of the file containing the track point arrays
76 TFile *fPointsFile; // File containing the track point arrays
77 TTree *fPointsTree; // Tree with the track point arrays
78 Int_t **fLastIndex; //! Last filled index in volume arrays
79 TArrayI ***fArrayIndex; //! Volume arrays which contains the tree index
80 Bool_t fIsIndexBuilt; // Is points tree index built
81 AliAlignObj ***fAlignObjs; // Array with alignment objects
82 AliTrackFitter *fTrackFitter; // Pointer to the track fitter
83 AliTrackResiduals*fMinimizer; // Pointer to track residuals minimizer
85 ClassDef(AliAlignmentTracks,1)