|
ACTS
Experiment-independent tracking
|
Provides Surface binning in 2 dimensions. More...
#include <Acts/Surfaces/SurfaceArray.hpp>
Classes | |
| struct | ISurfaceGridLookup |
| Base interface for all surface lookups. More... | |
| struct | SingleElementLookup |
| Lookup implementation which wraps one element and always returns this element when lookup is called. More... | |
| struct | SurfaceGridLookup |
Lookup helper which encapsulates a Grid. More... | |
Public Member Functions | |
| SurfaceArray (const GeometryContext &gctx, std::vector< std::shared_ptr< const Surface > > surfaces, std::shared_ptr< RegularSurface > representative, double tolerance, std::tuple< const IAxis &, const IAxis & > axes) | |
| Constructor to create a surface grid lookup for a given representative surface, tolerance, and axes. | |
| SurfaceArray (std::shared_ptr< const Surface > srf) | |
| Constructor with a single surface. | |
| SurfaceArray (std::unique_ptr< ISurfaceGridLookup > gridLookup, std::vector< std::shared_ptr< const Surface > > surfaces, const Transform3 &transform=Transform3::Identity()) | |
Default constructor which takes a SurfaceLookup and a vector of surfaces. | |
| std::span< const Surface *const > | at (const GeometryContext &gctx, const Vector3 &position, const Vector3 &direction) const |
Get all surfaces in bin given by position pos. | |
| const std::vector< const Surface * > & | at (const Vector3 &position, const Vector3 &direction) const |
Get all surfaces in bin given by position pos. | |
| std::span< const Surface *const > | at (std::array< std::size_t, 2 > gridIndices, std::uint8_t neighborDistance) const |
| Get all surfaces in bin given by local grid indices and neighbor distance. | |
| std::vector< const Surface * > & | at (std::size_t bin) |
Get all surfaces in bin given by global bin index bin. | |
| const std::vector< const Surface * > & | at (std::size_t bin) const |
| Get all surfaces in bin given by global bin index. | |
| std::vector< AxisDirection > | binningValues () const |
| The binning values described by this surface grid lookup. | |
| std::vector< const IAxis * > | getAxes () const |
Get vector of axes spanning the grid as AnyAxis. | |
| Vector3 | getBinCenter (std::size_t bin) const |
Get the center of the bin identified by global bin index bin. | |
| const ISurfaceGridLookup & | gridLookup () const |
| Return the lookup object. | |
| bool | isValidBin (std::size_t bin) const |
| Checks if global bin is valid. | |
| std::uint8_t | maxNeighborDistance () const |
| Get the maximum neighbor distance that is supported by this lookup. | |
| std::span< const Surface *const > | neighbors (const GeometryContext &gctx, const Vector3 &position, const Vector3 &direction) const |
Get all surfaces in bin at pos and its neighbors. | |
| const std::vector< const Surface * > & | neighbors (const Vector3 &position, const Vector3 &direction) const |
Get all surfaces in bin at pos and its neighbors. | |
| std::array< std::size_t, 2 > | numLocalBins () const |
| Get the number of local bins in each dimension. | |
| std::size_t | size () const |
| Get the size of the underlying grid structure including under/overflow bins. | |
| const Surface * | surfaceRepresentation () const |
| Get the representative surface used for this surface array. | |
| const std::vector< const Surface * > & | surfaces () const |
Get all surfaces attached to this SurfaceArray. | |
| std::ostream & | toStream (const GeometryContext &gctx, std::ostream &sl) const |
Get string representation of this SurfaceArray. | |
| const Transform3 & | transform () const |
| Get the transform of this surface array. | |
Provides Surface binning in 2 dimensions.
Uses Grid under the hood to implement the storage and lookup Contains a lookup struct which talks to the Grid and performs utility actions. This struct needs to be initialised externally and passed to SurfaceArray on construction.
| Acts::SurfaceArray::SurfaceArray | ( | std::unique_ptr< ISurfaceGridLookup > | gridLookup, |
| std::vector< std::shared_ptr< const Surface > > | surfaces, | ||
| const Transform3 & | transform = Transform3::Identity() ) |
Default constructor which takes a SurfaceLookup and a vector of surfaces.
| gridLookup | The grid storage. SurfaceArray does not fill it on its own |
| surfaces | The input vector of surfaces. This is only for bookkeeping, so we can ask |
| transform | Optional additional transform for this SurfaceArray |
|
explicit |
Constructor with a single surface.
| srf | The one and only surface |
| Acts::SurfaceArray::SurfaceArray | ( | const GeometryContext & | gctx, |
| std::vector< std::shared_ptr< const Surface > > | surfaces, | ||
| std::shared_ptr< RegularSurface > | representative, | ||
| double | tolerance, | ||
| std::tuple< const IAxis &, const IAxis & > | axes ) |
Constructor to create a surface grid lookup for a given representative surface, tolerance, and axes.
| gctx | The current geometry context object, e.g. alignment |
| surfaces | The input vector of surfaces that will be accessible through this SurfaceArray. |
| representative | The surface which is used as representative |
| tolerance | The tolerance used for intersection checks |
| axes | The axes used for the grid |
| std::span< const Surface *const > Acts::SurfaceArray::at | ( | const GeometryContext & | gctx, |
| const Vector3 & | position, | ||
| const Vector3 & | direction ) const |
Get all surfaces in bin given by position pos.
| gctx | The current geometry context object, e.g. alignment |
| position | the lookup position |
| direction | the lookup direction |
| const std::vector< const Surface * > & Acts::SurfaceArray::at | ( | const Vector3 & | position, |
| const Vector3 & | direction ) const |
Get all surfaces in bin given by position pos.
| position | the lookup position |
| direction | the lookup direction |
| std::span< const Surface *const > Acts::SurfaceArray::at | ( | std::array< std::size_t, 2 > | gridIndices, |
| std::uint8_t | neighborDistance ) const |
Get all surfaces in bin given by local grid indices and neighbor distance.
| gridIndices | the local grid indices |
| neighborDistance | the neighbor distance to include in the lookup |
| std::vector< const Surface * > & Acts::SurfaceArray::at | ( | std::size_t | bin | ) |
Get all surfaces in bin given by global bin index bin.
| bin | the global bin index |
| const std::vector< const Surface * > & Acts::SurfaceArray::at | ( | std::size_t | bin | ) | const |
Get all surfaces in bin given by global bin index.
| bin | the global bin index |
| std::vector< AxisDirection > Acts::SurfaceArray::binningValues | ( | ) | const |
The binning values described by this surface grid lookup.
They are in order of the axes
| std::vector< const IAxis * > Acts::SurfaceArray::getAxes | ( | ) | const |
Get vector of axes spanning the grid as AnyAxis.
AnyAxis | Vector3 Acts::SurfaceArray::getBinCenter | ( | std::size_t | bin | ) | const |
Get the center of the bin identified by global bin index bin.
| bin | the global bin index |
| const ISurfaceGridLookup & Acts::SurfaceArray::gridLookup | ( | ) | const |
Return the lookup object.
| bool Acts::SurfaceArray::isValidBin | ( | std::size_t | bin | ) | const |
Checks if global bin is valid.
| bin | the global bin index |
| std::uint8_t Acts::SurfaceArray::maxNeighborDistance | ( | ) | const |
Get the maximum neighbor distance that is supported by this lookup.
This is used to determine how many neighbors to include in neighbor lookups.
| std::span< const Surface *const > Acts::SurfaceArray::neighbors | ( | const GeometryContext & | gctx, |
| const Vector3 & | position, | ||
| const Vector3 & | direction ) const |
Get all surfaces in bin at pos and its neighbors.
| gctx | The current geometry context object, e.g. alignment |
| position | The position to lookup |
| direction | The direction to lookup |
| const std::vector< const Surface * > & Acts::SurfaceArray::neighbors | ( | const Vector3 & | position, |
| const Vector3 & | direction ) const |
Get all surfaces in bin at pos and its neighbors.
| position | The position to lookup |
| direction | The direction to lookup |
| std::array< std::size_t, 2 > Acts::SurfaceArray::numLocalBins | ( | ) | const |
Get the number of local bins in each dimension.
This is used to determine the size of the grid for neighbor lookups.
| std::size_t Acts::SurfaceArray::size | ( | ) | const |
Get the size of the underlying grid structure including under/overflow bins.
| const Surface * Acts::SurfaceArray::surfaceRepresentation | ( | ) | const |
Get the representative surface used for this surface array.
| const std::vector< const Surface * > & Acts::SurfaceArray::surfaces | ( | ) | const |
Get all surfaces attached to this SurfaceArray.
| std::ostream & Acts::SurfaceArray::toStream | ( | const GeometryContext & | gctx, |
| std::ostream & | sl ) const |
Get string representation of this SurfaceArray.
| gctx | The current geometry context object, e.g. alignment |
| sl | Output stream to write to |
sl | const Transform3 & Acts::SurfaceArray::transform | ( | ) | const |
Get the transform of this surface array.