ATLAS Offline Software
FPGATrackSimHoughRootOutputTool.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
9 
10 
12 FPGATrackSimHoughRootOutputTool::FPGATrackSimHoughRootOutputTool(const std::string& algname, const std::string& name, const IInterface *ifc) :
13  AthAlgTool(algname, name, ifc)
14 {
15 }
16 
17 
18 
19 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
21 {
22  ATH_CHECK(m_FPGATrackSimMapping.retrieve());
23  ATH_CHECK(m_tHistSvc.retrieve());
24  ATH_CHECK(m_EvtSel.retrieve());
25 
26  if(m_algorithm == "Normal") m_algo=ORAlgo::Normal;
27  else if(m_algorithm == "Invert") m_algo=ORAlgo::InvertGrouping;
28 
30  return StatusCode::SUCCESS;
31 }
32 
33 
34 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
36 {
37  m_tree = new TTree("FPGATrackSimHoughRootOutput","FPGATrackSimHoughRootOutput");
38  m_tree->Branch("x",&m_x);
39  m_tree->Branch("y",&m_y);
40  m_tree->Branch("z",&m_z);
41  m_tree->Branch("volumeID",&m_volumeID);
42  m_tree->Branch("custom_layerID",&m_custom_layerID);
43 
44  m_tree->Branch("layerID",&m_layerID);
45  m_tree->Branch("etaID",&m_etaID);
46 
47  m_tree->Branch("gphi",&m_gphi);
48  m_tree->Branch("zIdeal",&m_zIdeal);
49  m_tree->Branch("gphiIdeal",&m_gphiIdeal);
50  m_tree->Branch("phi",&m_phi);
51  m_tree->Branch("invpt",&m_invpt);
52  m_tree->Branch("tracknumber",&m_tracknumber);
53  m_tree->Branch("roadnumber",&m_roadnumber);
54  m_tree->Branch("barcode",&m_barcode);
55  m_tree->Branch("barcodefrac",&m_barcodefrac);
56  m_tree->Branch("eventindex",&m_eventindex);
57  m_tree->Branch("isRealHit",&m_realHit);
58  m_tree->Branch("isPixel",&m_isPixel);
59  m_tree->Branch("layer",&m_layer);
60  m_tree->Branch("isBarrel",&m_isBarrel);
61  m_tree->Branch("etawidth",&m_etawidth);
62  m_tree->Branch("phiwidth",&m_phiwidth);
63  m_tree->Branch("etamodule",&m_etamodule);
64  m_tree->Branch("phimodule",&m_phimodule);
65  m_tree->Branch("ID",&m_ID);
66  m_tree->Branch("diskLayer",&m_diskLayer);
67  m_tree->Branch("hitIsMapped",&m_mapped);
68 
69  m_tree->Branch("candidate_barcodefrac",&m_candidate_barcodefrac);
70  m_tree->Branch("candidate_barcode",&m_candidate_barcode);
71  m_tree->Branch("candidate_eventindex",&m_candidate_eventindex);
72  m_tree->Branch("treeindex",&m_treeindex);
73  m_tree->Branch("subregion",&m_subregion);
74  m_tree->Branch("fakelabel",&m_fakelabel);
75  m_tree->Branch("passesOR",&m_passesOR);
76  m_tree->Branch("roadChi2",&m_roadChi2);
77  m_tree->Branch("nMissingHits",&m_nMissingHits);
78  m_tree->Branch("NTracksORMinusRoads",&m_NTracksORMinusRoads);
79 
80  m_treeindex = 0;
81 
82  m_truthtree = new TTree("FPGATrackSimTruthTree","FPGATrackSimTruthTree");
83  m_truthtree->Branch("truth_d0",&m_truth_d0);
84  m_truthtree->Branch("truth_z0",&m_truth_z0);
85  m_truthtree->Branch("truth_pt",&m_truth_pt);
86  m_truthtree->Branch("truth_eta",&m_truth_eta);
87  m_truthtree->Branch("truth_phi",&m_truth_phi);
88  m_truthtree->Branch("truth_q",&m_truth_q);
89  m_truthtree->Branch("truth_pdg",&m_truth_pdg);
90  m_truthtree->Branch("truth_barcode",&m_truth_barcode);
91  m_truthtree->Branch("truth_eventindex",&m_truth_eventindex);
92  m_truthtree->Branch("truth_track_hit_x",&m_track_hit_x);
93  m_truthtree->Branch("truth_track_hit_y",&m_track_hit_y);
94  m_truthtree->Branch("truth_track_hit_z",&m_track_hit_z);
95  m_truthtree->Branch("truth_track_hit_R",&m_track_hit_R);
96  m_truthtree->Branch("truth_track_hit_phi",&m_track_hit_phi);
97  m_truthtree->Branch("truth_track_hit_layer_disk",&m_track_hit_layer_disk);
98  m_truthtree->Branch("has_strip_nonspacepoint",&m_has_strip_nonspacepoint);
99  m_truthtree->Branch("truth_track_hit_isPixel", &m_track_hit_isPixel);
100  m_truthtree->Branch("truth_track_hit_isStrip", &m_track_hit_isStrip);
101  m_truthtree->Branch("truth_track_hit_isClustered", &m_track_hit_isClustered);
102  m_truthtree->Branch("truth_track_hit_isSpacepoint", &m_track_hit_isSpacepoint);
103  m_truthtree->Branch("truth_track_hit_barcode", &m_track_hit_barcode);
104  m_truthtree->Branch("truth_track_hit_barcodefrac", &m_track_hit_barcodefrac);
105  m_truthtree->Branch("truth_track_hit_zIdeal", &m_track_hit_zIdeal);
106  m_truthtree->Branch("truth_track_hit_gphiIdeal", &m_track_hit_gphiIdeal);
107  m_truthtree->Branch("truth_track_hit_fineID", &m_track_hit_fineID);
108 
109  m_offlinetree = new TTree("FPGATrackSimOfflineTree","FPGATrackSimOfflineTree");
110  m_offlinetree->Branch("offline_d0",&m_offline_d0);
111  m_offlinetree->Branch("offline_z0",&m_offline_z0);
112  m_offlinetree->Branch("offline_pt",&m_offline_pt);
113  m_offlinetree->Branch("offline_eta",&m_offline_eta);
114  m_offlinetree->Branch("offline_phi",&m_offline_phi);
115  m_offlinetree->Branch("offline_q",&m_offline_q);
116  m_offlinetree->Branch("offline_barcode",&m_offline_barcode);
117  m_offlinetree->Branch("offline_barcodefrac",&m_offline_barcodefrac);
118  m_offlinetree->Branch("offline_n_holes",&m_offline_n_holes);
119  m_offlinetree->Branch("offline_n_inertmaterial",&m_offline_n_inertmaterial);
120  m_offlinetree->Branch("offline_n_measurement",&m_offline_n_measurement);
121  m_offlinetree->Branch("offline_n_brempoint",&m_offline_n_brempoint);
122  m_offlinetree->Branch("offline_n_scatterer",&m_offline_n_scatterer);
123  m_offlinetree->Branch("offline_n_perigee",&m_offline_n_perigee);
124  m_offlinetree->Branch("offline_n_outlier",&m_offline_n_outlier);
125  m_offlinetree->Branch("offline_n_other",&m_offline_n_other);
126 
127  ATH_CHECK(m_tHistSvc->regTree(Form("/TRIGFPGATrackSimHOUGHOUTPUT/%s",m_tree->GetName()), m_tree));
128  ATH_CHECK(m_tHistSvc->regTree(Form("/TRIGFPGATrackSimHOUGHOUTPUT/%s",m_truthtree->GetName()), m_truthtree));
129  ATH_CHECK(m_tHistSvc->regTree(Form("/TRIGFPGATrackSimHOUGHOUTPUT/%s",m_offlinetree->GetName()), m_offlinetree));
130 
131  return StatusCode::SUCCESS;
132 }
133 
134 
135 
136 StatusCode FPGATrackSimHoughRootOutputTool::fillTree(const std::vector<std::shared_ptr<const FPGATrackSimRoad>> &roads, const std::vector<FPGATrackSimTruthTrack> &truthTracks, const std::vector<FPGATrackSimOfflineTrack> &offlineTracks, const std::vector<std::shared_ptr<const FPGATrackSimHit>> &hits_2nd, const bool writeOutNonSPStripHits, const float minChi2, const int maxOverlappingHits)
137 {
138  ATH_MSG_DEBUG("Running HoughOutputTool!!");
139 
140  m_tracknumber = 0;
141  ResetVectors();
142 
143 
144  std::vector<float> tmp_hits_x;
145  std::vector<float> tmp_hits_y;
146  std::vector<float> tmp_hits_z;
147  std::vector<float> tmp_hits_R;
148  std::vector<float> tmp_hits_phi;
149  std::vector<int> tmp_hits_layer_disk;
150  std::vector<bool> tmp_hits_mapped;
151  std::vector<bool> tmp_hits_isPixel;
152  std::vector<bool> tmp_hits_isStrip;
153  std::vector<bool> tmp_hits_isClustered;
154  std::vector<bool> tmp_hits_isSpacepoint;
155  std::vector<float> tmp_hits_barcodefrac;
156  std::vector<int> tmp_hits_barcode;
157  std::vector<float> tmp_hits_zIdeal;
158  std::vector<float> tmp_hits_gphiIdeal;
159  std::vector<long> tmp_hits_fineID;
160 
161  std::vector<float> tmp_hits_x_sorted;
162  std::vector<float> tmp_hits_y_sorted;
163  std::vector<float> tmp_hits_z_sorted;
164  std::vector<float> tmp_hits_R_sorted;
165  std::vector<float> tmp_hits_phi_sorted;
166  std::vector<int> tmp_hits_layer_disk_sorted;
167  std::vector<bool> tmp_hits_isPixel_sorted;
168  std::vector<bool> tmp_hits_isStrip_sorted;
169  std::vector<bool> tmp_hits_isClustered_sorted;
170  std::vector<bool> tmp_hits_isSpacepoint_sorted;
171  std::vector<float> tmp_hits_barcodefrac_sorted;
172  std::vector<int> tmp_hits_barcode_sorted;
173  std::vector<float> tmp_hits_zIdeal_sorted;
174  std::vector<float> tmp_hits_gphiIdeal_sorted;
175  std::vector<long> tmp_hits_fineID_sorted;
176 
177  std::vector<bool> tmp_hits_mapped_sorted;
178  bool has_strip_nonspacepoint;
179 
180 
181  // fill the truth tree, simply once per event! to know which entry here to loop at for a given road or hit
182  // combination below, use treeindex from below to find the entry here
183  for (const auto & track : truthTracks) {
184  if (!m_EvtSel->passCuts(track)) continue;
185  if (track.getStatus() != 1) continue;
186 
187 
188  tmp_hits_x.clear();
189  tmp_hits_y.clear();
190  tmp_hits_z.clear();
191  tmp_hits_R.clear();
192  tmp_hits_phi.clear();
193  tmp_hits_layer_disk.clear();
194  tmp_hits_mapped.clear();
195  tmp_hits_isPixel.clear();
196  tmp_hits_isStrip.clear();
197  tmp_hits_isClustered.clear();
198  tmp_hits_isSpacepoint.clear();
199  tmp_hits_barcodefrac.clear();
200  tmp_hits_barcode.clear();
201  tmp_hits_zIdeal.clear();
202  tmp_hits_gphiIdeal.clear();
203  tmp_hits_fineID.clear();
204 
205  tmp_hits_x_sorted.clear();
206  tmp_hits_y_sorted.clear();
207  tmp_hits_z_sorted.clear();
208  tmp_hits_R_sorted.clear();
209  tmp_hits_phi_sorted.clear();
210  tmp_hits_layer_disk_sorted.clear();
211  tmp_hits_isPixel_sorted.clear();
212  tmp_hits_isStrip_sorted.clear();
213  tmp_hits_isClustered_sorted.clear();
214  tmp_hits_isSpacepoint_sorted.clear();
215  tmp_hits_barcodefrac_sorted.clear();
216  tmp_hits_barcode_sorted.clear();
217  tmp_hits_zIdeal_sorted.clear();
218  tmp_hits_gphiIdeal_sorted.clear();
219  tmp_hits_fineID_sorted.clear();
220 
221  has_strip_nonspacepoint = false;
222 
223  double target_r;
224  std::vector<float> idealized_coords;
227 
228  // Collect truth tracks' 2nd stage hits
229  for (auto hit : hits_2nd) {
230  // Only write out hits belonging to the truth track
231  if (hit->getBarcode() == track.getBarcode()) {
232 
233  if (hit->isPixel() == 0 && hit->getHitType() != HitType::spacepoint) {has_strip_nonspacepoint = true;}
234 
235  FPGATrackSimMultiTruth truth = hit->getTruth();
237 
238  const bool ok = truth.best(tbarcode, tfrac);
239  if (tfrac < 1.0) { continue; }
240  if( ok ) {
241  tmp_hits_barcode.push_back((int)(tbarcode.second));
242  tmp_hits_barcodefrac.push_back(tfrac);
243  }
244  else {
245  tmp_hits_barcode.push_back(-1);
246  tmp_hits_barcodefrac.push_back(-1);
247  }
248 
249  tmp_hits_x.push_back(hit->getX());
250  tmp_hits_y.push_back(hit->getY());
251  tmp_hits_z.push_back(hit->getZ());
252  tmp_hits_R.push_back(hit->getR());
253  tmp_hits_phi.push_back(hit->getGPhi());
254  tmp_hits_layer_disk.push_back(hit->getLayerDisk());
255  tmp_hits_mapped.push_back(hit->isMapped());
256  tmp_hits_isPixel.push_back(hit->isPixel());
257  tmp_hits_isStrip.push_back(hit->isStrip());
258  tmp_hits_isClustered.push_back(hit->isClustered());
259 
260  tmp_hits_fineID.push_back(getFineID(*hit));
261 
262  target_r = m_SUBREGIONMAP->getAvgRadius(0, hit->getLayerDisk());
263  idealized_coords = computeIdealCoords(*hit, hit->getGPhi(), track.getQOverPt(), target_r, true, TrackCorrType::None);
264  tmp_hits_zIdeal.push_back(idealized_coords[0]);
265  tmp_hits_gphiIdeal.push_back(idealized_coords[1]);
266 
267  if (hit->getHitType() == HitType::spacepoint) {
268  tmp_hits_isSpacepoint.push_back(true);
269  }
270  else {
271  tmp_hits_isSpacepoint.push_back(false);
272  }
273  }
274  }
275 
276 
277  m_has_strip_nonspacepoint.push_back(has_strip_nonspacepoint);
278 
279  if ( (! writeOutNonSPStripHits & has_strip_nonspacepoint)) {
280  ATH_MSG_DEBUG("Truth Track is not written to HoughRootOutput file, because it contains a non-SP strip hit!");
281  continue;
282  }
283 
284  std::vector<int> sorting_index(tmp_hits_R.size(), 0);
285  for (unsigned int i = 0 ; i != sorting_index.size() ; i++) {
286  sorting_index[i] = i;
287  }
288  sort(sorting_index.begin(), sorting_index.end(),
289  [&](const int& a, const int& b) {
290  return (tmp_hits_R[a] < tmp_hits_R[b]);
291  }
292  );
293 
294  for (unsigned int i = 0 ; i != sorting_index.size() ; i++) {
295  tmp_hits_x_sorted.push_back(tmp_hits_x[sorting_index[i]]);
296  tmp_hits_y_sorted.push_back(tmp_hits_y[sorting_index[i]]);
297  tmp_hits_z_sorted.push_back(tmp_hits_z[sorting_index[i]]);
298  tmp_hits_R_sorted.push_back(tmp_hits_R[sorting_index[i]]);
299  tmp_hits_phi_sorted.push_back(tmp_hits_phi[sorting_index[i]]);
300  tmp_hits_layer_disk_sorted.push_back(tmp_hits_layer_disk[sorting_index[i]]);
301  tmp_hits_isPixel_sorted.push_back(tmp_hits_isPixel[sorting_index[i]]);
302  tmp_hits_isStrip_sorted.push_back(tmp_hits_isStrip[sorting_index[i]]);
303  tmp_hits_isClustered_sorted.push_back(tmp_hits_isClustered[sorting_index[i]]);
304  tmp_hits_isSpacepoint_sorted.push_back(tmp_hits_isSpacepoint[sorting_index[i]]);
305  tmp_hits_barcode_sorted.push_back(tmp_hits_barcode[sorting_index[i]]);
306  tmp_hits_barcodefrac_sorted.push_back(tmp_hits_barcodefrac[sorting_index[i]]);
307  tmp_hits_zIdeal_sorted.push_back(tmp_hits_zIdeal[sorting_index[i]]);
308  tmp_hits_gphiIdeal_sorted.push_back(tmp_hits_gphiIdeal[sorting_index[i]]);
309  tmp_hits_fineID_sorted.push_back(tmp_hits_fineID[sorting_index[i]]);
310  };
311 
312  m_track_hit_x.push_back(tmp_hits_x_sorted);
313  m_track_hit_y.push_back(tmp_hits_y_sorted);
314  m_track_hit_z.push_back(tmp_hits_z_sorted);
315  m_track_hit_R.push_back(tmp_hits_R_sorted);
316  m_track_hit_phi.push_back(tmp_hits_phi_sorted);
317  m_track_hit_layer_disk.push_back(tmp_hits_layer_disk_sorted);
318  m_track_hit_isPixel.push_back(tmp_hits_isPixel_sorted);
319  m_track_hit_isStrip.push_back(tmp_hits_isStrip);
320  m_track_hit_isClustered.push_back(tmp_hits_isClustered_sorted);
321  m_track_hit_isSpacepoint.push_back(tmp_hits_isSpacepoint_sorted);
322  m_track_hit_barcode.push_back(tmp_hits_barcode_sorted);
323  m_track_hit_barcodefrac.push_back(tmp_hits_barcodefrac_sorted);
324  m_track_hit_zIdeal.push_back(tmp_hits_zIdeal_sorted);
325  m_track_hit_gphiIdeal.push_back(tmp_hits_gphiIdeal_sorted);
326  m_track_hit_fineID.push_back(tmp_hits_fineID_sorted);
327 
328  m_truth_d0.push_back(track.getD0());
329  m_truth_z0.push_back(track.getZ0());
330  m_truth_pt.push_back(track.getPt());
331  m_truth_eta.push_back(track.getEta());
332  m_truth_phi.push_back(track.getPhi());
333  m_truth_barcode.push_back(track.getBarcode());
334  m_truth_eventindex.push_back(track.getEventIndex());
335  m_truth_q.push_back(track.getQ());
336  m_truth_pdg.push_back(track.getPDGCode());
337  }
338  // Fill only if at least one truth track to save to avoid empty events
339  if (m_truth_eventindex.size() != 0) {
340  m_truthtree->Fill();
341  }
342  ResetVectors();
343 
344 
345  // now do the same for offline tree, once per event
346  for (auto track : offlineTracks) {
347  if (!m_EvtSel->passCuts(track)) continue;
348 
349  m_offline_d0.push_back(track.getD0());
350  m_offline_z0.push_back(track.getZ0());
351  m_offline_pt.push_back(abs(1./track.getQOverPt()));
352  m_offline_eta.push_back(track.getEta());
353  m_offline_phi.push_back(track.getPhi());
354  m_offline_barcode.push_back(track.getBarcode());
355  m_offline_barcodefrac.push_back(track.getBarcodeFrac());
356 
357  m_offline_q.push_back(track.getQOverPt() > 0 ? 1 : -1);
358  int nhole(0), nmeasurement(0), ninert(0), nbrem(0), nscatter(0), nperigee(0), noutlier(0), nother(0);
359  for (const auto& hit : track.getOfflineHits()) {
360  if (hit.getHitType() == OfflineHitType::Measurement) nmeasurement++;
361  else if (hit.getHitType() == OfflineHitType::InertMaterial) ninert++;
362  else if (hit.getHitType() == OfflineHitType::BremPoint) nbrem++;
363  else if (hit.getHitType() == OfflineHitType::Scatterer) nscatter++;
364  else if (hit.getHitType() == OfflineHitType::Perigee) nperigee++;
365  else if (hit.getHitType() == OfflineHitType::Outlier) noutlier++;
366  else if (hit.getHitType() == OfflineHitType::Hole) nhole++;
367  else nother++;
368  }
369  m_offline_n_holes.push_back(nhole);
370  m_offline_n_measurement.push_back(nmeasurement);
371  m_offline_n_inertmaterial.push_back(ninert);
372  m_offline_n_brempoint.push_back(nbrem);
373  m_offline_n_scatterer.push_back(nscatter);
374  m_offline_n_perigee.push_back(nperigee);
375  m_offline_n_outlier.push_back(noutlier);
376  m_offline_n_other.push_back(nother);
377  }
378  m_offlinetree->Fill();
379  ResetVectors();
380 
381  // for calculating the truth for the entire combination, not just an individual hit
382  std::vector<FPGATrackSimMultiTruth> mtv;
383  mtv.reserve( m_FPGATrackSimMapping->PlaneMap_1st(0)->getNLogiLayers());
384 
385 
386  // Create a list of track candidates by taking all possible combinations of hits in road.
387  std::vector<FPGATrackSimTrack> track_cands;
388 
389 
390  for (size_t iroad = 0; iroad < roads.size(); iroad++) {
391  m_roadnumber = iroad;
392  std::shared_ptr<const FPGATrackSimRoad> road = roads[iroad];
393  std::vector<FPGATrackSimTrack> track_cand;
394  if (road == nullptr) continue; // Not Hough roads
395 
396  std::vector<std::vector<int>> combs = ::getComboIndices(road->getNHits_layer());
397  m_phi = road->getX();
398  m_invpt = road->getY();
399 
400  // Build track candidate for OR tool
401  int nMissing;
402  bool missPixel;
403  bool missStrip;
404  layer_bitmask_t missing_mask;
405  layer_bitmask_t norecovery_mask; // mask to prevent majority in planes with multiple hits
406  getMissingInfo(*road, nMissing, missPixel, missStrip, missing_mask, norecovery_mask, m_FPGATrackSimMapping, m_idealCoordFitType);
407  // Create a template track with common parameters filled already for initializing below
408  FPGATrackSimTrack temp;
409 
411  temp.setSecondSectorID(road->getSector());
412  // }
413  temp.setNLayers(m_FPGATrackSimMapping->PlaneMap_1st(0)->getNLogiLayers());
414  temp.setBankID(-1); // TODO
415  temp.setPatternID(road->getPID());
416  temp.setHitMap(missing_mask);
417  temp.setNMissing(nMissing);
418  temp.setHoughX(road->getX());
419  temp.setHoughY(road->getY());
420  temp.setQOverPt(road->getY());
422  temp.setDoDeltaGPhis(true);
423  temp.setPassedOR(1);
424 
425  makeTrackCandidates(*road, temp, track_cand, m_FPGATrackSimMapping);
426  for (auto const &tr : track_cand) {
427  track_cands.push_back(tr);
428  }
429  }
430 
431  ATH_CHECK(runOverlapRemoval(track_cands, minChi2, maxOverlappingHits, m_algo));
432  unsigned long passed = 0;
433  for (auto const &cand : track_cands) {
434  if (cand.passedOR()) {
435  passed++;
436  }
437  }
438 
439  m_NTracksORMinusRoads = passed - roads.size();
440 
441  double target_r;
442 
443  for (size_t iroad = 0; iroad < track_cands.size(); iroad++) {
444  m_roadnumber = iroad;
445  FPGATrackSimTrack road = track_cands[iroad];
446 
447  m_roadChi2.push_back(track_cands[iroad].getChi2ndof());
448 
449 
450  m_nMissingHits.push_back(track_cands[iroad].getNMissing());
451 
452  m_passesOR.push_back(road.passedOR());
453 
454  m_phi = road.getHoughX();
455  m_invpt = road.getHoughY();
456  m_subregion = road.getRegion();
457  std::vector<FPGATrackSimHit> hits = road.getFPGATrackSimHits();
458 
459 
460  // Add the hits from each combination to the tree
461  for (FPGATrackSimHit hit : hits) {
462 
463  m_realHit.push_back(hit.isReal());
464  mtv.clear();
465  FPGATrackSimMultiTruth truth = hit.getTruth();
466 
468  mtv.push_back( truth );
469 
472  const bool ok = truth.best(tbarcode,tfrac);
473  if( ok ) {
474  m_eventindex.push_back((int)(tbarcode.first));
475  m_barcode.push_back((int)(tbarcode.second));
476  m_barcodefrac.push_back(tfrac);
477  }
478  else {
479  m_eventindex.push_back(-1);
480  m_barcode.push_back(-1);
481  m_barcodefrac.push_back(-1);
482  }
483 
484  target_r = m_SUBREGIONMAP->getAvgRadius(0, hit.getLayer());
485  std::shared_ptr<const FPGATrackSimHit> hit_ptr = std::make_shared<const FPGATrackSimHit>(hit);
486  std::vector<float> idealized_coords = computeIdealCoords(hit, m_invpt, hit.getGPhi(), target_r, true, TrackCorrType::None);
487 
488  m_x.push_back(hit.getX());
489  m_y.push_back(hit.getY());
490  m_z.push_back(hit.getZ());
491  m_volumeID.push_back(getVolumeID(*hit_ptr));
492  m_custom_layerID.push_back(getFineID(*hit_ptr));
493  m_layerID.push_back(hit.getLayerDisk());
494  m_etaID.push_back(hit.getEtaModule());
495 
496  m_gphi.push_back(hit.getGPhi());
497  m_zIdeal.push_back(idealized_coords[0]);
498  m_gphiIdeal.push_back(idealized_coords[1]);
499  m_isPixel.push_back(hit.isPixel() ? 1 : 0);
500  m_layer.push_back(hit.getLayer());
501  m_isBarrel.push_back(hit.isBarrel() ? 1 : 0);
502  m_etawidth.push_back(hit.getEtaWidth());
503  m_phiwidth.push_back(hit.getPhiWidth());
504  m_etamodule.push_back(hit.getEtaModule());
505  m_phimodule.push_back(hit.getPhiModule());
506  m_ID.push_back(hit.getIdentifierHash());
507  m_diskLayer.push_back(hit.getLayerDisk());
508  }
509  // done looping over hits, now we do the truth calculation for this track candidate
510  // first compute the best geant match, the barcode with the largest number of contributing hits
511  // frac is then the fraction of the total number of hits on the candidate attributed to the barcode.
513  // retrieve the best barcode and frac and store it
516  const bool ok = mt.best(tbarcode,tfrac);
517  if( ok ) {
518  m_candidate_eventindex = (int)(tbarcode.first);
519  m_candidate_barcode = (int)(tbarcode.second);
520  m_candidate_barcodefrac = tfrac;
521  if ( tfrac <= 0.5 ) m_fakelabel = 1;
522  else if ( tfrac == 1.0 ) m_fakelabel = 0;
523  }
524  else {
526  m_candidate_barcode = -1;
528  m_fakelabel = 1;
529  }
530  m_tree->Fill();
531 
532  ResetVectors();
533  m_tracknumber++;
534  }
535  m_treeindex++;
536  return StatusCode::SUCCESS;
537 }
538 
540  m_x.clear();
541  m_y.clear();
542  m_z.clear();
543  m_volumeID.clear();
544  m_custom_layerID.clear();
545 
546  m_layerID.clear();
547  m_etaID.clear();
548 
549  m_barcode.clear();
550  m_barcodefrac.clear();
551  m_eventindex.clear();
552  m_realHit.clear();
553  m_isPixel.clear();
554  m_layer.clear();
555  m_isBarrel.clear();
556  m_etawidth.clear();
557  m_phiwidth.clear();
558  m_etamodule.clear();
559  m_phimodule.clear();
560  m_ID.clear();
561  m_diskLayer.clear();
562  m_passesOR.clear();
563  m_roadChi2.clear();
564  m_nMissingHits.clear();
565  m_truth_d0.clear();
566  m_truth_z0.clear();
567  m_truth_pt.clear();
568  m_truth_eta.clear();
569  m_truth_phi.clear();
570  m_truth_q.clear();
571  m_truth_barcode.clear();
572  m_truth_eventindex.clear();
573  m_truth_pdg.clear();
574  m_offline_n_holes.clear();
575  m_offline_n_measurement.clear();
577  m_offline_n_brempoint.clear();
578  m_offline_n_scatterer.clear();
579  m_offline_n_perigee.clear();
580  m_offline_n_outlier.clear();
581  m_offline_n_other.clear();
582  m_offline_d0.clear();
583  m_offline_z0.clear();
584  m_offline_pt.clear();
585  m_offline_eta.clear();
586  m_offline_phi.clear();
587  m_offline_q.clear();
588  m_offline_barcode.clear();
589  m_offline_barcodefrac.clear();
590  m_track_hit_x.clear();
591  m_track_hit_y.clear();
592  m_track_hit_z.clear();
593  m_track_hit_R.clear();
594  m_track_hit_phi.clear();
595  m_track_hit_layer_disk.clear();
596  m_track_hit_isPixel.clear();
597  m_track_hit_isStrip.clear();
598  m_track_hit_isClustered.clear();
599  m_track_hit_isSpacepoint.clear();
600  m_track_hit_barcode.clear();
601  m_track_hit_barcodefrac.clear();
602  m_track_hit_zIdeal.clear();
603  m_track_hit_gphiIdeal.clear();
604  m_track_hit_fineID.clear();
605 
606  m_gphi.clear();
607  m_zIdeal.clear();
608  m_gphiIdeal.clear();
610 }
FPGATrackSimTrack::setHitMap
void setHitMap(unsigned int v)
Definition: FPGATrackSimTrack.h:101
OfflineHitType::Hole
@ Hole
FPGATrackSimHoughRootOutputTool::m_roadChi2
std::vector< float > m_roadChi2
Definition: FPGATrackSimHoughRootOutputTool.h:94
FPGATrackSimHoughRootOutputTool::m_track_hit_isClustered
std::vector< std::vector< bool > > m_track_hit_isClustered
Definition: FPGATrackSimHoughRootOutputTool.h:146
FPGATrackSimHoughRootOutputTool::m_barcodefrac
std::vector< float > m_barcodefrac
Definition: FPGATrackSimHoughRootOutputTool.h:81
FPGATrackSimHoughRootOutputTool::m_track_hit_y
std::vector< std::vector< float > > m_track_hit_y
Definition: FPGATrackSimHoughRootOutputTool.h:138
FPGATrackSimHoughRootOutputTool::m_truth_phi
std::vector< float > m_truth_phi
Definition: FPGATrackSimHoughRootOutputTool.h:131
FPGATrackSimHoughRootOutputTool::m_offline_z0
std::vector< float > m_offline_z0
Definition: FPGATrackSimHoughRootOutputTool.h:166
getMenu.algname
algname
Definition: getMenu.py:54
FPGATrackSimHoughRootOutputTool::m_track_hit_gphiIdeal
std::vector< std::vector< float > > m_track_hit_gphiIdeal
Definition: FPGATrackSimHoughRootOutputTool.h:151
TRTCalib_Extractor.hits
hits
Definition: TRTCalib_Extractor.py:35
FPGATrackSimTrack::setBankID
void setBankID(int v)
Definition: FPGATrackSimTrack.h:84
FPGATrackSimHoughRootOutputTool::m_track_hit_barcode
std::vector< std::vector< int > > m_track_hit_barcode
Definition: FPGATrackSimHoughRootOutputTool.h:148
FPGATrackSimHoughRootOutputTool::m_isBarrel
std::vector< unsigned int > m_isBarrel
Definition: FPGATrackSimHoughRootOutputTool.h:86
TrigCompositeUtils::passed
bool passed(DecisionID id, const DecisionIDContainer &idSet)
checks if required decision ID is in the set of IDs in the container
Definition: TrigCompositeUtilsRoot.cxx:117
FPGATrackSimHoughRootOutputTool::m_layer
std::vector< unsigned int > m_layer
Definition: FPGATrackSimHoughRootOutputTool.h:85
CaloCellPos2Ntuple.int
int
Definition: CaloCellPos2Ntuple.py:24
FPGATrackSimHoughRootOutputTool::m_track_hit_phi
std::vector< std::vector< float > > m_track_hit_phi
Definition: FPGATrackSimHoughRootOutputTool.h:142
OfflineHitType::InertMaterial
@ InertMaterial
FPGATrackSimTrack
Definition: FPGATrackSimTrack.h:18
FPGATrackSimHoughRootOutputTool::initialize
virtual StatusCode initialize() override
Definition: FPGATrackSimHoughRootOutputTool.cxx:20
FPGATrackSimHoughRootOutputTool::m_offline_phi
std::vector< float > m_offline_phi
Definition: FPGATrackSimHoughRootOutputTool.h:169
FPGATrackSimTrack::setPatternID
void setPatternID(int v)
Definition: FPGATrackSimTrack.h:85
OfflineHitType::BremPoint
@ BremPoint
FPGATrackSimMultiTruth::Weight
float Weight
Definition: FPGATrackSimMultiTruth.h:50
OfflineHitType::Measurement
@ Measurement
FPGATrackSimHoughRootOutputTool::m_track_hit_zIdeal
std::vector< std::vector< float > > m_track_hit_zIdeal
Definition: FPGATrackSimHoughRootOutputTool.h:150
FPGATrackSimHoughRootOutputTool::m_realHit
std::vector< bool > m_realHit
Definition: FPGATrackSimHoughRootOutputTool.h:97
FPGATrackSimHoughRootOutputTool::m_x
std::vector< float > m_x
Definition: FPGATrackSimHoughRootOutputTool.h:71
FPGATrackSimHoughRootOutputTool::m_offlinetree
TTree * m_offlinetree
Definition: FPGATrackSimHoughRootOutputTool.h:155
accumulate
bool accumulate(AccumulateMap &map, std::vector< module_t > const &modules, FPGATrackSimMatrixAccumulator const &acc)
Accumulates an accumulator (e.g.
Definition: FPGATrackSimMatrixAccumulator.cxx:22
FPGATrackSimTrack::setNMissing
void setNMissing(int v)
Definition: FPGATrackSimTrack.h:99
ORAlgo::Normal
@ Normal
FPGATrackSimHoughRootOutputTool::m_offline_n_brempoint
std::vector< int > m_offline_n_brempoint
Definition: FPGATrackSimHoughRootOutputTool.h:159
FPGATrackSimTrack::setPassedOR
void setPassedOR(unsigned int)
Definition: FPGATrackSimTrack.cxx:260
FPGATrackSimTrack::getRegion
int getRegion() const
Definition: FPGATrackSimTrack.h:29
FPGATrackSimHoughRootOutputTool::m_gphiIdeal
std::vector< float > m_gphiIdeal
Definition: FPGATrackSimHoughRootOutputTool.h:80
FPGATrackSimHoughRootOutputTool::m_diskLayer
std::vector< unsigned int > m_diskLayer
Definition: FPGATrackSimHoughRootOutputTool.h:92
FPGATrackSimHoughRootOutputTool::m_etawidth
std::vector< unsigned int > m_etawidth
Definition: FPGATrackSimHoughRootOutputTool.h:87
HitType::spacepoint
@ spacepoint
FPGATrackSimHoughRootOutputTool::m_treeindex
int m_treeindex
Definition: FPGATrackSimHoughRootOutputTool.h:119
FPGATrackSimHoughRootOutputTool::m_track_hit_R
std::vector< std::vector< float > > m_track_hit_R
Definition: FPGATrackSimHoughRootOutputTool.h:140
FPGATrackSimHoughRootOutputTool::m_track_hit_layer_disk
std::vector< std::vector< int > > m_track_hit_layer_disk
Definition: FPGATrackSimHoughRootOutputTool.h:143
FPGATrackSimTrack::passedOR
unsigned int passedOR() const
Definition: FPGATrackSimTrack.h:127
FPGATrackSimTrack::getHoughY
float getHoughY() const
Definition: FPGATrackSimTrack.h:36
FPGATrackSimHoughRootOutputTool::m_has_strip_nonspacepoint
std::vector< bool > m_has_strip_nonspacepoint
Definition: FPGATrackSimHoughRootOutputTool.h:136
FPGATrackSimRoad::getNHits_layer
std::vector< size_t > getNHits_layer() const
Definition: FPGATrackSimRoad.cxx:27
FPGATrackSimHoughRootOutputTool::m_isPixel
std::vector< unsigned int > m_isPixel
Definition: FPGATrackSimHoughRootOutputTool.h:84
FPGATrackSimRoad::getX
float getX() const
Definition: FPGATrackSimRoad.h:86
FPGATrackSimHoughRootOutputTool::m_phi
float m_phi
Definition: FPGATrackSimHoughRootOutputTool.h:102
FPGATrackSimMultiTruth::best
bool best(FPGATrackSimMultiTruth::Barcode &code, FPGATrackSimMultiTruth::Weight &weight) const
Definition: FPGATrackSimMultiTruth.h:86
FPGATrackSimConstants.h
FPGATrackSimHit
Definition: FPGATrackSimHit.h:41
FPGATrackSimTrack::setSecondSectorID
void setSecondSectorID(int v)
Definition: FPGATrackSimTrack.h:87
FPGATrackSimHoughRootOutputTool::m_passesOR
std::vector< unsigned int > m_passesOR
Definition: FPGATrackSimHoughRootOutputTool.h:93
FPGATrackSimTrack::getFPGATrackSimHits
const std::vector< FPGATrackSimHit > & getFPGATrackSimHits() const
Definition: FPGATrackSimTrack.h:63
computeIdealCoords
std::vector< float > computeIdealCoords(const FPGATrackSimHit &hit, const double hough_x, const double hough_y, const double target_r, const bool doDeltaGPhis, const TrackCorrType trackCorrType)
Definition: FPGATrackSimFunctions.cxx:116
FPGATrackSimHoughRootOutputTool::m_offline_n_outlier
std::vector< int > m_offline_n_outlier
Definition: FPGATrackSimHoughRootOutputTool.h:162
FPGATrackSimHoughRootOutputTool::m_idealCoordFitType
TrackCorrType m_idealCoordFitType
Definition: FPGATrackSimHoughRootOutputTool.h:99
OfflineHitType::Perigee
@ Perigee
FPGATrackSimHoughRootOutputTool::m_subregion
unsigned int m_subregion
Definition: FPGATrackSimHoughRootOutputTool.h:104
FPGATrackSimHoughRootOutputTool::m_phiwidth
std::vector< unsigned int > m_phiwidth
Definition: FPGATrackSimHoughRootOutputTool.h:88
FPGATrackSimHoughRootOutputTool::m_track_hit_fineID
std::vector< std::vector< long > > m_track_hit_fineID
Definition: FPGATrackSimHoughRootOutputTool.h:152
FPGATrackSimHoughRootOutputTool::fillTree
StatusCode fillTree(const std::vector< std::shared_ptr< const FPGATrackSimRoad >> &roads, const std::vector< FPGATrackSimTruthTrack > &truthTracks, const std::vector< FPGATrackSimOfflineTrack > &offlineTracks, const std::vector< std::shared_ptr< const FPGATrackSimHit >> &hits_2nd, const bool writeOutNonSPStripHits, const float minChi2, const int maxOverlappingHits)
Definition: FPGATrackSimHoughRootOutputTool.cxx:136
lumiFormat.i
int i
Definition: lumiFormat.py:85
FPGATrackSimHoughRootOutputTool::m_truth_z0
std::vector< float > m_truth_z0
Definition: FPGATrackSimHoughRootOutputTool.h:128
FPGATrackSimHoughRootOutputTool::m_offline_d0
std::vector< float > m_offline_d0
Definition: FPGATrackSimHoughRootOutputTool.h:165
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
FPGATrackSimHoughRootOutputTool::m_offline_eta
std::vector< float > m_offline_eta
Definition: FPGATrackSimHoughRootOutputTool.h:168
getFineID
long getFineID(const FPGATrackSimHit &hit)
Definition: FPGATrackSimHoughFunctions.cxx:433
FPGATrackSimTrack::setDoDeltaGPhis
void setDoDeltaGPhis(bool v)
Definition: FPGATrackSimTrack.h:83
FPGATrackSimMultiTruth::Barcode
std::pair< unsigned long, unsigned long > Barcode
Definition: FPGATrackSimMultiTruth.h:49
FPGATrackSimHoughRootOutputTool::m_z
std::vector< float > m_z
Definition: FPGATrackSimHoughRootOutputTool.h:73
FPGATrackSimHoughRootOutputTool::m_offline_n_measurement
std::vector< int > m_offline_n_measurement
Definition: FPGATrackSimHoughRootOutputTool.h:157
FPGATrackSimHoughRootOutputTool::m_candidate_eventindex
float m_candidate_eventindex
Definition: FPGATrackSimHoughRootOutputTool.h:110
FPGATrackSimHoughRootOutputTool::m_candidate_barcodefrac
float m_candidate_barcodefrac
Definition: FPGATrackSimHoughRootOutputTool.h:108
FPGATrackSimHoughRootOutputTool::m_track_hit_z
std::vector< std::vector< float > > m_track_hit_z
Definition: FPGATrackSimHoughRootOutputTool.h:139
FPGATrackSimHoughRootOutputTool::m_invpt
float m_invpt
Definition: FPGATrackSimHoughRootOutputTool.h:103
FPGATrackSimHoughRootOutputTool::m_SUBREGIONMAP
const FPGATrackSimRegionMap * m_SUBREGIONMAP
Definition: FPGATrackSimHoughRootOutputTool.h:66
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
FPGATrackSimHoughRootOutputTool::m_truth_eventindex
std::vector< int > m_truth_eventindex
Definition: FPGATrackSimHoughRootOutputTool.h:135
TrackStage::SECOND
@ SECOND
FPGATrackSimHoughRootOutputTool::m_truthtree
TTree * m_truthtree
Definition: FPGATrackSimHoughRootOutputTool.h:125
FPGATrackSimHoughRootOutputTool::m_offline_q
std::vector< int > m_offline_q
Definition: FPGATrackSimHoughRootOutputTool.h:170
FPGATrackSimHoughRootOutputTool::ResetVectors
void ResetVectors()
Definition: FPGATrackSimHoughRootOutputTool.cxx:539
FPGATrackSimTrack::setTrackCorrType
void setTrackCorrType(TrackCorrType v)
Definition: FPGATrackSimTrack.h:81
FPGATrackSimHoughRootOutputTool::m_truth_d0
std::vector< float > m_truth_d0
Definition: FPGATrackSimHoughRootOutputTool.h:127
FPGATrackSimHoughRootOutputTool::m_gphi
std::vector< float > m_gphi
Definition: FPGATrackSimHoughRootOutputTool.h:78
getComboIndices
std::vector< std::vector< int > > getComboIndices(std::vector< size_t > const &sizes)
Given a vector of sizes (of arrays), generates a vector of all combinations of indices to index one e...
Definition: FPGATrackSimFunctions.cxx:21
FPGATrackSimHoughRootOutputTool::m_etamodule
std::vector< unsigned int > m_etamodule
Definition: FPGATrackSimHoughRootOutputTool.h:89
FPGATrackSimHoughRootOutputTool::m_truth_pdg
std::vector< float > m_truth_pdg
Definition: FPGATrackSimHoughRootOutputTool.h:132
FPGATrackSimHoughRootOutputTool::m_offline_n_perigee
std::vector< int > m_offline_n_perigee
Definition: FPGATrackSimHoughRootOutputTool.h:161
FPGATrackSimTrack::setTrackStage
void setTrackStage(TrackStage v)
Definition: FPGATrackSimTrack.h:82
FPGATrackSimHoughRootOutputTool.h
Output roads into a ROOT file.
FPGATrackSimMultiTruth
Definition: FPGATrackSimMultiTruth.h:46
FPGATrackSimHoughRootOutputTool::m_FPGATrackSimMapping
ServiceHandle< IFPGATrackSimMappingSvc > m_FPGATrackSimMapping
Definition: FPGATrackSimHoughRootOutputTool.h:60
FPGATrackSimMultiTruth::AddAccumulator
Definition: FPGATrackSimMultiTruth.h:57
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
plotBeamSpotMon.b
b
Definition: plotBeamSpotMon.py:77
FPGATrackSimHoughRootOutputTool::m_nMissingHits
std::vector< float > m_nMissingHits
Definition: FPGATrackSimHoughRootOutputTool.h:95
FPGATrackSimHoughRootOutputTool::m_volumeID
std::vector< int > m_volumeID
Definition: FPGATrackSimHoughRootOutputTool.h:74
TrackCorrType::None
@ None
FPGATrackSimFunctions.h
FPGATrackSimHoughRootOutputTool::m_track_hit_isSpacepoint
std::vector< std::vector< bool > > m_track_hit_isSpacepoint
Definition: FPGATrackSimHoughRootOutputTool.h:147
FPGATrackSimTrack::setHoughY
void setHoughY(float v)
Definition: FPGATrackSimTrack.h:91
FPGATrackSimHoughRootOutputTool::m_truth_eta
std::vector< float > m_truth_eta
Definition: FPGATrackSimHoughRootOutputTool.h:130
FPGATrackSimTrack::setQOverPt
void setQOverPt(float v)
Definition: FPGATrackSimTrack.h:92
FPGATrackSimHoughRootOutputTool::m_truth_q
std::vector< int > m_truth_q
Definition: FPGATrackSimHoughRootOutputTool.h:133
FPGATrackSimHoughRootOutputTool::m_offline_n_inertmaterial
std::vector< int > m_offline_n_inertmaterial
Definition: FPGATrackSimHoughRootOutputTool.h:158
FPGATrackSimRoad::getY
float getY() const
Definition: FPGATrackSimRoad.h:87
FPGATrackSimHoughRootOutputTool::m_algo
ORAlgo m_algo
Definition: FPGATrackSimHoughRootOutputTool.h:64
FPGATrackSimHoughRootOutputTool::m_tHistSvc
ServiceHandle< ITHistSvc > m_tHistSvc
Definition: FPGATrackSimHoughRootOutputTool.h:61
FPGATrackSimHoughRootOutputTool::m_EvtSel
ServiceHandle< IFPGATrackSimEventSelectionSvc > m_EvtSel
Definition: FPGATrackSimHoughRootOutputTool.h:59
FPGATrackSimHoughRootOutputTool::m_roadnumber
int m_roadnumber
Definition: FPGATrackSimHoughRootOutputTool.h:122
ORAlgo::InvertGrouping
@ InvertGrouping
FPGATrackSimHoughRootOutputTool::m_barcode
std::vector< unsigned long > m_barcode
Definition: FPGATrackSimHoughRootOutputTool.h:82
FPGATrackSimHoughRootOutputTool::FPGATrackSimHoughRootOutputTool
FPGATrackSimHoughRootOutputTool(const std::string &, const std::string &, const IInterface *)
Definition: FPGATrackSimHoughRootOutputTool.cxx:12
FPGATrackSimHoughRootOutputTool::m_track_hit_x
std::vector< std::vector< float > > m_track_hit_x
Definition: FPGATrackSimHoughRootOutputTool.h:137
getVolumeID
long getVolumeID(const FPGATrackSimHit &hit)
Definition: FPGATrackSimHoughFunctions.cxx:351
a
TList * a
Definition: liststreamerinfos.cxx:10
FPGATrackSimHoughRootOutputTool::m_algorithm
Gaudi::Property< std::string > m_algorithm
Definition: FPGATrackSimHoughRootOutputTool.h:62
FPGATrackSimHoughRootOutputTool::m_offline_barcode
std::vector< int > m_offline_barcode
Definition: FPGATrackSimHoughRootOutputTool.h:171
IFPGATrackSimEventSelectionSvc.h
makeTrackCandidates
void makeTrackCandidates(const FPGATrackSimRoad &road, const FPGATrackSimTrack &temp, std::vector< FPGATrackSimTrack > &track_cands, const ServiceHandle< IFPGATrackSimMappingSvc > &FPGATrackSimMapping)
Creates a list of track candidates by taking all possible combination of hits in road.
Definition: FPGATrackSimHoughFunctions.cxx:287
FPGATrackSimHoughRootOutputTool::m_offline_n_scatterer
std::vector< int > m_offline_n_scatterer
Definition: FPGATrackSimHoughRootOutputTool.h:160
FPGATrackSimHoughRootOutputTool::m_layerID
std::vector< int > m_layerID
Definition: FPGATrackSimHoughRootOutputTool.h:76
FPGATrackSimHoughRootOutputTool::m_fakelabel
unsigned int m_fakelabel
Definition: FPGATrackSimHoughRootOutputTool.h:111
layer_bitmask_t
uint32_t layer_bitmask_t
Definition: FPGATrackSimTypes.h:22
FPGATrackSimHoughRootOutputTool::m_eventindex
std::vector< int > m_eventindex
Definition: FPGATrackSimHoughRootOutputTool.h:83
FPGATrackSimHoughRootOutputTool::m_candidate_barcode
float m_candidate_barcode
Definition: FPGATrackSimHoughRootOutputTool.h:109
FPGATrackSimHoughRootOutputTool::m_offline_n_other
std::vector< int > m_offline_n_other
Definition: FPGATrackSimHoughRootOutputTool.h:163
FPGATrackSimHoughRootOutputTool::m_offline_n_holes
std::vector< int > m_offline_n_holes
Definition: FPGATrackSimHoughRootOutputTool.h:156
FPGATrackSimHoughRootOutputTool::m_offline_pt
std::vector< float > m_offline_pt
Definition: FPGATrackSimHoughRootOutputTool.h:167
FPGATrackSimHoughRootOutputTool::m_tracknumber
int m_tracknumber
Definition: FPGATrackSimHoughRootOutputTool.h:116
FPGATrackSimHoughRootOutputTool::m_track_hit_barcodefrac
std::vector< std::vector< float > > m_track_hit_barcodefrac
Definition: FPGATrackSimHoughRootOutputTool.h:149
FPGATrackSimRoad::getSector
sector_t getSector() const
Definition: FPGATrackSimRoad.h:91
FPGATrackSimHoughRootOutputTool::m_NTracksORMinusRoads
long m_NTracksORMinusRoads
Definition: FPGATrackSimHoughRootOutputTool.h:105
FPGATrackSimRoad::getPID
pid_t getPID() const
Definition: FPGATrackSimRoad.h:90
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
FPGATrackSimHoughRootOutputTool::m_etaID
std::vector< int > m_etaID
Definition: FPGATrackSimHoughRootOutputTool.h:77
FPGATrackSimHoughRootOutputTool::m_offline_barcodefrac
std::vector< float > m_offline_barcodefrac
Definition: FPGATrackSimHoughRootOutputTool.h:172
FPGATrackSimHoughRootOutputTool::m_phimodule
std::vector< unsigned int > m_phimodule
Definition: FPGATrackSimHoughRootOutputTool.h:90
OfflineHitType::Scatterer
@ Scatterer
AthAlgTool
Definition: AthAlgTool.h:26
FPGATrackSimTrack::setNLayers
void setNLayers(int)
set the number of layers in the track.
Definition: FPGATrackSimTrack.cxx:108
FPGATrackSimHoughRootOutputTool::m_mapped
std::vector< bool > m_mapped
Definition: FPGATrackSimHoughRootOutputTool.h:96
FPGATrackSimHoughRootOutputTool::m_IdealCoordFitType
TrackCorrType m_IdealCoordFitType
Definition: FPGATrackSimHoughRootOutputTool.h:67
FPGATrackSimHoughRootOutputTool::m_ID
std::vector< unsigned int > m_ID
Definition: FPGATrackSimHoughRootOutputTool.h:91
FPGATrackSimHoughRootOutputTool::m_track_hit_isStrip
std::vector< std::vector< bool > > m_track_hit_isStrip
Definition: FPGATrackSimHoughRootOutputTool.h:145
FPGATrackSimHoughRootOutputTool::m_truth_barcode
std::vector< int > m_truth_barcode
Definition: FPGATrackSimHoughRootOutputTool.h:134
FPGATrackSimTrack::getHoughX
float getHoughX() const
Definition: FPGATrackSimTrack.h:35
OfflineHitType::Outlier
@ Outlier
FPGATrackSimHoughRootOutputTool::m_track_hit_isPixel
std::vector< std::vector< bool > > m_track_hit_isPixel
Definition: FPGATrackSimHoughRootOutputTool.h:144
FPGATrackSimHoughRootOutputTool::m_y
std::vector< float > m_y
Definition: FPGATrackSimHoughRootOutputTool.h:72
FPGATrackSimHoughRootOutputTool::m_tree
TTree * m_tree
Definition: FPGATrackSimHoughRootOutputTool.h:70
getMissingInfo
void getMissingInfo(const FPGATrackSimRoad &road, int &nMissing, bool &missPixel, bool &missStrip, layer_bitmask_t &missing_mask, layer_bitmask_t &norecovery_mask, const ServiceHandle< IFPGATrackSimMappingSvc > &FPGATrackSimMapping, const TrackCorrType idealCoordFitType)
Definition: FPGATrackSimHoughFunctions.cxx:225
FPGATrackSimHoughRootOutputTool::m_truth_pt
std::vector< float > m_truth_pt
Definition: FPGATrackSimHoughRootOutputTool.h:129
FPGATrackSimHoughRootOutputTool::m_custom_layerID
std::vector< int > m_custom_layerID
Definition: FPGATrackSimHoughRootOutputTool.h:75
runOverlapRemoval
StatusCode runOverlapRemoval(std::vector< FPGATrackSimTrack > &tracks, const float minChi2, const int NumOfHitPerGrouping, ORAlgo orAlgo)
Definition: FPGATrackSimHoughFunctions.cxx:12
FPGATrackSimTrack::setHoughX
void setHoughX(float v)
Definition: FPGATrackSimTrack.h:90
FPGATrackSimRegionMap::getAvgRadius
double getAvgRadius(unsigned region, unsigned layer) const
Definition: FPGATrackSimRegionMap.cxx:373
FPGATrackSimHoughRootOutputTool::bookTree
StatusCode bookTree()
Definition: FPGATrackSimHoughRootOutputTool.cxx:35
FPGATrackSimMultiTruth::assign_equal_normalization
void assign_equal_normalization()
Definition: FPGATrackSimMultiTruth.cxx:69
FPGATrackSimHoughRootOutputTool::m_zIdeal
std::vector< float > m_zIdeal
Definition: FPGATrackSimHoughRootOutputTool.h:79