ATLAS Offline Software
HoughEventData.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef MUONR4_MUONPATTERNRECOGNITIONEVENT_MUONHOUGHEVENTDATA__H
6 #define MUONR4_MUONPATTERNRECOGNITIONEVENT_MUONHOUGHEVENTDATA__H
7 
10 #include "Acts/Seeding/HoughTransformUtils.hpp"
13 #include <unordered_map>
14 #include <memory>
15 
16 namespace MuonR4{
17 
21  template <typename peakFinder_t, typename peakFinderConfig_t>
23  HoughEventData_impl() = default;
24 
29  inline static void updateSearchWindow(std::pair<double,double> & searchWindow, double value){
30  searchWindow.first = std::min(searchWindow.first, value);
31  searchWindow.second = std::max(searchWindow.second, value);
32  }
33 
34  // Hough accumulator
35  std::unique_ptr<HoughPlane> houghPlane{nullptr};
36  // peak finder instance
37  std::unique_ptr<peakFinder_t> peakFinder{nullptr};
41  // Bucket containing the input space points
42  const SpacePointBucket* bucket{nullptr};
43  // placeholder boundary for the search space
44  static constexpr double dummyBoundary{1.e9};
45  // search window for the intercept, optimised for the bucket
46  std::pair<double, double> searchWindowIntercept{dummyBoundary, -dummyBoundary};
47  // search window for the angle, optimised for the bucket
48  std::pair<double, double> searchWindowTanAngle{dummyBoundary, -dummyBoundary};
49 
51  void updateHoughWindow(double interceptMeas, double TanAngleMeas) {
54  }
55  };
56  // the maxima found by the hough transform
57  std::vector<HoughMaximum> maxima{};
58  // the hough setup for each logical muon chamber
59  std::unordered_map<const MuonGMR4::SpectrometerSector*, std::vector<HoughSetupForBucket>> houghSetups{};
60  // the axis ranges currently mapped to the accumulator
61  Acts::HoughTransformUtils::HoughAxisRanges currAxisRanges;
62  // current search window for the intercept
63  std::pair<double,double> searchSpaceIntercept{10000000,-100000000.};
64  // current search window for the angle
65  std::pair<double,double> searchSpaceTanAngle{100000000.,-100000.};
66  // hit counter for phi-measurements
67  size_t phiHitsOnMax{0};
68  };
69 
70  // for now, we use one common (default ACTS) peak finder for both the eta- and the phi-transforms.
72 
73 }
74 
75 #endif
UncalibratedMeasurement.h
max
#define max(a, b)
Definition: cfImp.cxx:41
MuonR4::HoughEventData_impl::peakFinder
std::unique_ptr< peakFinder_t > peakFinder
Definition: HoughEventData.h:37
MuonR4::SpacePointBucket
: The muon space point bucket represents a collection of points that will bre processed together in t...
Definition: MuonSpectrometer/MuonPhaseII/Event/MuonSpacePoint/MuonSpacePoint/SpacePointContainer.h:21
MuonR4::HoughEventData_impl::phiHitsOnMax
size_t phiHitsOnMax
Definition: HoughEventData.h:67
MuonR4::HoughEventData_impl::searchSpaceTanAngle
std::pair< double, double > searchSpaceTanAngle
Definition: HoughEventData.h:65
MuonR4::HoughEventData_impl::HoughSetupForBucket::updateHoughWindow
void updateHoughWindow(double interceptMeas, double TanAngleMeas)
Update the hough space search window.
Definition: HoughEventData.h:51
MuonR4::HoughEventData_impl::houghSetups
std::unordered_map< const MuonGMR4::SpectrometerSector *, std::vector< HoughSetupForBucket > > houghSetups
Definition: HoughEventData.h:59
MuonR4::HoughEventData_impl::HoughSetupForBucket::searchWindowIntercept
std::pair< double, double > searchWindowIntercept
Definition: HoughEventData.h:46
MuonR4::HoughEventData_impl::HoughSetupForBucket::dummyBoundary
static constexpr double dummyBoundary
Definition: HoughEventData.h:44
athena.value
value
Definition: athena.py:124
MuonR4::HoughEventData_impl::maxima
std::vector< HoughMaximum > maxima
Definition: HoughEventData.h:57
GeoPrimitives.h
MuonR4::HoughEventData_impl::searchSpaceIntercept
std::pair< double, double > searchSpaceIntercept
Definition: HoughEventData.h:63
MuonR4::HoughEventData_impl::HoughSetupForBucket::bucket
const SpacePointBucket * bucket
Definition: HoughEventData.h:42
MuonR4::HoughEventData_impl::currAxisRanges
Acts::HoughTransformUtils::HoughAxisRanges currAxisRanges
Definition: HoughEventData.h:61
min
#define min(a, b)
Definition: cfImp.cxx:40
MuonR4::HoughEventData_impl::HoughSetupForBucket
Hough transform configuration for one bucket of the search space.
Definition: HoughEventData.h:40
MuonHoughDefs.h
MuonR4::HoughEventData_impl::HoughEventData_impl
HoughEventData_impl()=default
MuonR4
This header ties the generic definitions in this package.
Definition: HoughEventData.h:16
MuonR4::HoughEventData_impl::HoughSetupForBucket::searchWindowTanAngle
std::pair< double, double > searchWindowTanAngle
Definition: HoughEventData.h:48
MuonR4::HoughEventData_impl::houghPlane
std::unique_ptr< HoughPlane > houghPlane
Definition: HoughEventData.h:35
MuonR4::HoughEventData_impl::updateSearchWindow
static void updateSearchWindow(std::pair< double, double > &searchWindow, double value)
Updates a search space window to account for a value.
Definition: HoughEventData.h:29
MuonR4::HoughEventData_impl
Templated event data class for the phase-2 muon hough transform.
Definition: HoughEventData.h:22