ATLAS Offline Software
Loading...
Searching...
No Matches
EFTrackingTransient.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
14
15#ifndef EFTRACKING_FPGA_INTEGRATION_EFTRACKING_TRANSIENT_H
16#define EFTRACKING_FPGA_INTEGRATION_EFTRACKING_TRANSIENT_H
17
18#include <vector>
19
21
23{
24 // The struct of the StripCluster and PixelCluster are not aligned at the moment
25 // They might be aligned in the future for efficient device memory usage
26
27 constexpr uint32_t MAX_PIXEL_CLUSTERS = 326400;
28 constexpr uint32_t MAX_STRIP_CLUSTERS = 307200;
29 constexpr uint16_t CLUSTER_SEG_SIZE = 256;
30 constexpr uint8_t NUM_PIXEL_WORDS = 10;
31 constexpr uint8_t NUM_STRIP_WORDS = 9;
32 constexpr uint8_t NUM_PIXEL_FIELDS = 17;
33 constexpr uint8_t NUM_STRIP_FIELDS = 11;
34 constexpr uint8_t NUM_PIXEL_ROWS = 22;
35 constexpr uint8_t NUM_STRIP_ROWS = 14;
36 constexpr uint32_t PIXEL_BLOCK_BUF_SIZE = (NUM_PIXEL_WORDS*MAX_PIXEL_CLUSTERS/1024+1)*1024; // align to 1024*sizeof(uint32_t)=4096
37 constexpr uint32_t STRIP_BLOCK_BUF_SIZE = (NUM_STRIP_WORDS*MAX_STRIP_CLUSTERS/1024+1)*1024;
38 constexpr uint32_t PIXEL_CONTAINER_BUF_SIZE = ((NUM_PIXEL_ROWS*MAX_PIXEL_CLUSTERS+16)/1024+1)*1024; // +16: for cluster number word
39 constexpr uint32_t STRIP_CONTAINER_BUF_SIZE = ((NUM_STRIP_ROWS*MAX_STRIP_CLUSTERS+16)/1024+1)*1024;
40
41
42
43 constexpr unsigned int MAX_NUM_CLUSTERS = 409600;
44 constexpr unsigned int NUM_MAXCLUSTER_WORD_INTRACK = 13;
45 constexpr unsigned int MAX_TRACK = 1000;
46
48
49
50 // Optimize these,
51 constexpr unsigned int MAX_NUM_INPUTCLUSTERS = 409600;
52 constexpr unsigned int NUM_MAXINPUT_PIXEL_ROW = 3;
53 constexpr unsigned int NUM_MAXINPUT_STRIP_ROW = 2;
56
64 {
65 float localPosition = 0.0f;
66 float localCovariance = 0.0f;
67 unsigned int idHash = 0;
68 long unsigned int id = 0;
69 float globalPosition[3] = {0.0f, 0.0f, 0.0f};
70 unsigned long long rdoList[1000] = {0};
73 };
74
82 {
83 long unsigned int id = 0;
84 unsigned int idHash = 0;
85 float localPosition[2] = {0.0f, 0.0f};
86 float localCovariance[2] = {0.0f, 0.0f};
87 float globalPosition[3] = {0.0f, 0.0f, 0.0f};
88 unsigned long long rdoList[1000] = {0};
91 float widthInEta = 0.0f;
92 int totList[1000] = {0};
93 int totalToT = 0;
94 float chargeList[1000] = {0.0f};
95 float totalCharge = 0.0f;
96 float energyLoss = 0.0f;
97 char isSplit = 0;
98 float splitProbability1 = 0.0f;
99 float splitProbability2 = 0.0f;
100 int lvl1a = 0;
104 };
105
113 {
114
115 unsigned int idHash[2] = {0};
116 float globalPosition[3] = {0.0f, 0.0f, 0.0f};
117 float radius = 0.0f;
118 float cov_r = 0.0f;
119 float cov_z = 0.0f;
120 int measurementIndex[100] = {0};
121 // Strip
122 float topHalfStripLength = 0.0f;
124 float topStripDirection[3] = {0.0f, 0.0f, 0.0f};
125 float bottomStripDirection[3] = {0.0f, 0.0f, 0.0f};
126 float stripCenterDistance[3] = {0.0f, 0.0f, 0.0f};
127 float topStripCenter[3] = {0.0f, 0.0f, 0.0f};
128 };
129
135 struct Metadata
136 {
137 unsigned long numOfStripClusters = 0;
138 unsigned long numOfPixelClusters = 0;
139 unsigned long numOfStripSpacePoints = 0;
140 unsigned int numOfPixelSpacePoints = 0;
141 unsigned int scRdoIndex[500000] = {0};
142 unsigned int pcRdoIndex[500000] = {0};
143 unsigned int pcTotIndex[500000] = {0};
144 unsigned int pcChargeIndex[500000] = {0};
145 unsigned int pcRdoIndexSize = 0;
146 unsigned int scRdoIndexSize = 0;
147 unsigned int pcTotIndexSize = 0;
148 unsigned int pcChargeIndexSize = 0;
149 };
150
156 {
157
160 unsigned int *scIdHash;
161 long unsigned int *scId;
163 unsigned long long *scRdoList;
165 };
166
193
199
217
223 {
224 std::vector<float> localPosition;
225 std::vector<float> localCovariance;
226 std::vector<unsigned int> idHash;
227 std::vector<long unsigned int> id;
228 std::vector<float> globalPosition;
229 std::vector<unsigned long long> rdoList;
230 std::vector<int> channelsInPhi;
231 };
232
238 {
239 std::vector<long unsigned int> id;
240 std::vector<unsigned int> idHash;
241 std::vector<float> localPosition;
242 std::vector<float> localCovariance;
243 std::vector<float> globalPosition;
244 std::vector<unsigned long long> rdoList;
245 std::vector<int> channelsInPhi;
246 std::vector<int> channelsInEta;
247 std::vector<float> widthInEta;
248 std::vector<int> totList;
249 std::vector<int> totalToT;
250 std::vector<float> chargeList;
251 std::vector<float> totalCharge;
252 std::vector<float> energyLoss;
253 std::vector<char> isSplit;
254 std::vector<float> splitProbability1;
255 std::vector<float> splitProbability2;
256 std::vector<int> lvl1a;
257 std::vector<int> sizeOfRDOList;
258 std::vector<int> sizeOfTotList;
259 std::vector<int> sizeOfChargeList;
260 };
261
266 {
267 std::vector<unsigned int> elementIdList;
268 std::vector<float> globalPosition;
269 std::vector<float> radius;
270 std::vector<float> varianceR;
271 std::vector<float> varianceZ;
272 std::vector<float> topHalfStripLength;
273 std::vector<float> bottomHalfStripLength;
274 std::vector<float> topStripDirection;
275 std::vector<float> bottomStripDirection;
276 std::vector<float> stripCenterDistance;
277 std::vector<float> topStripCenter;
278 std::vector<int> measurementIndexes;
279 };
280
281} // namespace EFTrackingDataTransient
282
283#endif // EFTRACKING_FPGA_INTEGRATION_EFTRACKING_TRANSIENT_H
constexpr uint32_t MAX_PIXEL_CLUSTERS
constexpr uint8_t NUM_STRIP_FIELDS
constexpr uint8_t NUM_STRIP_WORDS
constexpr unsigned long PIXEL_CONTAINER_INPUT_BUF_SIZE
constexpr unsigned int NUM_MAXINPUT_PIXEL_ROW
constexpr unsigned int NUM_MAXCLUSTER_WORD_INTRACK
constexpr uint8_t NUM_STRIP_ROWS
constexpr uint8_t NUM_PIXEL_WORDS
constexpr unsigned int MAX_NUM_CLUSTERS
constexpr uint16_t CLUSTER_SEG_SIZE
constexpr unsigned int MAX_TRACK
constexpr unsigned int NUM_MAXINPUT_STRIP_ROW
constexpr uint32_t STRIP_CONTAINER_BUF_SIZE
constexpr unsigned int MAX_NUM_INPUTCLUSTERS
constexpr uint8_t NUM_PIXEL_FIELDS
constexpr unsigned long STRIP_CONTAINER_INPUT_BUF_SIZE
constexpr uint32_t MAX_STRIP_CLUSTERS
constexpr uint32_t STRIP_BLOCK_BUF_SIZE
constexpr uint8_t NUM_PIXEL_ROWS
constexpr uint32_t PIXEL_BLOCK_BUF_SIZE
constexpr unsigned long TRACK_CONTAINER_BUF_SIZE
constexpr uint32_t PIXEL_CONTAINER_BUF_SIZE
The structure of the Metadata containing data after clusterization.
The PixelClusterAuxInput struct is used to simplify the creaction of the xAOD::PixelClusterContainer.
std::vector< unsigned long long > rdoList
The PixelClusters struct contains the output arrays from the FPGA.
The PixelClusters struct contains all xAOD::PixelCluster data members.
The SpacePointAuxInput struct is used to simplify the creaction of the xAOD::SpacePointContainer.
The Pixel/Strip SpacePoints struct contains the output arrays from the FPGA.
The SpacePoint struct contains all xAOD::SpacePoint data members.
The StripClusterAuxInput struct is used to simplify the creaction of the xAOD::StripClusterContainer.
std::vector< unsigned long long > rdoList
The StripClusters struct contains the output arrays from the FPGA.
The StripClusters struct contains all xAOD::StripCluster data members.