ECCE @ EIC Software
Reference for
ECCE @ EIC
simulation and reconstruction software on GitHub
|
#include <acts/blob/master/Core/include/Acts/Geometry/SurfaceArrayCreator.hpp>
Classes | |
struct | Config |
struct | ProtoAxis |
Public Member Functions | |
SurfaceArrayCreator (std::unique_ptr< const Logger > logger=getDefaultLogger("SurfaceArrayCreator", Logging::INFO)) | |
SurfaceArrayCreator (const Config &cfg, std::unique_ptr< const Logger > logger=getDefaultLogger("SurfaceArrayCreator", Logging::INFO)) | |
virtual | ~SurfaceArrayCreator ()=default |
Destructor. | |
std::unique_ptr< SurfaceArray > | surfaceArrayOnCylinder (const GeometryContext &gctx, std::vector< std::shared_ptr< const Surface >> surfaces, size_t binsPhi, size_t binsZ, std::optional< ProtoLayer > protoLayerOpt=std::nullopt, const std::shared_ptr< const Transform3D > &transformOpt=nullptr) const |
std::unique_ptr < Acts::SurfaceArray > | surfaceArrayOnCylinder (const GeometryContext &gctx, std::vector< std::shared_ptr< const Surface >> surfaces, BinningType bTypePhi=equidistant, BinningType bTypeZ=equidistant, std::optional< ProtoLayer > protoLayerOpt=std::nullopt, const std::shared_ptr< const Transform3D > &transformOpt=nullptr) const |
std::unique_ptr< SurfaceArray > | surfaceArrayOnDisc (const GeometryContext &gctx, std::vector< std::shared_ptr< const Surface >> surfaces, size_t binsR, size_t binsPhi, std::optional< ProtoLayer > protoLayerOpt=std::nullopt, const std::shared_ptr< const Transform3D > &transformOpt=nullptr) const |
std::unique_ptr < Acts::SurfaceArray > | surfaceArrayOnDisc (const GeometryContext &gctx, std::vector< std::shared_ptr< const Surface >> surfaces, BinningType bTypeR, BinningType bTypePhi, std::optional< ProtoLayer > protoLayerOpt=std::nullopt, const std::shared_ptr< const Transform3D > &transformOpt=nullptr) const |
std::unique_ptr< SurfaceArray > | surfaceArrayOnPlane (const GeometryContext &gctx, std::vector< std::shared_ptr< const Surface >> surfaces, size_t bins1, size_t bins2, BinningValue bValue, std::optional< ProtoLayer > protoLayerOpt=std::nullopt, const std::shared_ptr< const Transform3D > &transformOpt=nullptr) const |
SurfaceArrayCreator interface method - create an array on a plane. | |
void | setLogger (std::unique_ptr< const Logger > logger) |
Static Public Member Functions | |
static bool | isSurfaceEquivalent (const GeometryContext &gctx, BinningValue bValue, const Surface *a, const Surface *b) |
Private Member Functions | |
const Logger & | logger () const |
Private access to logger. | |
std::vector< const Surface * > | findKeySurfaces (const std::vector< const Surface * > &surfaces, const std::function< bool(const Surface *, const Surface *)> &equal) const |
size_t | determineBinCount (const GeometryContext &gctx, const std::vector< const Surface * > &surfaces, BinningValue bValue) const |
ProtoAxis | createVariableAxis (const GeometryContext &gctx, const std::vector< const Surface * > &surfaces, BinningValue bValue, ProtoLayer protoLayer, Transform3D &transform) const |
ProtoAxis | createEquidistantAxis (const GeometryContext &gctx, const std::vector< const Surface * > &surfaces, BinningValue bValue, ProtoLayer protoLayer, Transform3D &transform, size_t nBins=0) const |
void | completeBinning (const GeometryContext &gctx, SurfaceArray::ISurfaceGridLookup &sl, const std::vector< const Surface * > &surfaces) const |
std::vector< Acts::Vector3D > | makeGlobalVertices (const GeometryContext &gctx, const Acts::Surface &surface, const std::vector< Acts::Vector2D > &locVertices) const |
Static Private Member Functions | |
template<detail::AxisBoundaryType bdtA, detail::AxisBoundaryType bdtB, typename F1 , typename F2 > | |
static std::unique_ptr < SurfaceArray::ISurfaceGridLookup > | makeSurfaceGridLookup2D (F1 globalToLocal, F2 localToGlobal, ProtoAxis pAxisA, ProtoAxis pAxisB) |
Creates a SurfaceGridLookup instance within an any This is essentially a factory which absorbs some if/else logic that is required by the templating. | |
Private Attributes | |
Config | m_cfg |
configuration object | |
std::unique_ptr< const Logger > | m_logger |
logging instance | |
It is designed create sub surface arrays to be ordered on Surfaces
Definition at line 45 of file SurfaceArrayCreator.hpp.
View newest version in sPHENIX GitHub at line 45 of file SurfaceArrayCreator.hpp
|
inline |
Constructor with default config
logger | logging instance |
Definition at line 87 of file SurfaceArrayCreator.hpp.
View newest version in sPHENIX GitHub at line 87 of file SurfaceArrayCreator.hpp
|
inline |
Constructor with explicit config
cfg | Explicit config struct |
logger | logging instance |
Definition at line 94 of file SurfaceArrayCreator.hpp.
View newest version in sPHENIX GitHub at line 94 of file SurfaceArrayCreator.hpp
|
virtualdefault |
Destructor.
|
inlineprivate |
Private helper method to complete the binning
given a grid point o
0 | x | | | | x | 1 | | | o | | | 2 | x | | | | x |
This is being called when you chose to use more bins thans surfaces I.e. to put a finer granularity binning onto your surface Neighbour bins are then filled to contain pointers as well This method delegates to SurfaceGridLookup itself.
[in] | gctx | the geometry context for this call |
sl | The SurfaceGridLookup | |
surfaces | the surfaces |
Definition at line 424 of file SurfaceArrayCreator.hpp.
View newest version in sPHENIX GitHub at line 424 of file SurfaceArrayCreator.hpp
References ACTS_VERBOSE, and Acts::SurfaceArray::ISurfaceGridLookup::completeBinning().
Referenced by surfaceArrayOnCylinder().
|
private |
SurfaceArrayCreator internal method Creates a equidistant ProtoAxis
when the extremas and the bin number are It loops through the surfaces and finds out the needed information First the surfaces are sorted in the binning direction and the so called "key" surfaces (surfaces with different positions in the binning direction) are extracted. The number of key surfaces euqals the number of bins. Afterwards the minimum and maximum are calculated by subtracting/adding half of a bin size to the center position (in the binning direction) to the first/last surface.
[in] | gctx | the geometry context for this call |
surfaces | are the sensitive surfaces to be | |
bValue | the BinningValue in which direction should be binned (currently possible: binPhi, binR, binZ) | |
protoLayer | Instance of ProtoLayer holding generic layer info | |
transform | is the (optional) additional transform applied |
ProtoAxis
containing determined properties Definition at line 559 of file SurfaceArrayCreator.cpp.
View newest version in sPHENIX GitHub at line 559 of file SurfaceArrayCreator.cpp
References a, ACTS_VERBOSE, angle, b, Acts::GeometryObject::binningPosition(), Acts::binPhi, Acts::binR, Acts::binX, Acts::binY, Acts::binZ, Acts::SurfaceArrayCreator::ProtoAxis::bType, Acts::SurfaceArrayCreator::ProtoAxis::bValue, Acts::equidistant, Acts::Test::gctx, M_PI, Acts::SurfaceArrayCreator::ProtoAxis::max, max, Acts::ProtoLayer::maxPhi, Acts::ProtoLayer::maxR, Acts::ProtoLayer::maxX, Acts::ProtoLayer::maxY, Acts::ProtoLayer::maxZ, Acts::SurfaceArrayCreator::ProtoAxis::min, Acts::ProtoLayer::minPhi, Acts::ProtoLayer::minR, Acts::ProtoLayer::minX, Acts::ProtoLayer::minY, Acts::ProtoLayer::minZ, Acts::SurfaceArrayCreator::ProtoAxis::nBins, phi, Acts::Test::step(), and Acts::Test::transform.
Referenced by Acts::Test::SurfaceArrayCreatorFixture::createEquidistantAxis(), and surfaceArrayOnCylinder().
|
private |
SurfaceArrayCreator internal method Creates a variable ProtoAxis
from a vector of (unsorted) surfaces with PlanarBounds It loops through the surfaces and finds out the needed information First the surfaces are sorted in the binning direction and the so called "key" surfaces (surfaces with different positions in the binning direction) are extracted. The boundary value between two surfaces is the mean value of the two center position in the binning direction. The first and the last boundaries are calculated from the vertices of the first and last surface.
[in] | gctx | the geometry context for this call |
surfaces | are the sensitive surfaces to be | |
bValue | the BinningValue in which direction should be binned (currently possible: binPhi, binR, binZ) | |
protoLayer | Instance of ProtoLayer holding generic layer info | |
transform | is the (optional) additional transform applied |
ProtoAxis
containing determined properties Definition at line 424 of file SurfaceArrayCreator.cpp.
View newest version in sPHENIX GitHub at line 424 of file SurfaceArrayCreator.cpp
References a, ACTS_ERROR, ACTS_VERBOSE, angle, Acts::arbitrary, b, Acts::GeometryObject::binningPosition(), Acts::binPhi, Acts::binR, Acts::binZ, Acts::Surface::bounds(), Acts::SurfaceArrayCreator::ProtoAxis::bType, Acts::Test::gctx, M_PI, Acts::Test::maxPhi, Acts::ProtoLayer::maxR, Acts::ProtoLayer::maxZ, Acts::ProtoLayer::minR, Acts::ProtoLayer::minZ, Acts::VectorHelpers::perp(), phi, surface(), Acts::Test::transform, and Acts::PlanarBounds::vertices().
Referenced by Acts::Test::SurfaceArrayCreatorFixture::createVariableAxis().
|
private |
Definition at line 411 of file SurfaceArrayCreator.cpp.
View newest version in sPHENIX GitHub at line 411 of file SurfaceArrayCreator.cpp
References a, b, and Acts::Test::gctx.
|
private |
Definition at line 391 of file SurfaceArrayCreator.cpp.
View newest version in sPHENIX GitHub at line 391 of file SurfaceArrayCreator.cpp
References Acts::concept::exists.
|
inlinestatic |
Static check funtion for surface equivalent
[in] | gctx | the geometry context for this check |
bValue | the binning value for the binning | |
a | first surface for checking | |
b | second surface for checking |
Definition at line 230 of file SurfaceArrayCreator.hpp.
View newest version in sPHENIX GitHub at line 230 of file SurfaceArrayCreator.hpp
References Acts::units::_um, kdfinder::abs(), Acts::GeometryObject::binningPosition(), Acts::binPhi, Acts::binR, Acts::binZ, M_PI, and Acts::VectorHelpers::perp().
|
inlineprivate |
Private access to logger.
Definition at line 278 of file SurfaceArrayCreator.hpp.
View newest version in sPHENIX GitHub at line 278 of file SurfaceArrayCreator.hpp
References m_logger.
|
private |
Private helper method to transform the vertices of surface bounds into global coordinates
[in] | gctx | the geometry context for this call |
surface | the surface associated with the given vertices | |
locVertices | a vector of the vertices in local coordinates |
Definition at line 704 of file SurfaceArrayCreator.cpp.
View newest version in sPHENIX GitHub at line 704 of file SurfaceArrayCreator.cpp
References Acts::Surface::localToGlobal().
|
inlinestaticprivate |
Creates a SurfaceGridLookup instance within an any This is essentially a factory which absorbs some if/else logic that is required by the templating.
SurfaceArrayCreator internal method
bdtA | AxisBoundaryType of axis A |
bdtB | AxisBoundaryType of axis B |
F1 | type-deducted value of g2l lambda |
F2 | type-deducted value of l2g lambda |
globalToLocal | transform callable |
localToGlobal | transform callable |
pAxisA | ProtoAxis object for axis A |
pAxisB | ProtoAxis object for axis B |
Definition at line 356 of file SurfaceArrayCreator.hpp.
View newest version in sPHENIX GitHub at line 356 of file SurfaceArrayCreator.hpp
References Acts::arbitrary, Acts::SurfaceArrayCreator::ProtoAxis::binEdges, Acts::SurfaceArrayCreator::ProtoAxis::bType, Acts::equidistant, Acts::SurfaceArrayCreator::ProtoAxis::max, Acts::SurfaceArrayCreator::ProtoAxis::min, and Acts::SurfaceArrayCreator::ProtoAxis::nBins.
Referenced by Acts::Test::SurfaceArrayCreatorFixture::makeSurfaceGridLookup2D(), and surfaceArrayOnCylinder().
Set logging instance
logger | is the logging instance to be set |
Definition at line 269 of file SurfaceArrayCreator.hpp.
View newest version in sPHENIX GitHub at line 269 of file SurfaceArrayCreator.hpp
References m_logger.
std::unique_ptr< Acts::SurfaceArray > Acts::SurfaceArrayCreator::surfaceArrayOnCylinder | ( | const GeometryContext & | gctx, |
std::vector< std::shared_ptr< const Surface >> | surfaces, | ||
size_t | binsPhi, | ||
size_t | binsZ, | ||
std::optional< ProtoLayer > | protoLayerOpt = std::nullopt , |
||
const std::shared_ptr< const Transform3D > & | transformOpt = nullptr |
||
) | const |
SurfaceArrayCreator interface method
surfaces | is the vector of pointers to sensitive surfaces to be ordered on the cylinder |
[in] | gctx | The gometry context fro this building call |
protoLayerOpt | The proto layer containing the layer size | |
binsPhi | is the number of bins in phi for the surfaces | |
binsZ | is the number of bin in Z for the surfaces | |
transform | is the (optional) additional transform applied |
Definition at line 31 of file SurfaceArrayCreator.cpp.
View newest version in sPHENIX GitHub at line 31 of file SurfaceArrayCreator.cpp
References ACTS_VERBOSE, Acts::binPhi, Acts::binZ, completeBinning(), createEquidistantAxis(), makeSurfaceGridLookup2D(), Acts::ProtoLayer::maxR, Acts::ProtoLayer::minR, phi, pos(), Acts::IntegrationTest::R, Acts::Test::transform, and Acts::unpack_shared_vector().
std::unique_ptr< Acts::SurfaceArray > Acts::SurfaceArrayCreator::surfaceArrayOnCylinder | ( | const GeometryContext & | gctx, |
std::vector< std::shared_ptr< const Surface >> | surfaces, | ||
BinningType | bTypePhi = equidistant , |
||
BinningType | bTypeZ = equidistant , |
||
std::optional< ProtoLayer > | protoLayerOpt = std::nullopt , |
||
const std::shared_ptr< const Transform3D > & | transformOpt = nullptr |
||
) | const |
SurfaceArrayCreator interface method
surfaces | is the vector of pointers to sensitive surfaces to be ordered on the cylinder |
[in] | gctx | The gometry context fro this building call |
protoLayerOpt | The proto layer containing the layer size | |
bTypePhi | the binning type in phi direction (equidistant/aribtrary) | |
bTypeZ | the binning type in z direction (equidistant/aribtrary) | |
transform | is the (optional) additional transform applied |
Definition at line 81 of file SurfaceArrayCreator.cpp.
View newest version in sPHENIX GitHub at line 81 of file SurfaceArrayCreator.cpp
References ACTS_VERBOSE, Acts::binPhi, Acts::binZ, Acts::equidistant, Acts::SurfaceArray::ISurfaceGridLookup::fill(), Acts::SurfaceArray::ISurfaceGridLookup::getAxes(), Acts::ProtoLayer::maxR, Acts::ProtoLayer::minR, phi, pos(), Acts::IntegrationTest::R, Acts::Test::transform, and Acts::unpack_shared_vector().
std::unique_ptr< Acts::SurfaceArray > Acts::SurfaceArrayCreator::surfaceArrayOnDisc | ( | const GeometryContext & | gctx, |
std::vector< std::shared_ptr< const Surface >> | surfaces, | ||
size_t | binsR, | ||
size_t | binsPhi, | ||
std::optional< ProtoLayer > | protoLayerOpt = std::nullopt , |
||
const std::shared_ptr< const Transform3D > & | transformOpt = nullptr |
||
) | const |
SurfaceArrayCreator interface method
surfaces | is the vector of pointers to sensitive surfaces to be ordered on the disc |
[in] | gctx | The gometry context fro this building call |
protoLayerOpt | The proto layer containing the layer size | |
binsPhi | is the number of bins in phi for the surfaces | |
binsR | is the number of bin in R for the surfaces | |
transformOpt | is the (optional) additional transform applied |
Definition at line 147 of file SurfaceArrayCreator.cpp.
View newest version in sPHENIX GitHub at line 147 of file SurfaceArrayCreator.cpp
References ACTS_VERBOSE, Acts::binPhi, Acts::binR, Acts::SurfaceArray::ISurfaceGridLookup::fill(), Acts::SurfaceArray::ISurfaceGridLookup::getAxes(), Acts::ProtoLayer::maxZ, Acts::ProtoLayer::minZ, Acts::VectorHelpers::perp(), phi, pos(), Acts::Test::transform, Acts::unpack_shared_vector(), and Z.
std::unique_ptr< Acts::SurfaceArray > Acts::SurfaceArrayCreator::surfaceArrayOnDisc | ( | const GeometryContext & | gctx, |
std::vector< std::shared_ptr< const Surface >> | surfaces, | ||
BinningType | bTypeR, | ||
BinningType | bTypePhi, | ||
std::optional< ProtoLayer > | protoLayerOpt = std::nullopt , |
||
const std::shared_ptr< const Transform3D > & | transformOpt = nullptr |
||
) | const |
SurfaceArrayCreator interface method
surfaces | is the vector of pointers to sensitive surfaces to be ordered on the disc |
[in] | gctx | The gometry context fro this building call |
protoLayerOpt | The proto layer containing the layer size | |
bTypeR | the binning type in r direction (equidistant/aribtrary) | |
bTypePhi | the binning type in phi direction (equidistant/aribtrary) | |
transformOpt | is the (optional) additional transform applied |
Definition at line 203 of file SurfaceArrayCreator.cpp.
View newest version in sPHENIX GitHub at line 203 of file SurfaceArrayCreator.cpp
References a, ACTS_VERBOSE, b, bin, Acts::binPhi, Acts::binR, Acts::equidistant, Acts::SurfaceArray::ISurfaceGridLookup::fill(), Acts::Test::gctx, Acts::SurfaceArray::ISurfaceGridLookup::getAxes(), Acts::SurfaceArrayCreator::ProtoAxis::getBin(), Acts::ProtoLayer::maxZ, Acts::ProtoLayer::minZ, Acts::SurfaceArrayCreator::ProtoAxis::nBins, Acts::VectorHelpers::perp(), phi, pos(), Acts::Test::transform, Acts::unpack_shared_vector(), and Z.
std::unique_ptr< Acts::SurfaceArray > Acts::SurfaceArrayCreator::surfaceArrayOnPlane | ( | const GeometryContext & | gctx, |
std::vector< std::shared_ptr< const Surface >> | surfaces, | ||
size_t | bins1, | ||
size_t | bins2, | ||
BinningValue | bValue, | ||
std::optional< ProtoLayer > | protoLayerOpt = std::nullopt , |
||
const std::shared_ptr< const Transform3D > & | transformOpt = nullptr |
||
) | const |
SurfaceArrayCreator interface method - create an array on a plane.
SurfaceArrayCreator interface method
[in] | gctx | The gometry context fro this building call |
[in] | surfaces | is the vector of pointers to sensitive surfaces to be ordered on the plane |
[in] | bins1 | is the number of bins in the orthogonal direction to bValue |
[in] | bins2 | is the number of bins in the orthogonal direction to bValue |
[in] | bValue | Direction of the aligned surfaces |
[in] | bTypePhi | the binning type in phi direction (equidistant/aribtrary) |
[in] | transformOpt | is the (optional) additional transform applied |
<
Definition at line 312 of file SurfaceArrayCreator.cpp.
View newest version in sPHENIX GitHub at line 312 of file SurfaceArrayCreator.cpp
References ACTS_VERBOSE, Acts::binX, Acts::binY, Acts::binZ, Acts::SurfaceArray::ISurfaceGridLookup::fill(), pos(), Acts::Test::transform, and Acts::unpack_shared_vector().
Referenced by Acts::Test::Layers::BOOST_AUTO_TEST_CASE().
|
private |
configuration object
Definition at line 275 of file SurfaceArrayCreator.hpp.
View newest version in sPHENIX GitHub at line 275 of file SurfaceArrayCreator.hpp
|
private |
logging instance
Definition at line 405 of file SurfaceArrayCreator.hpp.
View newest version in sPHENIX GitHub at line 405 of file SurfaceArrayCreator.hpp
Referenced by logger(), and setLogger().