Project
Loading...
Searching...
No Matches
CATrackerSpec.cxx
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
13
15
16#include <stdexcept>
17#include <algorithm>
18#include <array>
19#include <limits>
20#include <memory>
21#include <numeric>
22#include <ranges>
23#include <utility>
24#include <vector>
25
26#include <gsl/span>
27
36#include "Framework/Logger.h"
46#include <oneapi/tbb/task_arena.h>
53
54using namespace o2::framework;
55
56namespace o2::its::ca
57{
58
59namespace
60{
61using namespace o2::itsmft::tracking;
62
63template <int NLayers>
64constexpr std::array<LayerId, NLayers> detectorLocalToLayoutLayers()
65{
66 std::array<LayerId, NLayers> order{};
67 for (int i = 0; i < NLayers; ++i) {
68 order[i] = LayerId{static_cast<uint16_t>(i)};
69 }
70 return order;
71}
72
73inline constexpr auto kLayerToLayout = detectorLocalToLayoutLayers<ITSNLayers>();
74
75struct TrackOutput {
76 std::vector<o2::its::TrackITS> tracks;
77 std::vector<int> clusterIndices;
78 std::vector<o2::itsmft::ROFRecord> trackROFs;
79 std::vector<o2::MCCompLabel> labels;
80};
81
82bool exportTrackState(const SurfaceTrackState& source, o2::track::TrackParCovF& destination) noexcept
83{
84 if (source.kind != SurfaceKind::Cylinder) {
85 return false;
86 }
87 o2::track::TrackParCovF::params_t parameters{};
88 o2::track::TrackParCovF::covMat_t covariance{};
89 for (uint8_t i = 0; i < 5; ++i) {
90 parameters[i] = source.parameters[i];
91 }
92 for (uint8_t i = 0; i < 15; ++i) {
93 covariance[i] = source.covariance[i];
94 }
95 const o2::track::TrackParCovF scratch{source.referenceCoordinate, source.alpha, parameters, covariance, source.absCharge, source.pid};
96 destination = scratch;
97 return true;
98}
99
100bool collectReferences(const TimeFrame& frame, const GenericTrack& common, std::vector<int>& outputIndices, o2::its::TrackITS& output,
101 uint32_t& pattern,
102 const std::vector<std::vector<uint32_t>>* externalIndicesBySurface,
103 const std::vector<std::vector<uint32_t>>* clusterSizesBySurface)
104{
105 constexpr uint32_t maxLayers = ITSNLayers;
106 const auto& layerMapping = kLayerToLayout;
107 const auto& references = frame.getTrackClusterIndices();
108 std::array<const TrackClusterReference*, maxLayers> byLayer{};
109 for (uint32_t ref = common.firstClusterRef; ref < common.clusterRefEnd; ++ref) {
110 const auto& key = references[ref];
111 if (!key.isValid()) {
112 return false;
113 }
114 const auto where = std::find(layerMapping.begin(), layerMapping.end(), key.layer);
115 if (where == layerMapping.end() || static_cast<uint32_t>(where - layerMapping.begin()) >= maxLayers) {
116 return false;
117 }
118 const auto layer = static_cast<uint32_t>(where - layerMapping.begin());
119 if (byLayer[layer] != nullptr) {
120 return false;
121 }
122 byLayer[layer] = &key;
123 }
124 const int first = static_cast<int>(outputIndices.size());
125 uint32_t count = 0;
126 for (uint32_t layer = maxLayers; layer-- > 0;) {
127 const auto* reference = byLayer[layer];
128 if (reference == nullptr) {
129 continue;
130 }
131 uint32_t externalIndex = reference->clusterId;
132 if (externalIndicesBySurface != nullptr) {
133 if (reference->layer.value() >= externalIndicesBySurface->size() ||
134 reference->clusterId >= (*externalIndicesBySurface)[reference->layer.value()].size()) {
135 return false;
136 }
137 externalIndex = (*externalIndicesBySurface)[reference->layer.value()][reference->clusterId];
138 }
139 if (externalIndex > static_cast<uint32_t>(std::numeric_limits<int>::max())) {
140 return false;
141 }
142 if (clusterSizesBySurface == nullptr ||
143 reference->layer.value() >= clusterSizesBySurface->size() ||
144 reference->clusterId >= (*clusterSizesBySurface)[reference->layer.value()].size()) {
145 return false;
146 }
147 outputIndices.push_back(static_cast<int>(externalIndex));
148 output.setClusterSize(layer, (*clusterSizesBySurface)[reference->layer.value()][reference->clusterId]);
149 pattern |= 1u << layer;
150 ++count;
151 }
152 output.setClusterRefs(first, static_cast<int>(count));
153 return true;
154}
155
156std::optional<TrackOutput> stageTrackOutput(const TimeFrame& frame,
157 const TrackPublicationTimingContext& context,
158 gsl::span<const uint8_t> sharedClusterFlags,
159 bool withMC,
160 const std::vector<std::vector<uint32_t>>* externalIndicesBySurface = nullptr,
161 const std::vector<std::vector<uint32_t>>* clusterSizesBySurface = nullptr)
162{
163 auto selection = selectGenericTracksForSurfaces(frame, kLayerToLayout);
164 if (!selection) {
165 return std::nullopt;
166 }
167 if (withMC && frame.getTrackLabels().size() != frame.getGenericTracks().size()) {
168 return std::nullopt;
169 }
170 const auto ordered = makeLegacyOutputOrder(frame, std::move(*selection), context.clock);
171 if (!ordered) {
172 return std::nullopt;
173 }
174 TrackOutput staged;
175 staged.trackROFs.assign(context.inputROFs.begin(), context.inputROFs.end());
176 staged.tracks.reserve(ordered->size());
177 staged.labels.reserve(withMC ? ordered->size() : 0);
178 std::vector<o2::its::TimeStamp> times;
179 times.reserve(ordered->size());
180 for (const auto index : *ordered) {
181 o2::track::TrackParCovF inner, outer;
182 const auto& common = frame.getGenericTracks()[index];
183 const auto timestamp = makeOutputTimestamp(common.timestamp, context.clock);
184 if (!exportTrackState(common.innerState, inner) || !exportTrackState(common.outerState, outer)) {
185 return std::nullopt;
186 }
187 if (index >= sharedClusterFlags.size() || sharedClusterFlags[index] > 1) {
188 return std::nullopt;
189 }
190 o2::its::TrackITS output{inner, common.chi2, outer};
191 uint32_t pattern = 0;
192 if (!collectReferences(frame, common, staged.clusterIndices, output, pattern,
193 externalIndicesBySurface, clusterSizesBySurface)) {
194 return std::nullopt;
195 }
196 output.setPattern(pattern);
197 output.setSharedClusters(sharedClusterFlags[index] != 0);
198 output.getTimeStamp() = timestamp;
199 staged.tracks.push_back(std::move(output));
200 times.push_back(timestamp);
201 if (withMC) {
202 staged.labels.push_back(frame.getTrackLabels()[index]);
203 }
204 }
205 finalizeROFs(staged.trackROFs, times, context);
206 return staged;
207}
208
209bool completePublication(PublicationAdapter& publication,
210 const TimeFrame& frame,
211 const Tracker& tracker,
212 const TrackingStatistics& statistics)
213{
214 const auto configurations = tracker.getIterationConfigurations();
215 std::size_t firstTrack = 0;
216 for (std::size_t iteration = 0; iteration < configurations.size(); ++iteration) {
217 if (iteration >= statistics.acceptedTrackCounts.size() ||
218 statistics.acceptedTrackCounts[iteration] > frame.getGenericTracks().size() - firstTrack) {
219 return false;
220 }
221 std::vector<uint32_t> trackIndices(statistics.acceptedTrackCounts[iteration]);
222 std::iota(trackIndices.begin(), trackIndices.end(), static_cast<uint32_t>(firstTrack));
223 if (!publication.completeAccepted(trackIndices, configurations[iteration].parameters, frame, iteration + 1 == configurations.size())) {
224 return false;
225 }
226 firstTrack += statistics.acceptedTrackCounts[iteration];
227 }
228 return firstTrack == frame.getGenericTracks().size();
229}
230
231} // namespace
232
233CATrackerDPL::CATrackerDPL(std::shared_ptr<o2::base::GRPGeomRequest> gr, WorkflowOptions options)
234 : mGGCCDBRequest(std::move(gr)), mUseMC(options.useMC), mOptions(std::move(options))
235{
236}
237
238void CATrackerDPL::addTruthSeedingVertices(const o2::InteractionRecord& origin, gsl::span<const o2::itsmft::ROFRecord> rofs)
239{
240 if (rofs.empty()) {
241 return;
242 }
243 LOGP(info, "ITS CA using truth seeds as vertices");
244 const auto& clock = mSession.frame.getROFViews().overlap.getLayer(0);
245 const auto window = truthSeedingWindow(rofs, origin, clock);
246 if (!window) {
247 throw std::runtime_error("ITS CA truth seeding received invalid ROF timing");
248 }
249 const std::unique_ptr<o2::steer::DigitizationContext> dc{o2::steer::DigitizationContext::loadFromFile(mOptions.truthContext.c_str())};
250 if (!dc) {
251 throw std::runtime_error("ITS CA truth seeding could not load " + mOptions.truthContext);
252 }
253 const auto& irs = dc->getEventRecords();
254 o2::steer::MCKinematicsReader mcReader(dc.get());
255 constexpr int iSrc = 0;
256 const auto eveId2colId = dc->getCollisionIndicesForSource(iSrc);
257 std::vector<std::pair<o2::its::TimeEstBC, int>> selected;
258 for (int iEve = 0; iEve < mcReader.getNEvents(iSrc); ++iEve) {
259 const auto collision = eveId2colId.find(iEve);
260 if (collision == eveId2colId.end()) {
261 continue;
262 }
263 const auto timestamp = truthSeedingTime(irs.at(collision->second), origin, *window, clock.mROFLength / 2);
264 if (timestamp) {
265 selected.emplace_back(*timestamp, iEve);
266 }
267 }
268 // The ROF vertex lookup performs a binary search by lower timestamp.
269 std::sort(selected.begin(), selected.end(), [](const auto& a, const auto& b) {
270 return std::pair{a.first.lower(), a.second} < std::pair{b.first.lower(), b.second};
271 });
272 for (const auto& [timestamp, iEve] : selected) {
273 const auto& event = mcReader.getMCEventHeader(iSrc, iEve);
275 vertex.getTimeStamp() = timestamp;
276 vertex.setNContributors(std::max(1L, std::ranges::count_if(mcReader.getTracks(iSrc, iEve), [](const auto& track) {
277 if (!track.isPrimary() || track.GetPt() < 0.05 || std::abs(track.GetEta()) > 1.1) {
278 return false;
279 }
280 const auto* particle = o2::O2DatabasePDG::Instance()->GetParticle(track.GetPdgCode());
281 return particle && particle->Charge() != 0;
282 })));
283 vertex.setXYZ(static_cast<float>(event.GetX()), static_cast<float>(event.GetY()), static_cast<float>(event.GetZ()));
284 vertex.setChi2(1.f);
285 constexpr float covariance = 25.e-4f;
286 vertex.setSigmaX(covariance);
287 vertex.setSigmaY(covariance);
288 vertex.setSigmaZ(covariance);
289 mSession.frame.addPrimaryVertex(vertex);
290 const o2::MCCompLabel label{o2::MCCompLabel::maxTrackID(), iEve, iSrc, false};
291 mSession.frame.addPrimaryVertexLabel(o2::itsmft::tracking::VertexLabel{label, 1.f});
292 mcReader.releaseTracksForSourceAndEvent(iSrc, iEve);
293 }
294 LOGP(info, "ITS CA imposed {} pv collisions from MC truth", mSession.frame.getPrimaryVertices().size());
295}
296
297void CATrackerDPL::configureROFViews(gsl::span<const o2::itsmft::ROFRecord> rofs)
298{
299 const auto& detector = mSession.frame.getDetectorConfiguration();
301 const int nOrbitsPerTF = o2::base::GRPGeomHelper::getNHBFPerTF();
302 const auto timings = mSession.layerTimings(alpParams, nOrbitsPerTF, detector.addTimeError);
303 mSession.configureTiming(timings, [](int) { return true; });
304 (void)rofs;
305}
306
307void CATrackerDPL::initialiseTracking()
308{
309 const auto mode = mOptions.mode;
310 auto plan = o2::itsmft::TrackingMode::getTrackingPlan(o2::detectors::DetID::ITS, mode);
311 for (auto& pass : plan.iterations) {
312 pass.UseDiamond = mOptions.vertexSource == VertexSource::Diamond;
313 }
314 LOGP(info, "ITS CA tracker initialized in {} mode with {} iteration(s)",
315 o2::itsmft::TrackingMode::toString(mode), plan.iterations.size());
316 if (plan.iterations.empty()) {
317 return;
318 }
319
320 mTrackerTraits = std::make_unique<o2::itsmft::tracking::TrackerTraits>();
321 std::shared_ptr<tbb::task_arena> taskArena;
322 const auto& commonParams = o2::itsmft::ITSCommonCATrackerParam::Instance();
323 mTrackerTraits->setNThreads(mOptions.nThreads, taskArena);
324
325 const auto maxMemory = plan.execution.MaxMemory;
328 static_cast<uint32_t>(o2::itsmft::tracking::kITSSurfaces.size())},
329 .holeLayers = o2::itsmft::tracking::LayerMask{commonParams.holeLayerMask},
330 .plan = std::move(plan),
331 .memoryPool = std::make_shared<o2::itsmft::tracking::BoundedMemoryResource>(maxMemory)};
332
333 mTracker = std::make_unique<o2::itsmft::tracking::Tracker>();
334 if (!mTracker->initialize(mSession.frame, configuration)) {
335 LOGP(fatal, "ITS CA tracker failed to initialize static configuration");
336 }
337}
338
339bool CATrackerDPL::processTimeFrame(
340 gsl::span<const o2::itsmft::ROFRecord> rofs,
341 gsl::span<const o2::itsmft::CompClusterExt> clusters,
342 gsl::span<const unsigned char> patterns,
344{
345 if (!isActive()) {
346 LOGP(info, "ITS CA tracking mode is off, skipping TimeFrame processing");
347 return true;
348 }
349 mSession.frame.setBz(o2::base::Propagator::Instance()->getNominalBz());
352 source.detector = o2::detectors::DetID::ITS;
353 source.clusters = clusters;
354 source.patterns = patterns;
355 source.rofs = rofs;
356 source.dictionary = mDictionary;
357 source.labels = labels;
358 source.layerToSurface = kLayerToLayout;
359 return mSession.process(*mTracker, *mTrackerTraits, source, [&](const o2::InteractionRecord& origin) {
360 if (mOptions.vertexSource == VertexSource::Truth) {
361 addTruthSeedingVertices(origin, rofs);
362 mSession.vertices.update(mSession.frame.getPrimaryVertices().data(), mSession.frame.getPrimaryVertices().size());
363 } }, [&](const o2::itsmft::tracking::TrackingStatistics& statistics) {
364 if (!completePublication(mPublication, mSession.frame, *mTracker, statistics)) {
365 throw std::runtime_error{"failed to prepare ITS shared-cluster flags"};
366 } });
367}
368
369void CATrackerDPL::init(InitContext&)
370{
372}
373
374void CATrackerDPL::run(ProcessingContext& pc)
375{
376 auto publicationCleanup = mPublication.cleanupOnExit();
377 updateTimeDependentParams(pc);
378
379 auto rofsinput = pc.inputs().get<const std::vector<o2::itsmft::ROFRecord>>("ROframes");
380
381 if (decideCATrackerPublicationAction(isActive(), true) == CATrackerPublicationAction::PublishInactiveEmpty) {
382 pc.outputs().make<std::vector<o2::itsmft::ROFRecord>>(Output{"ITS", "ITSTrackROF", 0},
383 rofsinput.begin(), rofsinput.end());
384 pc.outputs().make<std::vector<o2::its::TrackITS>>(Output{"ITS", "TRACKS", 0});
385 pc.outputs().make<std::vector<int>>(Output{"ITS", "TRACKCLSID", 0});
386 return;
387 }
388
389 auto compClusters = pc.inputs().get<const std::vector<o2::itsmft::CompClusterExt>>("compClusters");
390 gsl::span<const unsigned char> patterns = pc.inputs().get<gsl::span<unsigned char>>("patterns");
391
393 if (mUseMC && pc.inputs().getPos("labels") >= 0) {
394 labels = pc.inputs().get<const dataformats::MCTruthContainer<MCCompLabel>*>("labels").release();
395 }
396
397 LOGP(info, "ITS CA input pulled {} compressed clusters in {} RO frames ({} pattern bytes)",
398 compClusters.size(), rofsinput.size(), patterns.size());
399
400 auto cleanup = mSession.cleanupOnExit();
401 configureROFViews(gsl::span<const o2::itsmft::ROFRecord>(rofsinput.data(), rofsinput.size()));
402 const auto trackingSucceeded = processTimeFrame(gsl::span<const o2::itsmft::ROFRecord>(rofsinput.data(), rofsinput.size()),
403 gsl::span<const o2::itsmft::CompClusterExt>(compClusters.data(), compClusters.size()),
404 patterns, labels);
405
406 if (decideCATrackerPublicationAction(isActive(), trackingSucceeded) == CATrackerPublicationAction::SkipDroppedTimeFrame) {
407 LOGP(error, "ITS CA tracking dropped this TimeFrame ({} ROFs, {} clusters); publishing nothing and continuing with the next TimeFrame",
408 rofsinput.size(), compClusters.size());
409 cleanup.frameAlreadyReset();
410 return;
411 }
412
413 {
415 gsl::span<const o2::itsmft::ROFRecord>{rofsinput.data(), rofsinput.size()}, mSession.overlap.getView().getClockLayer()};
416 const auto staged = stageTrackOutput(mSession.frame, context, mPublication.sharedClusterFlags(), mUseMC,
417 &mSession.externalIndices, &mSession.clusterSizes);
418 if (!staged) {
419 throw std::runtime_error{"ITS GenericTrack output staging failed"};
420 }
421
423 Output{"ITS", "TRACKS", 0}, Output{"ITS", "TRACKCLSID", 0}, *staged);
424 LOGP(info, "ITS CA pushed {} tracks in {} ROFs", staged->tracks.size(), staged->trackROFs.size());
425 if (mUseMC) {
426 pc.outputs().snapshot(Output{"ITS", "TRACKSMCTR", 0}, staged->labels);
427 LOGP(info, "ITS CA pushed {} track MC labels", staged->labels.size());
428 }
429 }
430}
431
432void CATrackerDPL::updateTimeDependentParams(ProcessingContext& pc)
433{
436 if (!mTrackingInitialised) {
437 mTrackingInitialised = true;
438 initialiseTracking();
439 }
440 static bool initOnceDone = false;
441 if (!initOnceDone) {
442 initOnceDone = true;
443 if (pc.inputs().getPos("itsTGeo") >= 0) {
444 pc.inputs().get<o2::its::GeometryTGeo*>("itsTGeo");
445 }
446 pc.inputs().get<o2::itsmft::TopologyDictionary*>("itscldict");
447 o2::its::GeometryTGeo::Instance()->fillMatrixCache(o2::math_utils::bit2Mask(o2::math_utils::TransformType::T2L,
448 o2::math_utils::TransformType::T2GRot,
449 o2::math_utils::TransformType::T2G));
450 }
451}
452
453void CATrackerDPL::finaliseCCDB(ConcreteDataMatcher& matcher, void* obj)
454{
455 if (o2::base::GRPGeomHelper::instance().finaliseCCDB(matcher, obj)) {
456 return;
457 }
458 if (matcher == ConcreteDataMatcher("ITS", "CLUSDICT", 0)) {
459 LOG(info) << "ITS CA input cluster dictionary updated";
460 mDictionary = static_cast<const o2::itsmft::TopologyDictionary*>(obj);
461 return;
462 }
463 if (matcher == ConcreteDataMatcher("ITS", "ALPIDEPARAM", 0)) {
464 LOG(info) << "ITS CA input Alpide param updated";
466 return;
467 }
468 if (matcher == ConcreteDataMatcher("ITS", "GEOMTGEO", 0)) {
469 LOG(info) << "ITS CA input GeometryTGeo loaded from CCDB";
471 o2::its::GeometryTGeo::Instance()->fillMatrixCache(o2::math_utils::bit2Mask(o2::math_utils::TransformType::T2L,
472 o2::math_utils::TransformType::T2GRot,
473 o2::math_utils::TransformType::T2G));
474 // The catalog has static process lifetime; geometry adoption remains
475 // necessary for raw cluster decoding.
476 return;
477 }
478}
479
481{
482 const bool useMC = options.useMC;
483 const bool useGeom = options.useFullGeometry;
484 std::vector<InputSpec> inputs;
485 inputs.emplace_back("compClusters", "ITS", "COMPCLUSTERS", 0, Lifetime::Timeframe);
486 inputs.emplace_back("patterns", "ITS", "PATTERNS", 0, Lifetime::Timeframe);
487 inputs.emplace_back("ROframes", "ITS", "CLUSTERSROF", 0, Lifetime::Timeframe);
488 inputs.emplace_back("itscldict", "ITS", "CLUSDICT", 0, Lifetime::Condition, ccdbParamSpec("ITS/Calib/ClusterDictionary"));
489 inputs.emplace_back("itsalppar", "ITS", "ALPIDEPARAM", 0, Lifetime::Condition, ccdbParamSpec("ITS/Config/AlpideParam"));
490
491 if (useMC) {
492 inputs.emplace_back("labels", "ITS", "CLUSTERSMCTR", 0, Lifetime::Timeframe);
493 }
494
495 auto ggRequest = std::make_shared<o2::base::GRPGeomRequest>(false,
496 true,
497 false,
498 true,
499 true,
501 inputs,
502 true);
503 if (!useGeom) {
504 ggRequest->addInput({"itsTGeo", "ITS", "GEOMTGEO", 0, Lifetime::Condition, framework::ccdbParamSpec("ITS/Config/Geometry")}, inputs);
505 }
506
507 std::vector<OutputSpec> outputs;
508 outputs.emplace_back("ITS", "TRACKS", 0, Lifetime::Timeframe);
509 outputs.emplace_back("ITS", "TRACKCLSID", 0, Lifetime::Timeframe);
510 outputs.emplace_back("ITS", "ITSTrackROF", 0, Lifetime::Timeframe);
511 if (useMC) {
512 outputs.emplace_back("ITS", "TRACKSMCTR", 0, Lifetime::Timeframe);
513 }
514
515 return DataProcessorSpec{
516 "its-ca-tracker",
517 inputs,
518 outputs,
519 AlgorithmSpec{adaptFromTask<CATrackerDPL>(ggRequest, options)},
520 Options{}};
521}
522
523} // namespace o2::its::ca
header::DataOrigin origin
std::vector< unsigned long > times
Definition of the ITSMFT compact cluster.
Definition of the ClusterTopology class.
Definition of the GeometryManager class.
uint64_t vertex
Definition RawEventData.h:9
int32_t i
Definition of the GeometryTGeo class.
Definition of the ITSMFT ROFrame (trigger) record.
Shared cluster I/O utilities for ITS and MFT (based on ITStracking/IOUtils.h)
Tracker orchestrator.
ITS common-CA tracker DPL device with tracker-only outputs.
std::vector< o2::itsmft::ROFRecord > trackROFs
std::vector< int > clusterIndices
std::vector< o2::MCCompLabel > labels
std::vector< o2::its::TrackITS > tracks
Header to collect LHC related constants.
void output(const std::map< std::string, ChannelStat > &channels)
Definition rawdump.cxx:197
Definition of a container to keep Monte Carlo truth external to simulation objects.
Definition of the ITS track.
StringRef key
static constexpr int maxTrackID()
static TDatabasePDG * Instance()
void checkUpdates(o2::framework::ProcessingContext &pc)
static GRPGeomHelper & instance()
void setRequest(std::shared_ptr< GRPGeomRequest > req)
GPUd() value_type estimateLTFast(o2 static GPUd() float estimateLTIncrement(const o2 PropagatorImpl * Instance(bool uninitialized=false)
Definition Propagator.h:180
A container to hold and manage MC truth information/labels.
void snapshot(const Output &spec, T const &object)
decltype(auto) make(const Output &spec, Args... args)
int getPos(const char *name) const
decltype(auto) get(R binding, int part=0) const
DataAllocator & outputs()
The data allocator is used to allocate memory for the output data.
InputRecord & inputs()
The inputs associated with this processing context.
static GeometryTGeo * Instance()
void fillMatrixCache(int mask) override
static void adopt(GeometryTGeo *raw, bool canDelete=false)
CATrackerDPL(std::shared_ptr< o2::base::GRPGeomRequest > gr, WorkflowOptions options)
gsl::span< const IterationConfiguration > getIterationConfigurations() const noexcept
Definition Tracker.h:64
static DigitizationContext * loadFromFile(std::string_view filename="")
struct _cl_event * event
Definition glcorearb.h:2982
GLenum mode
Definition glcorearb.h:266
GLint GLsizei count
Definition glcorearb.h:399
GLuint index
Definition glcorearb.h:781
GLint first
Definition glcorearb.h:399
GLboolean GLboolean GLboolean b
Definition glcorearb.h:1233
GLsizei GLsizei GLchar * source
Definition glcorearb.h:798
GLint reference
Definition glcorearb.h:5487
GLuint GLsizei const GLchar * label
Definition glcorearb.h:2519
typedef void(APIENTRYP PFNGLCULLFACEPROC)(GLenum mode)
GLenum GLuint GLint GLint layer
Definition glcorearb.h:1310
GLboolean GLboolean GLboolean GLboolean a
Definition glcorearb.h:1233
GLint ref
Definition glcorearb.h:291
std::string timestamp() noexcept
Definition Clock.h:84
Defining ITS Vertex explicitly as messageable.
Definition Cartesian.h:288
std::vector< ConfigParamSpec > ccdbParamSpec(std::string const &path, int runDependent, std::vector< CCDBMetadata > metadata={}, int qrate=0)
std::vector< ConfigParamSpec > Options
std::optional< o2::its::TimeEstBC > truthSeedingWindow(gsl::span< const o2::itsmft::ROFRecord > rofs, const o2::InteractionRecord &origin, const o2::its::LayerTiming &timing) noexcept
std::optional< o2::its::TimeEstBC > truthSeedingTime(const o2::InteractionRecord &collision, const o2::InteractionRecord &origin, const o2::its::TimeEstBC &window, uint32_t duration) noexcept
o2::framework::DataProcessorSpec getCATrackerSpec(const WorkflowOptions &options)
const bool const int TrackITSInternal< NLayers > & track
std::string toString(Type mode)
TrackingPlan getTrackingPlan(o2::detectors::DetID::ID detId, Type mode)
void copyTrackingOutputColumns(Allocator &outputs, Output rofs, Output tracks, Output indices, const Staged &staged)
std::optional< std::vector< uint32_t > > selectGenericTracksForSurfaces(const TimeFrame &frame, gsl::span< const LayerId > sourceSurfaces)
o2::its::VertexLabel VertexLabel
Definition TimeFrame.h:48
o2::its::TimeStamp makeOutputTimestamp(o2::its::TimeStamp timestamp, const o2::its::LayerTiming &clock) noexcept
constexpr std::array< SurfaceDescriptor, ITSNLayers > kITSSurfaces
constexpr int ITSNLayers
ITS CA layer count.
void finalizeROFs(std::vector< o2::itsmft::ROFRecord > &rofs, const std::vector< o2::its::TimeStamp > &times, const TrackPublicationTimingContext &context)
CATrackerPublicationAction decideCATrackerPublicationAction(bool active, bool success) noexcept
std::optional< std::vector< uint32_t > > makeLegacyOutputOrder(const TimeFrame &frame, std::vector< uint32_t > selection, const o2::its::LayerTiming &clock)
bool isActive(const Node< T > &node)
TrackParametrizationWithError< float > TrackParCovF
Definition Track.h:31
struct o2::upgrades_utils::@470 collision
void cleanup()
RuntimeROFOverlapView overlap
Definition ROFViews.h:374
const RuntimeROFViews & getROFViews() const noexcept
Definition TimeFrame.h:128
gsl::span< const o2::itsmft::ROFRecord > inputROFs
std::vector< std::size_t > acceptedTrackCounts
Definition Tracker.h:45
LOG(info)<< "Compressed in "<< sw.CpuTime()<< " s"
std::vector< Cluster > clusters
std::array< uint16_t, 5 > pattern