ATLAS Offline Software
TestVectorTool.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3 */
4 
14 #include <fstream>
15 
17 {
18  ATH_MSG_INFO("Initializing TestVectorTool tool");
19 
20  return StatusCode::SUCCESS;
21 }
22 
23 StatusCode TestVectorTool::prepareTV(const std::string &inputFile, std::vector<uint64_t> &testVector) const
24 {
25  ATH_MSG_DEBUG("Preparing input test vector from " << inputFile);
26 
27  // Check if the input file ends with .txt or .bin
28  if (inputFile.find(".txt") == std::string::npos && inputFile.find(".bin") == std::string::npos)
29  {
30  ATH_MSG_ERROR("Input TV file must be either .txt or .bin");
31  return StatusCode::FAILURE;
32  }
33 
34  // clear the test vector before reading
35  testVector.clear();
36 
37  // if .txt
38  if (inputFile.find(".txt") != std::string::npos)
39  {
40  std::ifstream file(inputFile, std::ios::in);
41  if (!file.is_open())
42  {
43  ATH_MSG_ERROR("Cannot open file " << inputFile);
44  return StatusCode::FAILURE;
45  }
46 
47  uint64_t cache;
48  while (file >> std::hex >> cache)
49  {
50  testVector.push_back(cache);
51  }
52 
53  // close the file
54  file.close();
55  }
56  else
57  {
58  std::ifstream file(inputFile, std::ios::binary);
59  if (!file.is_open())
60  {
61  ATH_MSG_ERROR("Cannot open input TV file " << inputFile);
62  return StatusCode::FAILURE;
63  }
64 
65  uint64_t cache;
66  while (file.read(reinterpret_cast<char *>(&cache), sizeof(uint64_t)))
67  {
68  // Reverse the byte order
69  cache = __builtin_bswap64(cache);
70  testVector.push_back(cache);
71  }
72 
73  // close the file
74  file.close();
75  }
76 
77  return StatusCode::SUCCESS;
78 }
79 
80 StatusCode TestVectorTool::compare(const std::vector<uint64_t> &tv_1, const std::vector<uint64_t> &tv_2) const
81 {
82  ATH_MSG_DEBUG("Comparing two test vectors");
83 
84  std::vector<uint64_t>::size_type size = -1;
85 
86  if (tv_1.size() != tv_2.size())
87  {
88  ATH_MSG_WARNING("The two test vectors have different sizes: " << tv_1.size() << " and " << tv_2.size());
89  // Use the shorter one for comparison
90  size = tv_1.size() < tv_2.size() ? tv_1.size() : tv_2.size();
91  }
92  else
93  {
94  ATH_MSG_DEBUG("The two test vectors have the same size: " << tv_1.size());
95  size = tv_1.size();
96  }
97 
98  bool pass = true;
99  for (std::vector<uint64_t>::size_type i = 0; i < size; i++)
100  {
101  if (tv_1[i] != tv_2[i])
102  {
103  ATH_MSG_DEBUG("The two test vectors are different at index " << i);
104  pass = false;
105  }
106  }
107 
108  if (pass)
109  {
110  ATH_MSG_DEBUG("The two test vectors are the same");
111  }
112  else
113  {
114  ATH_MSG_WARNING("The two test vectors are different!");
115  }
116 
117  return StatusCode::SUCCESS;
118 }
119 
120 StatusCode TestVectorTool::compare(const EFTrackingFPGAIntegration::TVHolder &tvHolder, const std::vector<uint64_t> &tv_comp) const
121 {
122  ATH_MSG_DEBUG("Comparing the FPGA output to the reference vector for " << tvHolder.name);
123 
124  std::vector<uint64_t>::size_type size = -1;
125 
126  if (tvHolder.refTV.size() != tv_comp.size())
127  {
128  ATH_MSG_WARNING("The two test vectors have different sizes: " << tvHolder.refTV.size() << " and " << tv_comp.size());
129  // Use the shorter one for comparison
130  size = tvHolder.refTV.size() < tv_comp.size() ? tvHolder.refTV.size() : tv_comp.size();
131  }
132  else
133  {
134  ATH_MSG_DEBUG("The two test vectors have the same size: " << tvHolder.refTV.size());
135  size = tvHolder.refTV.size();
136  }
137 
138  bool pass = true;
139  for (std::vector<uint64_t>::size_type i = 0; i < size; i++)
140  {
141  if (tvHolder.refTV[i] != tv_comp[i])
142  {
143  ATH_MSG_DEBUG("The two test vectors are different at index " << i);
144  pass = false;
145  }
146  }
147 
148  if (pass)
149  {
150  ATH_MSG_DEBUG(tvHolder.name << " FPGA output matches the reference vector");
151  }
152  else
153  {
154  ATH_MSG_WARNING(tvHolder.name << " FPGA output does not match the reference vector");
155  }
156 
157  return StatusCode::SUCCESS;
158 }
159 
160 StatusCode TestVectorTool::encodePixelL2G(const xAOD::PixelClusterContainer *pixelClusters, std::vector<uint64_t> &encodedData) const
161 {
162  ATH_MSG_DEBUG("Encoding xAOD pixel clusters to L2G EDM TV");
163 
164  // Fill the event header
165  // Event header w1
167  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EVT_HDR_w1(header_w1));
168 
169  // Event header w2
170  auto header_w2 = FPGADataFormatUtilities::fill_EVT_HDR_w2(242000, 0);
171  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EVT_HDR_w2(header_w2));
172 
173  // Event header w3
174  auto header_w3 = FPGADataFormatUtilities::fill_EVT_HDR_w3(0, 0);
175  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EVT_HDR_w3(header_w3));
176 
177  // L2G conetent
178  // Loop over the pixel clusters
179  unsigned int isLast = 0;
180  for (unsigned int i = 0; i < pixelClusters->size(); i++)
181  {
182  // Pixel cluster w1
184  pixelClusters->at(i)->identifierHash(),
185  0);
186  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w1(pixelCluster_w1));
187 
188 
189 
190  // Determine the size of rdo list and retrieve accordingly
191  uint64_t rdoList[4] = {0, 0, 0, 0}; // Current dataformat only supports 4 RDOs
192 
193  unsigned int rdoListSize = pixelClusters->at(i)->rdoList().size();
194  rdoListSize = rdoListSize > 4 ? 4 : rdoListSize; // restrict to 4 RDOs if more
195  for (unsigned int j = 0; j < rdoListSize; j++)
196  {
197  rdoList[j] = pixelClusters->at(i)->rdoList().at(j).get_compact();
198  }
199 
200  // Pixel cluster w2
201  auto pixelCluster_w2 = FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w2(rdoList[0]);
202  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w2(pixelCluster_w2));
203 
204  // Pixel cluster w3
205  auto pixelCluster_w3 = FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w3(rdoList[1]);
206  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w3(pixelCluster_w3));
207 
208  // Pixel cluster w4
209  auto pixelCluster_w4 = FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w4(rdoList[2]);
210  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w4(pixelCluster_w4));
211 
212  // Pixel cluster w5
213  auto pixelCluster_w5 = FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w5(rdoList[3]);
214  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w5(pixelCluster_w5));
215 
216  // Pixel cluster w6
217  auto pixelCluster_w6 = FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w6(pixelClusters->at(i)->localPosition<2>()(0, 0),
218  pixelClusters->at(i)->localPosition<2>()(1, 0),
219  pixelClusters->at(i)->channelsInPhi(),
220  pixelClusters->at(i)->channelsInEta(),
221  pixelClusters->at(i)->widthInEta()
222  );
223  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w6(pixelCluster_w6));
224 
225  // Pixel cluster w7
226  auto pixelCluster_w7 = FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w7(pixelClusters->at(i)->localCovariance<2>()(0, 0),
227  pixelClusters->at(i)->localCovariance<2>()(1, 1),
228  0,
229  0
230  );
231  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w7(pixelCluster_w7));
232 
233  // Pixel cluster w8
234  auto pixelCluster_w8 = FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w8(pixelClusters->at(i)->globalPosition()[0],
235  pixelClusters->at(i)->globalPosition()[1],
236  0);
237  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w8(pixelCluster_w8));
238 
239  // Pixel cluster w9
240  auto pixelCluster_w9 = FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w9(pixelClusters->at(i)->identifier());
241  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w9(pixelCluster_w9));
242 
243  // Pixel cluster w10
244  isLast = i == (pixelClusters->size() - 1) ? 1 : 0;
245  auto pixelCluster_w10 = FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w10(pixelClusters->at(i)->globalPosition()[2],
246  pixelClusters->at(i)->totalToT(),
247  isLast,
248  0);
249  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w10(pixelCluster_w10));
250  }
251 
252  // Fill the event footer
253  // Event footer w1
255  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EVT_FTR_w1(footer_w1));
256 
257  // Event footer w2
258  auto footer_w2 = FPGADataFormatUtilities::fill_EVT_FTR_w2(0);
259  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EVT_FTR_w2(footer_w2));
260 
261  // Event footer w3
262  auto footer_w3 = FPGADataFormatUtilities::fill_EVT_FTR_w3(encodedData.size(), 44939973);
263  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EVT_FTR_w3(footer_w3));
264 
265  return StatusCode::SUCCESS;
266 }
267 
268 StatusCode TestVectorTool::encodeStripL2G(const xAOD::StripClusterContainer *stripClusters, std::vector<uint64_t> &encodedData) const
269 {
270  ATH_MSG_DEBUG("Encoding xAOD strip clusters to L2G EDM TV");
271 
272  // Fill the event header
273  // Event header w1
275  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EVT_HDR_w1(header_w1));
276 
277  // Event header w2
278  auto header_w2 = FPGADataFormatUtilities::fill_EVT_HDR_w2(242000, 0);
279  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EVT_HDR_w2(header_w2));
280 
281  // Event header w3
282  auto header_w3 = FPGADataFormatUtilities::fill_EVT_HDR_w3(0, 0);
283  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EVT_HDR_w3(header_w3));
284 
285  // L2G conetent
286  // Loop over the strip clusters
287  unsigned int isLast = 0;
288  for (unsigned int i = 0; i < stripClusters->size(); i++)
289  {
290  // Strip cluster w1
292  stripClusters->at(i)->identifierHash(),
293  0);
294  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w1(stripCluster_w1));
295 
296 
297 
298  // Determine the size of rdo list and retrieve accordingly
299  uint64_t rdoList[4] = {0, 0, 0, 0}; // Current dataformat only supports 4 RDOs
300 
301  unsigned int rdoListSize = stripClusters->at(i)->rdoList().size();
302  rdoListSize = rdoListSize > 4 ? 4 : rdoListSize; // restrict to 4 RDOs if more
303  for (unsigned int j = 0; j < rdoListSize; j++)
304  {
305  rdoList[j] = stripClusters->at(i)->rdoList().at(j).get_compact();
306  }
307 
308  // Strip cluster w3
309  auto stripCluster_w2 = FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w2(rdoList[0]);
310  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w2(stripCluster_w2));
311 
312  // Strip cluster w3
313  auto stripCluster_w3 = FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w3(rdoList[1]);
314  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w3(stripCluster_w3));
315 
316  // Strip cluster w4
317  auto stripCluster_w4 = FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w4(rdoList[2]);
318  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w4(stripCluster_w4));
319 
320  // Strip cluster w5
321  auto stripCluster_w5 = FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w5(rdoList[3]);
322  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w5(stripCluster_w5));
323 
324  // Strip cluster w6
325  auto stripCluster_w6 = FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w6(stripClusters->at(i)->localPosition<1>()(0, 0),
326  0, // Strip cluster has no local position y
327  stripClusters->at(i)->localCovariance<1>()(0, 0),
328  0);
329  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w6(stripCluster_w6));
330 
331  // Strip cluster w7
332  auto stripCluster_w7 = FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w7(stripClusters->at(i)->globalPosition()[0],
333  stripClusters->at(i)->globalPosition()[1],
334  stripClusters->at(i)->channelsInPhi(),
335  0);
336  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w7(stripCluster_w7));
337 
338  // Strip cluster w8
339  auto stripCluster_w8 = FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w8(stripClusters->at(i)->identifier());
340  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w8(stripCluster_w8));
341 
342  // Strip cluster w9
343  isLast = i == (stripClusters->size() - 1) ? 1 : 0;
344  auto stripCluster_w9 = FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w9(stripClusters->at(i)->globalPosition()[2],
345  isLast, i, 0);
346  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w9(stripCluster_w9));
347  }
348 
349  // Fill the event footer
350  // Event footer w1
352  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EVT_FTR_w1(footer_w1));
353 
354  // Event footer w2
355  auto footer_w2 = FPGADataFormatUtilities::fill_EVT_FTR_w2(0);
356  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EVT_FTR_w2(footer_w2));
357 
358  // Event footer w3
359  // 44939973 in the crc field is a dummy value for now
360  auto footer_w3 = FPGADataFormatUtilities::fill_EVT_FTR_w3(encodedData.size(), 44939973);
361  encodedData.push_back(FPGADataFormatUtilities::get_dataformat_EVT_FTR_w3(footer_w3));
362 
363  return StatusCode::SUCCESS;
364 }
EFTrackingFPGAIntegration::TVHolder::refTV
std::vector< uint64_t > refTV
Definition: TestVectorTool.h:34
FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w5
EDM_PIXELCLUSTER_w5 fill_EDM_PIXELCLUSTER_w5(const uint64_t &rdo_list_w4)
Definition: FPGADataFormatUtilities.h:2012
FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w4
uint64_t get_dataformat_EDM_PIXELCLUSTER_w4(const EDM_PIXELCLUSTER_w4 &in)
Definition: FPGADataFormatUtilities.h:1932
FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w3
EDM_STRIPCLUSTER_w3 fill_EDM_STRIPCLUSTER_w3(const uint64_t &rdo_list_w2)
Definition: FPGADataFormatUtilities.h:1544
FPGADataFormatUtilities::get_dataformat_EVT_HDR_w3
uint64_t get_dataformat_EVT_HDR_w3(const EVT_HDR_w3 &in)
Definition: FPGADataFormatUtilities.h:113
FPGADataFormatUtilities::get_dataformat_EVT_FTR_w2
uint64_t get_dataformat_EVT_FTR_w2(const EVT_FTR_w2 &in)
Definition: FPGADataFormatUtilities.h:249
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w7
EDM_STRIPCLUSTER_w7 fill_EDM_STRIPCLUSTER_w7(const double &globalposition_x, const double &globalposition_y, const uint64_t &channels_in_phi, const uint64_t &spare)
Definition: FPGADataFormatUtilities.h:1571
FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w1
EDM_PIXELCLUSTER_w1 fill_EDM_PIXELCLUSTER_w1(const uint64_t &flag, const uint64_t &id_hash, const uint64_t &spare)
Definition: FPGADataFormatUtilities.h:1986
FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w5
uint64_t get_dataformat_EDM_STRIPCLUSTER_w5(const EDM_STRIPCLUSTER_w5 &in)
Definition: FPGADataFormatUtilities.h:1491
FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w1
uint64_t get_dataformat_EDM_STRIPCLUSTER_w1(const EDM_STRIPCLUSTER_w1 &in)
Definition: FPGADataFormatUtilities.h:1465
FPGADataFormatUtilities::EVT_HDR_FLAG
const int EVT_HDR_FLAG
Definition: FPGADataFormatUtilities.h:20
FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w9
EDM_STRIPCLUSTER_w9 fill_EDM_STRIPCLUSTER_w9(const double &globalposition_z, const uint64_t &lastword, const uint64_t &index, const uint64_t &spare)
Definition: FPGADataFormatUtilities.h:1586
FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w1
uint64_t get_dataformat_EDM_PIXELCLUSTER_w1(const EDM_PIXELCLUSTER_w1 &in)
Definition: FPGADataFormatUtilities.h:1912
FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w5
EDM_STRIPCLUSTER_w5 fill_EDM_STRIPCLUSTER_w5(const uint64_t &rdo_list_w4)
Definition: FPGADataFormatUtilities.h:1556
FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w3
uint64_t get_dataformat_EDM_STRIPCLUSTER_w3(const EDM_STRIPCLUSTER_w3 &in)
Definition: FPGADataFormatUtilities.h:1479
FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w7
uint64_t get_dataformat_EDM_STRIPCLUSTER_w7(const EDM_STRIPCLUSTER_w7 &in)
Definition: FPGADataFormatUtilities.h:1506
FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w2
uint64_t get_dataformat_EDM_PIXELCLUSTER_w2(const EDM_PIXELCLUSTER_w2 &in)
Definition: FPGADataFormatUtilities.h:1920
TestVectorTool::initialize
StatusCode initialize() override
Definition: TestVectorTool.cxx:16
FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w7
uint64_t get_dataformat_EDM_PIXELCLUSTER_w7(const EDM_PIXELCLUSTER_w7 &in)
Definition: FPGADataFormatUtilities.h:1954
TestVectorTool::prepareTV
StatusCode prepareTV(const std::string &inputFile, std::vector< uint64_t > &testVector) const
Prepare test vector in the form of std::vector<uint64_t>, can be either .txt or .bin.
Definition: TestVectorTool.cxx:23
FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w9
EDM_PIXELCLUSTER_w9 fill_EDM_PIXELCLUSTER_w9(const uint64_t &identifier)
Definition: FPGADataFormatUtilities.h:2045
Helpers.h
FPGADataFormatUtilities::fill_EVT_HDR_w2
EVT_HDR_w2 fill_EVT_HDR_w2(const uint64_t &runnumber, const uint64_t &time)
Definition: FPGADataFormatUtilities.h:129
FPGADataFormatUtilities::fill_EVT_FTR_w3
EVT_FTR_w3 fill_EVT_FTR_w3(const uint64_t &word_count, const uint64_t &crc)
Definition: FPGADataFormatUtilities.h:276
EFTrackingFPGAIntegration::TVHolder::name
std::string name
Definition: TestVectorTool.h:32
FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w8
uint64_t get_dataformat_EDM_STRIPCLUSTER_w8(const EDM_STRIPCLUSTER_w8 &in)
Definition: FPGADataFormatUtilities.h:1515
FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w6
EDM_STRIPCLUSTER_w6 fill_EDM_STRIPCLUSTER_w6(const double &localposition_x, const double &localposition_y, const double &localcovariance_xx, const uint64_t &spare)
Definition: FPGADataFormatUtilities.h:1562
FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w10
EDM_PIXELCLUSTER_w10 fill_EDM_PIXELCLUSTER_w10(const double &globalposition_z, const uint64_t &total_tot, const uint64_t &lastword, const uint64_t &index)
Definition: FPGADataFormatUtilities.h:2051
FPGADataFormatUtilities::EDM_STRIPCLUSTER_FLAG
const int EDM_STRIPCLUSTER_FLAG
Definition: FPGADataFormatUtilities.h:1262
FPGADataFormatUtilities::fill_EVT_HDR_w1
EVT_HDR_w1 fill_EVT_HDR_w1(const uint64_t &flag, const uint64_t &l0id, const uint64_t &bcid, const uint64_t &spare)
Definition: FPGADataFormatUtilities.h:120
FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w6
EDM_PIXELCLUSTER_w6 fill_EDM_PIXELCLUSTER_w6(const double &localposition_x, const double &localposition_y, const uint64_t &channels_in_phi, const uint64_t &channels_in_eta, const uint64_t &width_in_eta)
Definition: FPGADataFormatUtilities.h:2018
FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w8
EDM_PIXELCLUSTER_w8 fill_EDM_PIXELCLUSTER_w8(const double &globalposition_x, const double &globalposition_y, const uint64_t &spare)
Definition: FPGADataFormatUtilities.h:2037
python.setupRTTAlg.size
int size
Definition: setupRTTAlg.py:39
TestVectorTool::compare
StatusCode compare(const std::vector< uint64_t > &tv_1, const std::vector< uint64_t > &tv_2) const
Compare two TV in the form of std::vector<uint64_t>
Definition: TestVectorTool.cxx:80
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
FPGADataFormatUtilities::get_dataformat_EVT_HDR_w2
uint64_t get_dataformat_EVT_HDR_w2(const EVT_HDR_w2 &in)
Definition: FPGADataFormatUtilities.h:106
FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w8
uint64_t get_dataformat_EDM_PIXELCLUSTER_w8(const EDM_PIXELCLUSTER_w8 &in)
Definition: FPGADataFormatUtilities.h:1963
FPGADataFormatUtilities::get_dataformat_EVT_FTR_w3
uint64_t get_dataformat_EVT_FTR_w3(const EVT_FTR_w3 &in)
Definition: FPGADataFormatUtilities.h:255
CaloCondBlobAlgs_fillNoiseFromASCII.inputFile
string inputFile
Definition: CaloCondBlobAlgs_fillNoiseFromASCII.py:16
FPGADataFormatUtilities::EVT_FTR_FLAG
const int EVT_FTR_FLAG
Definition: FPGADataFormatUtilities.h:176
lumiFormat.i
int i
Definition: lumiFormat.py:85
TestVectorTool::encodePixelL2G
StatusCode encodePixelL2G(const xAOD::PixelClusterContainer *pixelClusters, std::vector< uint64_t > &encodedData) const
Encode xAOD pixel cluster to L2G EDM TV.
Definition: TestVectorTool.cxx:160
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w2
EDM_STRIPCLUSTER_w2 fill_EDM_STRIPCLUSTER_w2(const uint64_t &rdo_list_w1)
Definition: FPGADataFormatUtilities.h:1538
FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w4
EDM_PIXELCLUSTER_w4 fill_EDM_PIXELCLUSTER_w4(const uint64_t &rdo_list_w3)
Definition: FPGADataFormatUtilities.h:2006
file
TFile * file
Definition: tile_monitor.h:29
FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w9
uint64_t get_dataformat_EDM_PIXELCLUSTER_w9(const EDM_PIXELCLUSTER_w9 &in)
Definition: FPGADataFormatUtilities.h:1971
FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w1
EDM_STRIPCLUSTER_w1 fill_EDM_STRIPCLUSTER_w1(const uint64_t &flag, const uint64_t &id_hash, const uint64_t &spare)
Definition: FPGADataFormatUtilities.h:1530
xAOD::uint64_t
uint64_t
Definition: EventInfo_v1.cxx:123
FPGADataFormatUtilities::fill_EVT_HDR_w3
EVT_HDR_w3 fill_EVT_HDR_w3(const uint64_t &status, const uint64_t &crc)
Definition: FPGADataFormatUtilities.h:136
EFTrackingFPGAIntegration::TVHolder
Definition: TestVectorTool.h:29
FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w5
uint64_t get_dataformat_EDM_PIXELCLUSTER_w5(const EDM_PIXELCLUSTER_w5 &in)
Definition: FPGADataFormatUtilities.h:1938
FPGADataFormatUtilities.h
FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w6
uint64_t get_dataformat_EDM_PIXELCLUSTER_w6(const EDM_PIXELCLUSTER_w6 &in)
Definition: FPGADataFormatUtilities.h:1944
DataVector
Derived DataVector<T>.
Definition: DataVector.h:794
FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w2
uint64_t get_dataformat_EDM_STRIPCLUSTER_w2(const EDM_STRIPCLUSTER_w2 &in)
Definition: FPGADataFormatUtilities.h:1473
TestVectorTool::encodeStripL2G
StatusCode encodeStripL2G(const xAOD::StripClusterContainer *stripClusters, std::vector< uint64_t > &encodedData) const
Encode xAOD strip cluster to L2G EDM TV.
Definition: TestVectorTool.cxx:268
FPGADataFormatUtilities::EDM_PIXELCLUSTER_FLAG
const int EDM_PIXELCLUSTER_FLAG
Definition: FPGADataFormatUtilities.h:1676
FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w2
EDM_PIXELCLUSTER_w2 fill_EDM_PIXELCLUSTER_w2(const uint64_t &rdo_list_w1)
Definition: FPGADataFormatUtilities.h:1994
FPGADataFormatUtilities::get_dataformat_EVT_FTR_w1
uint64_t get_dataformat_EVT_FTR_w1(const EVT_FTR_w1 &in)
Definition: FPGADataFormatUtilities.h:241
FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w7
EDM_PIXELCLUSTER_w7 fill_EDM_PIXELCLUSTER_w7(const double &localcovariance_xx, const double &localcovariance_yy, const double &omega_x, const double &omega_y)
Definition: FPGADataFormatUtilities.h:2028
FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w4
uint64_t get_dataformat_EDM_STRIPCLUSTER_w4(const EDM_STRIPCLUSTER_w4 &in)
Definition: FPGADataFormatUtilities.h:1485
FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w3
uint64_t get_dataformat_EDM_PIXELCLUSTER_w3(const EDM_PIXELCLUSTER_w3 &in)
Definition: FPGADataFormatUtilities.h:1926
FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w6
uint64_t get_dataformat_EDM_STRIPCLUSTER_w6(const EDM_STRIPCLUSTER_w6 &in)
Definition: FPGADataFormatUtilities.h:1497
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w4
EDM_STRIPCLUSTER_w4 fill_EDM_STRIPCLUSTER_w4(const uint64_t &rdo_list_w3)
Definition: FPGADataFormatUtilities.h:1550
FPGADataFormatUtilities::get_dataformat_EDM_PIXELCLUSTER_w10
uint64_t get_dataformat_EDM_PIXELCLUSTER_w10(const EDM_PIXELCLUSTER_w10 &in)
Definition: FPGADataFormatUtilities.h:1977
FPGADataFormatUtilities::fill_EDM_STRIPCLUSTER_w8
EDM_STRIPCLUSTER_w8 fill_EDM_STRIPCLUSTER_w8(const uint64_t &identifier)
Definition: FPGADataFormatUtilities.h:1580
FPGADataFormatUtilities::get_dataformat_EDM_STRIPCLUSTER_w9
uint64_t get_dataformat_EDM_STRIPCLUSTER_w9(const EDM_STRIPCLUSTER_w9 &in)
Definition: FPGADataFormatUtilities.h:1521
TestVectorTool.h
DataVector::at
const T * at(size_type n) const
Access an element, as an rvalue.
FPGADataFormatUtilities::fill_EVT_FTR_w2
EVT_FTR_w2 fill_EVT_FTR_w2(const uint64_t &error_flags)
Definition: FPGADataFormatUtilities.h:270
FPGADataFormatUtilities::fill_EVT_FTR_w1
EVT_FTR_w1 fill_EVT_FTR_w1(const uint64_t &flag, const uint64_t &spare, const uint64_t &hdr_crc)
Definition: FPGADataFormatUtilities.h:262
FPGADataFormatUtilities::fill_EDM_PIXELCLUSTER_w3
EDM_PIXELCLUSTER_w3 fill_EDM_PIXELCLUSTER_w3(const uint64_t &rdo_list_w2)
Definition: FPGADataFormatUtilities.h:2000
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
FPGADataFormatUtilities::get_dataformat_EVT_HDR_w1
uint64_t get_dataformat_EVT_HDR_w1(const EVT_HDR_w1 &in)
Definition: FPGADataFormatUtilities.h:97