Project
Loading...
Searching...
No Matches
ROframe.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.
15
16
#include "
ITStracking/ROframe.h
"
17
18
#include <iostream>
19
20
namespace
o2
21
{
22
namespace
its
23
{
24
25
ROframe::ROframe
(
int
ROframeId,
int
nLayers) : mROframeId{ROframeId}
26
{
27
mClusters.resize(nLayers);
28
mTrackingFrameInfo.resize(nLayers);
29
// mClusterLabels.resize(nLayers);
30
mClusterExternalIndices.resize(nLayers);
31
}
32
33
void
ROframe::addPrimaryVertex
(
const
float
xCoordinate,
const
float
yCoordinate,
const
float
zCoordinate)
34
{
35
mPrimaryVertices.emplace_back(
float3
{xCoordinate, yCoordinate, zCoordinate});
36
}
37
38
void
ROframe::addPrimaryVertices
(std::vector<Vertex> vertices)
39
{
40
for
(
Vertex
&
vertex
: vertices) {
41
mPrimaryVertices.emplace_back(
float3
{
vertex
.getX(),
vertex
.getY(),
vertex
.getZ()});
42
}
43
}
44
45
void
ROframe::printPrimaryVertices
()
const
46
{
47
const
int
verticesNum{
static_cast<
int
>
(mPrimaryVertices.size())};
48
49
for
(
int
iVertex{0}; iVertex < verticesNum; ++iVertex) {
50
51
const
float3
& currentVertex = mPrimaryVertices[iVertex];
52
std::cout <<
"-1\t"
<< currentVertex.
x
<<
"\t"
<< currentVertex.
y
<<
"\t"
<< currentVertex.
z
<< std::endl;
53
}
54
}
55
56
int
ROframe::getTotalClusters
()
const
57
{
58
size_t
totalClusters{0};
59
for
(
auto
&
clusters
: mClusters) {
60
totalClusters +=
clusters
.size();
61
}
62
return
int
(totalClusters);
63
}
64
}
// namespace its
65
}
// namespace o2
vertex
uint64_t vertex
Definition
RawEventData.h:9
ROframe.h
int
o2::dataformats::Vertex
Definition
Vertex.h:122
o2::its::ROframe::ROframe
ROframe(int ROframeId, int nLayers)
Definition
ROframe.cxx:25
o2::its::ROframe::getTotalClusters
int getTotalClusters() const
Definition
ROframe.cxx:56
o2::its::ROframe::addPrimaryVertex
void addPrimaryVertex(const float, const float, const float)
Definition
ROframe.cxx:33
o2::its::ROframe::addPrimaryVertices
void addPrimaryVertices(std::vector< Vertex > vertices)
Definition
ROframe.cxx:38
o2::its::ROframe::printPrimaryVertices
void printPrimaryVertices() const
Definition
ROframe.cxx:45
o2
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
Definition
BitstreamReader.h:24
float3
Definition
GPUCommonDefAPI.h:63
float3::z
float z
Definition
GPUCommonDefAPI.h:63
float3::y
float y
Definition
GPUCommonDefAPI.h:63
float3::x
float x
Definition
GPUCommonDefAPI.h:63
clusters
std::vector< Cluster > clusters
Definition
test_ctf_io_cpv.cxx:41
Detectors
ITSMFT
ITS
tracking
src
ROframe.cxx
Generated on Tue Feb 25 2025 23:16:20 for Project by
1.9.8