Project
Loading...
Searching...
No Matches
TrackingInterface.h
Go to the documentation of this file.
1// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3// All rights not expressly granted are reserved.
4//
5// This software is distributed under the terms of the GNU General Public
6// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7//
8// In applying this license CERN does not waive the privileges and immunities
9// granted to it by virtue of its status as an Intergovernmental Organization
10// or submit itself to any jurisdiction.
11
12#ifndef O2_ITS_TRACKINGINTERFACE
13#define O2_ITS_TRACKINGINTERFACE
14
16
18#include "ITStracking/Tracker.h"
26
27#include "GPUDataTypesIO.h"
28#include "GPUO2ExternalUser.h"
29#include "GPUChainITS.h"
30
31#include <oneapi/tbb/task_arena.h>
32#include <utility>
33#include <vector>
34
35namespace o2::its
36{
38{
39 public:
40 static constexpr int NLayers{7};
46
48 bool doStag,
49 int trgType,
50 const bool overrBeamEst)
51 : mIsMC{isMC},
52 mDoStaggering(doStag),
53 mUseTriggers{trgType},
54 mOverrideBeamEstimation{overrBeamEst} {}
55
58 {
59 if (v == nullptr) {
60 LOGP(error, "Mean Vertex Object is nullptr");
61 return;
62 } else {
63 LOGP(info, "Mean Vertex set with x: {} y: {}", v->getX(), v->getY());
64 }
65 mMeanVertex = v;
66 }
67 // Task callbacks
68 void initialise();
70 void printSummary() const;
71
73 virtual void finaliseCCDB(framework::ConcreteDataMatcher& matcher, void* obj);
74
75 // Custom
78
79 auto getTracker() const { return mTracker.get(); }
80 auto getVertexer() const { return mVertexer.get(); }
81
83
84 protected:
85 virtual void overrideParameters(std::vector<TrackingParameters>& t, std::vector<VertexingParameters>& v) {}
87 virtual void loadROF(gsl::span<const itsmft::ROFRecord>& trackROFspan,
88 gsl::span<const itsmft::CompClusterExt> clusters,
89 gsl::span<const unsigned char>::iterator& pattIt,
90 int layer,
92
93 private:
94 bool mIsMC = false;
95 bool mDoStaggering = false;
96 bool mRunVertexer = true;
97 bool mCosmicsProcessing = false;
98 int mUseTriggers = 0;
99 std::vector<o2::framework::InputSpec> mFilter;
101 bool mOverrideBeamEstimation = false;
102 const o2::itsmft::TopologyDictionary* mDict = nullptr;
103 std::unique_ptr<TrackerN> mTracker = nullptr;
104 std::unique_ptr<VertexerN> mVertexer = nullptr;
105 const o2::dataformats::MeanVertexObject* mMeanVertex{};
106 std::shared_ptr<BoundedMemoryResource> mMemoryPool;
107 std::shared_ptr<tbb::task_arena> mTaskArena;
108};
109
110} // namespace o2::its
111#endif // O2_ITS_TRACKINGINTERFACE
Definition of the ClusterTopology class.
Header of the General Run Parameters object.
Class to compute the primary vertex in ITS from tracklets.
A container to hold and manage MC truth information/labels.
VertexerTraits< NLayers > VertexerTraitsN
TrackerTraits< NLayers > TrackerTraitsN
TimeFrame< NLayers > TimeFrameN
void run(framework::ProcessingContext &pc)
void setMeanVertex(const o2::dataformats::MeanVertexObject *v)
void setTrackingMode(TrackingMode::Type mode=TrackingMode::Unset)
void setClusterDictionary(const o2::itsmft::TopologyDictionary *d)
virtual void requestTopologyDictionary(framework::ProcessingContext &pc)
virtual void updateTimeDependentParams(framework::ProcessingContext &pc)
virtual void loadROF(gsl::span< const itsmft::ROFRecord > &trackROFspan, gsl::span< const itsmft::CompClusterExt > clusters, gsl::span< const unsigned char >::iterator &pattIt, int layer, const dataformats::MCTruthContainer< MCCompLabel > *mcLabels)
virtual void finaliseCCDB(framework::ConcreteDataMatcher &matcher, void *obj)
ITSTrackingInterface(bool isMC, bool doStag, int trgType, const bool overrBeamEst)
void setTraitsFromProvider(VertexerTraitsN *, TrackerTraitsN *, TimeFrameN *)
virtual void overrideParameters(std::vector< TrackingParameters > &t, std::vector< VertexingParameters > &v)
GLenum mode
Definition glcorearb.h:266
const GLdouble * v
Definition glcorearb.h:832
GLenum GLuint GLint GLint layer
Definition glcorearb.h:1310
std::vector< Cluster > clusters