|
ACTS
Experiment-independent tracking
|
Representation of the hough plane - the histogram used for the hough transform with methods to fill and evaluate the histogram. More...
#include <Acts/Seeding/HoughTransformUtils.hpp>
Public Types | |
| using | Axis |
| hough histogram representation as a 2D-indexable vector of hough cells | |
| using | HoughHist = Grid<HoughCell<identifier_t>, Axis, Axis> |
| Type alias for Hough histogram grid. | |
| using | Index = typename HoughHist::index_t |
| Type alias for histogram index type. | |
Public Member Functions | |
| HoughPlane (const HoughPlaneConfig &cfg) | |
| instantiate the (empty) hough plane | |
| Index | axisBins (std::size_t globalBin) const |
| get the coordinates of the bin given the global bin index | |
| template<class PointType> | |
| void | fill (const PointType &measurement, const HoughAxisRanges &axisRanges, LineParametrisation< PointType > linePar, LineParametrisation< PointType > widthPar, const identifier_t &identifier, unsigned layer=0, YieldType weight=1.0f) |
| fill and reset methods to modify the grid content | |
| void | fillBin (std::size_t binX, std::size_t binY, const identifier_t &identifier, unsigned layer, double w=1.0f) |
| Helper method to fill a bin of the hough histogram. | |
| const std::unordered_set< std::size_t > & | getNonEmptyBins () const |
| get the list of cells with non-zero content. | |
| std::size_t | globalBin (Index indexBin) const |
| get the globalBin index given the coordinates of the bin | |
| std::span< const identifier_t, std::dynamic_extent > | hitIds (std::size_t xBin, std::size_t yBin) const |
| get the identifiers of all hits in one cell of the histogram | |
| std::span< const unsigned, std::dynamic_extent > | layers (std::size_t xBin, std::size_t yBin) const |
| get the layers with hits in one cell of the histogram | |
| std::pair< std::size_t, std::size_t > | locMaxHits () const |
| get the bin indices of the cell containing the largest number of (weighted) hits across the entire histogram | |
| std::pair< std::size_t, std::size_t > | locMaxLayers () const |
| get the bin indices of the cell containing the largest number of (weighted) layers with hits across the entire histogram | |
| YieldType | maxHits () const |
| get the maximum number of (weighted) hits seen in a single cell across the entire histrogram. | |
| YieldType | maxLayers () const |
| get the maximum number of (weighted) layers with hits seen in a single cell across the entire histrogram. | |
| std::size_t | nBinsX () const |
| get the number of bins on the first coordinate | |
| std::size_t | nBinsY () const |
| get the number of bins on the second coordinate | |
| YieldType | nHits (std::size_t globalBin) const |
| access the (weighted) number of hits in one cell of the histogram from globalBin index | |
| YieldType | nHits (std::size_t xBin, std::size_t yBin) const |
| access the (weighted) number of hits in one cell of the histogram from bin's coordinates | |
| YieldType | nLayers (std::size_t xBin, std::size_t yBin) const |
| get the (weighted) number of layers with hits in one cell of the histogram | |
| void | reset () |
| resets the contents of the grid. | |
| std::unordered_set< const identifier_t > | uniqueHitIds (std::size_t xBin, std::size_t yBin) const |
| get the identifiers of all hits in one cell of the histogram | |
Representation of the hough plane - the histogram used for the hough transform with methods to fill and evaluate the histogram.
Templated to a class used as identifier for the hits
| using Acts::HoughTransformUtils::HoughPlane< identifier_t >::Axis |
hough histogram representation as a 2D-indexable vector of hough cells
| using Acts::HoughTransformUtils::HoughPlane< identifier_t >::HoughHist = Grid<HoughCell<identifier_t>, Axis, Axis> |
Type alias for Hough histogram grid.
| using Acts::HoughTransformUtils::HoughPlane< identifier_t >::Index = typename HoughHist::index_t |
Type alias for histogram index type.
|
explicit |
instantiate the (empty) hough plane
| cfg | configuration |
| Index Acts::HoughTransformUtils::HoughPlane< identifier_t >::axisBins | ( | std::size_t | globalBin | ) | const |
get the coordinates of the bin given the global bin index
| globalBin | Global bin index to convert to coordinates |
| void Acts::HoughTransformUtils::HoughPlane< identifier_t >::fill | ( | const PointType & | measurement, |
| const HoughAxisRanges & | axisRanges, | ||
| LineParametrisation< PointType > | linePar, | ||
| LineParametrisation< PointType > | widthPar, | ||
| const identifier_t & | identifier, | ||
| unsigned | layer = 0, | ||
| YieldType | weight = 1.0f ) |
fill and reset methods to modify the grid content
add one measurement to the hough plane
| PointType | Type of the objects to use when adding measurements (e.g. experiment EDM object) |
| measurement | The measurement to add |
| axisRanges | Ranges of the hough axes, used to map the bin numbers to parameter values |
| linePar | The function y(x) parametrising the hough space line for a given measurement |
| widthPar | The function dy(x) parametrising the width of the y(x) curve for a given measurement |
| identifier | The unique identifier for the given hit |
| layer | A layer index for this hit |
| weight | An optional weight to assign to this hit |
| void Acts::HoughTransformUtils::HoughPlane< identifier_t >::fillBin | ( | std::size_t | binX, |
| std::size_t | binY, | ||
| const identifier_t & | identifier, | ||
| unsigned | layer, | ||
| double | w = 1.0f ) |
Helper method to fill a bin of the hough histogram.
Updates the internal helper data structures (maximum tracker etc).
| binX | bin number along x |
| binY | bin number along y |
| identifier | hit identifier |
| layer | layer index |
| w | optional hit weight |
| const std::unordered_set< std::size_t > & Acts::HoughTransformUtils::HoughPlane< identifier_t >::getNonEmptyBins | ( | ) | const |
get the list of cells with non-zero content.
Useful for peak-finders in sparse data to avoid looping over all cells
| std::size_t Acts::HoughTransformUtils::HoughPlane< identifier_t >::globalBin | ( | Index | indexBin | ) | const |
get the globalBin index given the coordinates of the bin
| indexBin | Bin coordinates to convert to global index |
| std::span< const identifier_t, std::dynamic_extent > Acts::HoughTransformUtils::HoughPlane< identifier_t >::hitIds | ( | std::size_t | xBin, |
| std::size_t | yBin ) const |
get the identifiers of all hits in one cell of the histogram
| xBin | bin index in the first coordinate |
| yBin | bin index in the second coordinate |
| out | of range if indices are not within plane limits |
| std::span< const unsigned, std::dynamic_extent > Acts::HoughTransformUtils::HoughPlane< identifier_t >::layers | ( | std::size_t | xBin, |
| std::size_t | yBin ) const |
get the layers with hits in one cell of the histogram
| xBin | bin index in the first coordinate |
| yBin | bin index in the second coordinate |
| out | of range if indices are not within plane limits |
| std::pair< std::size_t, std::size_t > Acts::HoughTransformUtils::HoughPlane< identifier_t >::locMaxHits | ( | ) | const |
get the bin indices of the cell containing the largest number of (weighted) hits across the entire histogram
| std::pair< std::size_t, std::size_t > Acts::HoughTransformUtils::HoughPlane< identifier_t >::locMaxLayers | ( | ) | const |
get the bin indices of the cell containing the largest number of (weighted) layers with hits across the entire histogram
| YieldType Acts::HoughTransformUtils::HoughPlane< identifier_t >::maxHits | ( | ) | const |
get the maximum number of (weighted) hits seen in a single cell across the entire histrogram.
| YieldType Acts::HoughTransformUtils::HoughPlane< identifier_t >::maxLayers | ( | ) | const |
get the maximum number of (weighted) layers with hits seen in a single cell across the entire histrogram.
| std::size_t Acts::HoughTransformUtils::HoughPlane< identifier_t >::nBinsX | ( | ) | const |
get the number of bins on the first coordinate
| std::size_t Acts::HoughTransformUtils::HoughPlane< identifier_t >::nBinsY | ( | ) | const |
get the number of bins on the second coordinate
| YieldType Acts::HoughTransformUtils::HoughPlane< identifier_t >::nHits | ( | std::size_t | globalBin | ) | const |
access the (weighted) number of hits in one cell of the histogram from globalBin index
| globalBin | global bin index |
| YieldType Acts::HoughTransformUtils::HoughPlane< identifier_t >::nHits | ( | std::size_t | xBin, |
| std::size_t | yBin ) const |
access the (weighted) number of hits in one cell of the histogram from bin's coordinates
| xBin | bin index in the first coordinate |
| yBin | bin index in the second coordinate |
| out | of range if indices are not within plane limits |
| YieldType Acts::HoughTransformUtils::HoughPlane< identifier_t >::nLayers | ( | std::size_t | xBin, |
| std::size_t | yBin ) const |
get the (weighted) number of layers with hits in one cell of the histogram
| xBin | bin index in the first coordinate |
| yBin | bin index in the second coordinate |
| out | of range if indices are not within plane limits |
| void Acts::HoughTransformUtils::HoughPlane< identifier_t >::reset | ( | ) |
resets the contents of the grid.
Can be used to avoid reallocating the histogram when switching regions / (sub)detectors
| std::unordered_set< const identifier_t > Acts::HoughTransformUtils::HoughPlane< identifier_t >::uniqueHitIds | ( | std::size_t | xBin, |
| std::size_t | yBin ) const |
get the identifiers of all hits in one cell of the histogram
| xBin | bin index in the first coordinate |
| yBin | bin index in the second coordinate |
| out | of range if indices are not within plane limits |