Go to the documentation of this file.
21 #include "FairLogger.h"
22 #include "FairRunAna.h"
23 #include "FairRuntimeDb.h"
25 #include "TClonesArray.h"
53 Int_t nEvents =
fEvents->GetEntriesFast();
54 LOG(debug) << GetName() <<
": reading time slice with " << nEvents
57 for (Int_t iEvent = 0; iEvent < nEvents; iEvent++) {
70 LOG(warn) <<
"CbmLitFindMvdTracks::Exec: MVD tracking is not executed NO "
71 "StsTrack or MvdHit arrays.";
73 LOG(info) <<
"-I- Event: " <<
fEventNo++;
77 FairRunAna* ana = FairRunAna::Instance();
78 FairRuntimeDb* rtdb = ana->GetRuntimeDb();
79 rtdb->getContainer(
"FairBaseParSet");
85 FairRootManager* ioman = FairRootManager::Instance();
87 LOG(fatal) <<
"CbmLitFindMvdTracks::ReadAndCreateDataBranches "
88 "FairRootManager is not instantiated";
90 fMvdHits = (TClonesArray*) ioman->GetObject(
"MvdHit");
91 fStsTracks = (TClonesArray*) ioman->GetObject(
"StsTrack");
92 fEvents =
dynamic_cast<TClonesArray*
>(ioman->GetObject(
"Event"));
98 for (Int_t iTrack = 0; iTrack <
fLitStsTracks.size(); iTrack++) {
103 LOG(info) <<
"-I- Number of STS tracks: " <<
fLitStsTracks.size();
109 for (Int_t iHit = 0; iHit <
fLitMvdHits.size(); iHit++) {
113 LOG(info) <<
"-I- Number of MVD hits: " <<
fLitMvdHits.size();
121 for (Int_t iHit = 0; iHit < litTrack->
GetNofHits(); iHit++) {
124 FairHit* hit =
static_cast<FairHit*
>(
fMvdHits->At(refId));
129 FairTrackParam parFirst;
Data class for track parameters.
TClonesArray * fStsTracks
void ReadAndCreateDataBranches()
Read necessary data branches from the input data files.
Data class for track parameters.
virtual void SetParContainers()
Inherited from FairTask.
Tracking geometry constructor.
Int_t GetNofMvdStations()
Return number of stations in MVD.
TrackPtrVector fLitStsTracks
Base data class for pixel hits.
void SetDetectorId(LitSystemId sysId, Int_t station)
void SetParamLast(const CbmLitTrackParam *par)
virtual void Exec(Option_t *opt)
Inherited from FairTask.
static void CbmLitTrackParamToFairTrackParam(const CbmLitTrackParam *litPar, FairTrackParam *par)
void ConvertOutputData()
Convert output littrack data classes to CBMROOT data classes.
void ConvertInputData(CbmEvent *event)
Convert input data from CBMROOT data classes to littrack data classes.
Data class for STS tracks.
Int_t GetPreviousTrackId() const
Base data class for hits.
static void MvdHitArrayToHitVector(const TClonesArray *hits, HitPtrVector &litHits)
void ClearArrays()
Clear arrays and free memory.
Base data class for track.
const CbmLitTrackParam * GetParamLast() const
virtual ~CbmLitFindMvdTracks()
Destructor.
CbmLitFindMvdTracks()
Constructor.
const CbmLitTrackParam * GetParamFirst() const
MVD tracking based on littrack package.
static void StsTrackArrayToTrackVector(CbmEvent *event, const TClonesArray *tracks, TrackPtrVector &litTracks)
Base data class for track.
void SetParamFirst(const FairTrackParam *par)
Class characterising one event by a collection of links (indices) to data objects,...
virtual void Finish()
Inherited from FairTask.
static CbmLitTrackingGeometryConstructor * Instance()
Return pointer to singleton object.
const CbmLitHit * GetHit(Int_t index) const
virtual InitStatus Init()
Inherited from FairTask.
Base data class for hits.
void RunTrackReconstruction()
Run track reconstruction.
Implementation of nearest neighbor tracking algorithm.
TrackPtrVector fLitOutputTracks
void AddMvdHit(Int_t hitIndex)