ACTS
Experiment-independent tracking
Loading...
Searching...
No Matches
Acts::GridBinFinder< DIM > Class Template Reference

#include <Acts/Utilities/GridBinFinder.hpp>

Public Types

using stored_values_t
 Type alias for variant storing different bin finding configurations.

Public Member Functions

template<typename... args>
requires ( sizeof...(args) == DIM && (Concepts::same_as_any_of<std::decay_t<args>, int, std::pair<int, int>, std::vector<std::pair<int, int>>> && ...))
 GridBinFinder (args &&... vals)
 Constructor that takes the individual values for each axis.
 GridBinFinder (std::array< stored_values_t, DIM > values)
 Constructor that takes an array of axes values.
template<typename stored_t, class... Axes>
boost::container::small_vector< std::size_t, dimCubedfindBins (const std::array< std::size_t, DIM > &locPosition, const Grid< stored_t, Axes... > &grid) const
 Retrieve the neighbouring bins given a local position in the grid.
const std::array< stored_values_t, DIM > & values () const
 Get the stored bin edge values for all dimensions.

Static Public Attributes

static constexpr std::size_t dimCubed = detail::ipow(3, DIM)
 Number of neighbor bins in 3^DIM grid configuration.

Detailed Description

template<std::size_t DIM>
class Acts::GridBinFinder< DIM >
Template Parameters
DIMDimension of the Grid on which the GridBinFinder will be used

The GridBinFinder is used by the ISPGroupSelector. It can be used to find both bins that could be bottom bins as well as bins that could be top bins, which are assumed to be the same bins. Does not take interaction region into account to limit z-bins.

Member Typedef Documentation

◆ stored_values_t

template<std::size_t DIM>
using Acts::GridBinFinder< DIM >::stored_values_t
Initial value:
std::variant<int, std::pair<int, int>, std::vector<std::pair<int, int>>>

Type alias for variant storing different bin finding configurations.

Constructor & Destructor Documentation

◆ GridBinFinder() [1/2]

template<std::size_t DIM>
template<typename... args>
requires ( sizeof...(args) == DIM && (Concepts::same_as_any_of<std::decay_t<args>, int, std::pair<int, int>, std::vector<std::pair<int, int>>> && ...))
Acts::GridBinFinder< DIM >::GridBinFinder ( args &&... vals)
explicit

Constructor that takes the individual values for each axis.

Template Parameters
args... Input parameters provided by the user
Parameters
[in]valsThe input parameters that define how many neighbours we need to find
Precondition
The provided parameters must be of type 'int', 'std::pair<int, int>' or 'std::vector<std::pair<int, int>>' no other type is allowed. The order of these parameters must correspond to the same ordering of the axes in the grid

◆ GridBinFinder() [2/2]

template<std::size_t DIM>
Acts::GridBinFinder< DIM >::GridBinFinder ( std::array< stored_values_t, DIM > values)
explicit

Constructor that takes an array of axes values.

Parameters
[in]valuesThe array of stored values that define how many neighbours we need to find

Member Function Documentation

◆ findBins()

template<std::size_t DIM>
template<typename stored_t, class... Axes>
boost::container::small_vector< std::size_t, dimCubed > Acts::GridBinFinder< DIM >::findBins ( const std::array< std::size_t, DIM > & locPosition,
const Grid< stored_t, Axes... > & grid ) const

Retrieve the neighbouring bins given a local position in the grid.

Return all bins that could contain space points that can be used with the space points in the bin with the provided indices to create seeds.

Template Parameters
stored_tThe type of elements stored in the Grid
Axes... The type of the axes of the grid
Parameters
[in]locPositionThe N-dimentional local position in the grid
[in]gridThe grid
Returns
The list of neighbouring bins
Precondition
The provided local position must be a valid local bins configuration in the grid

◆ values()

template<std::size_t DIM>
const std::array< stored_values_t, DIM > & Acts::GridBinFinder< DIM >::values ( ) const

Get the stored bin edge values for all dimensions.

Returns
Array of bin edge values for each dimension

Member Data Documentation

◆ dimCubed

template<std::size_t DIM>
std::size_t Acts::GridBinFinder< DIM >::dimCubed = detail::ipow(3, DIM)
staticconstexpr

Number of neighbor bins in 3^DIM grid configuration.