EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Acts::LayerCreator Class Reference

#include <acts/blob/sPHENIX/Core/include/Acts/Geometry/LayerCreator.hpp>

+ Collaboration diagram for Acts::LayerCreator:

Classes

struct  Config
 

Public Member Functions

 LayerCreator (const Config &lcConfig, std::unique_ptr< const Logger > logger=getDefaultLogger("LayerCreator", Logging::INFO))
 
 ~LayerCreator ()=default
 Destructor.
 
MutableLayerPtr cylinderLayer (const GeometryContext &gctx, std::vector< std::shared_ptr< const Surface >> surfaces, size_t binsPhi, size_t binsZ, std::optional< ProtoLayer > _protoLayer=std::nullopt, const Transform3D &transform=s_idTransform, std::unique_ptr< ApproachDescriptor > ad=nullptr) const
 
MutableLayerPtr cylinderLayer (const GeometryContext &gctx, std::vector< std::shared_ptr< const Surface >> surfaces, BinningType bTypePhi, BinningType bTypeZ, std::optional< ProtoLayer > _protoLayer=std::nullopt, const Transform3D &transform=s_idTransform, std::unique_ptr< ApproachDescriptor > ad=nullptr) const
 
MutableLayerPtr discLayer (const GeometryContext &gctx, std::vector< std::shared_ptr< const Surface >> surfaces, size_t binsR, size_t binsPhi, std::optional< ProtoLayer > _protoLayer=std::nullopt, const Transform3D &transform=s_idTransform, std::unique_ptr< ApproachDescriptor > ad=nullptr) const
 
MutableLayerPtr discLayer (const GeometryContext &gctx, std::vector< std::shared_ptr< const Surface >> surfaces, BinningType bTypeR, BinningType bTypePhi, std::optional< ProtoLayer > _protoLayer=std::nullopt, const Transform3D &transform=s_idTransform, std::unique_ptr< ApproachDescriptor > ad=nullptr) const
 
MutableLayerPtr planeLayer (const GeometryContext &gctx, std::vector< std::shared_ptr< const Surface >> surfaces, size_t bins1, size_t bins2, BinningValue bValue, std::optional< ProtoLayer > _protoLayer=std::nullopt, const Transform3D &transform=s_idTransform, std::unique_ptr< ApproachDescriptor > ad=nullptr) const
 
void setConfiguration (const Config &lcConfig)
 
Config getConfiguration () const
 Access th configuration object.
 
void setLogger (std::unique_ptr< const Logger > newLogger)
 
void associateSurfacesToLayer (Layer &layer) const
 

Private Member Functions

bool checkBinning (const GeometryContext &gctx, const SurfaceArray &sArray) const
 
const Loggerlogger () const
 Private acces method to the logger.
 

Private Attributes

Config m_cfg
 configuration object
 
std::unique_ptr< const Loggerm_logger
 logging instance
 

Detailed Description

The LayerCreator is able to build cylinde,r disc layers or plane layers from detector elements

Definition at line 34 of file LayerCreator.hpp.

View newest version in sPHENIX GitHub at line 34 of file LayerCreator.hpp

Constructor & Destructor Documentation

Acts::LayerCreator::LayerCreator ( const Config lcConfig,
std::unique_ptr< const Logger logger = getDefaultLogger("LayerCreator", Logging::INFO) 
)

Constructor

Parameters
lcConfigis the configuration object
loggerlogging instance

Definition at line 28 of file LayerCreator.cpp.

View newest version in sPHENIX GitHub at line 28 of file LayerCreator.cpp

Acts::LayerCreator::~LayerCreator ( )
default

Destructor.

Member Function Documentation

void Acts::LayerCreator::associateSurfacesToLayer ( Layer layer) const

Definition at line 397 of file LayerCreator.cpp.

View newest version in sPHENIX GitHub at line 397 of file LayerCreator.cpp

References Acts::Surface::associateLayer(), surface(), Acts::Layer::surfaceArray(), and Acts::SurfaceArray::surfaces().

+ Here is the call graph for this function:

bool Acts::LayerCreator::checkBinning ( const GeometryContext gctx,
const SurfaceArray sArray 
) const
private

Validates that all the sensitive surfaces are actually accessible through the binning

Parameters
surfGridis the object grid from the surface array surfaces is the vector of sensitive surfaces

Definition at line 408 of file LayerCreator.cpp.

View newest version in sPHENIX GitHub at line 408 of file LayerCreator.cpp

References ACTS_ERROR, ACTS_VERBOSE, Acts::SurfaceArray::at(), Acts::binR, Acts::SurfaceArray::isValidBin(), Acts::VectorHelpers::perp(), phi, Acts::SurfaceArray::size(), and Acts::SurfaceArray::surfaces().

+ Here is the call graph for this function:

Acts::MutableLayerPtr Acts::LayerCreator::cylinderLayer ( const GeometryContext gctx,
std::vector< std::shared_ptr< const Surface >>  surfaces,
size_t  binsPhi,
size_t  binsZ,
std::optional< ProtoLayer _protoLayer = std::nullopt,
const Transform3D transform = s_idTransform,
std::unique_ptr< ApproachDescriptor ad = nullptr 
) const

returning a cylindrical layer

Parameters
gctxist the geometry context with which the geometry is built
surfacesis the vector of pointers to sensitive surfaces represented by this layer
Precondition
the pointers to the sensitive surfaces in the surfaces vectors all need to be valid, since no check is performed
Parameters
binsPhiis number of bins the sensitive surfaces are ordered in phi
binsZis number of bins the sensitive surfaces are ordered in Z
_protoLayer(optional) proto layer specifying the dimensions and envelopes
transformis the (optional) transform of the layer
adpossibility to hand over a specific ApproachDescriptor, which is needed for material mapping. Otherwise the default ApproachDescriptor will be taken used for this layer
Returns
shared pointer to a newly created layer

Definition at line 43 of file LayerCreator.cpp.

View newest version in sPHENIX GitHub at line 43 of file LayerCreator.cpp

References Acts::active, ACTS_ERROR, ACTS_VERBOSE, Acts::binPhi, Acts::binR, Acts::binZ, Acts::CylinderLayer::create(), Acts::ProtoLayer::envelope, Acts::ProtoLayer::max(), Acts::ProtoLayer::medium(), Acts::ProtoLayer::min(), Acts::ProtoLayer::range(), and Acts::s_idTransform.

+ Here is the call graph for this function:

Acts::MutableLayerPtr Acts::LayerCreator::cylinderLayer ( const GeometryContext gctx,
std::vector< std::shared_ptr< const Surface >>  surfaces,
BinningType  bTypePhi,
BinningType  bTypeZ,
std::optional< ProtoLayer _protoLayer = std::nullopt,
const Transform3D transform = s_idTransform,
std::unique_ptr< ApproachDescriptor ad = nullptr 
) const

returning a cylindrical layer

Parameters
gctxist the geometry context with which the geometry is built
surfacesis the vector of pointers to sensitive surfaces represented by this layer
Precondition
the pointers to the sensitive surfaces in the surfaces vectors all need to be valid, since no check is performed
Parameters
bTypePhibinning type in phi (equidistant/arbitrary)
bTypeZbinning type in z (equidistant/arbitrary)
_protoLayer(optional) proto layer specifying the dimensions and envelopes
transformis the (optional) transform of the layer
adpossibility to hand over a specific ApproachDescriptor, which is needed for material mapping. Otherwise the default ApproachDescriptor will be taken used for this layer
Returns
shared pointer to a newly created layer

Definition at line 116 of file LayerCreator.cpp.

View newest version in sPHENIX GitHub at line 116 of file LayerCreator.cpp

References Acts::active, ACTS_ERROR, ACTS_VERBOSE, Acts::binPhi, Acts::binR, Acts::binZ, Acts::CylinderLayer::create(), Acts::ProtoLayer::envelope, Acts::equidistant, Acts::ProtoLayer::max(), Acts::ProtoLayer::medium(), Acts::ProtoLayer::min(), Acts::ProtoLayer::range(), and Acts::s_idTransform.

+ Here is the call graph for this function:

Acts::MutableLayerPtr Acts::LayerCreator::discLayer ( const GeometryContext gctx,
std::vector< std::shared_ptr< const Surface >>  surfaces,
size_t  binsR,
size_t  binsPhi,
std::optional< ProtoLayer _protoLayer = std::nullopt,
const Transform3D transform = s_idTransform,
std::unique_ptr< ApproachDescriptor ad = nullptr 
) const

returning a disc layer

Parameters
gctxist the geometry context with which the geometry is built
surfacesis the vector of pointers to sensitive surfaces represented by this layer
Precondition
the pointers to the sensitive surfaces in the surfaces vectors all need to be valid, since no check is performed
Parameters
binsRis number of bins the sensitive surfaces are ordered in R
binsPhiis number of bins the sensitive surfaces are ordered in Phi
transformis the (optional) transform of the layer
_protoLayer(optional) proto layer specifying the dimensions and envelopes
adpossibility to hand over a specific ApproachDescriptor, which is needed for material mapping. Otherwise the default ApproachDescriptor will be taken used for this layer
Returns
shared pointer to a newly created layer

Definition at line 189 of file LayerCreator.cpp.

View newest version in sPHENIX GitHub at line 189 of file LayerCreator.cpp

References Acts::active, ACTS_ERROR, ACTS_VERBOSE, Acts::binPhi, Acts::binR, Acts::binZ, Acts::DiscLayer::create(), Acts::ProtoLayer::envelope, Acts::ProtoLayer::max(), Acts::ProtoLayer::medium(), Acts::ProtoLayer::min(), Acts::ProtoLayer::range(), and Acts::s_idTransform.

+ Here is the call graph for this function:

Acts::MutableLayerPtr Acts::LayerCreator::discLayer ( const GeometryContext gctx,
std::vector< std::shared_ptr< const Surface >>  surfaces,
BinningType  bTypeR,
BinningType  bTypePhi,
std::optional< ProtoLayer _protoLayer = std::nullopt,
const Transform3D transform = s_idTransform,
std::unique_ptr< ApproachDescriptor ad = nullptr 
) const

returning a disc layer

Parameters
gctxist the geometry context with which the geometry is built
surfacesis the vector of pointers to sensitive surfaces represented by this layer
Precondition
the pointers to the sensitive surfaces in the surfaces vectors all need to be valid, since no check is performed
Parameters
bTypeRbinning type in r (equidistant/arbitrary)
bTypePhibinning type in phi (equidistant/arbitrary)
transformis the (optional) transform of the layer
_protoLayer(optional) proto layer specifying the dimensions and envelopes
adpossibility to hand over a specific ApproachDescriptor, which is needed for material mapping. Otherwise the default ApproachDescriptor will be taken used for this layer
Returns
shared pointer to a newly created layer

Definition at line 253 of file LayerCreator.cpp.

View newest version in sPHENIX GitHub at line 253 of file LayerCreator.cpp

References Acts::active, ACTS_ERROR, ACTS_VERBOSE, Acts::binPhi, Acts::binR, Acts::binZ, Acts::DiscLayer::create(), Acts::ProtoLayer::envelope, Acts::ProtoLayer::max(), Acts::ProtoLayer::medium(), Acts::ProtoLayer::min(), Acts::ProtoLayer::range(), and Acts::s_idTransform.

+ Here is the call graph for this function:

LayerCreator::Config Acts::LayerCreator::getConfiguration ( ) const
inline

Access th configuration object.

Definition at line 222 of file LayerCreator.hpp.

View newest version in sPHENIX GitHub at line 222 of file LayerCreator.hpp

References m_cfg.

const Logger& Acts::LayerCreator::logger ( ) const
inlineprivate

Private acces method to the logger.

Definition at line 216 of file LayerCreator.hpp.

View newest version in sPHENIX GitHub at line 216 of file LayerCreator.hpp

References m_logger.

Acts::MutableLayerPtr Acts::LayerCreator::planeLayer ( const GeometryContext gctx,
std::vector< std::shared_ptr< const Surface >>  surfaces,
size_t  bins1,
size_t  bins2,
BinningValue  bValue,
std::optional< ProtoLayer _protoLayer = std::nullopt,
const Transform3D transform = s_idTransform,
std::unique_ptr< ApproachDescriptor ad = nullptr 
) const

returning a plane layer

Parameters
gctxist the geometry context with which the geometry is built
[in]surfacesis the vector of pointers to sensitive surfaces represented by this layer
Precondition
the pointers to the sensitive surfaces in the surfaces vectors all need to be valid, since no check is performed
Parameters
[in]bins1is the number of bins in the orthogonal direction to bValue
[in]bins2is the number of bins in the orthogonal direction to bValue
[in]bValueDirection of the aligned surfaces
[in]transformis the (optional) transform of the layer
[in]_protoLayer(optional) proto layer specifying the dimensions and envelopes
[in]adpossibility to hand over a specific ApproachDescriptor, which is needed for material mapping. Otherwise the default ApproachDescriptor will be taken used for this layer
Returns
shared pointer to a newly created layer

Definition at line 315 of file LayerCreator.cpp.

View newest version in sPHENIX GitHub at line 315 of file LayerCreator.cpp

References Acts::active, ACTS_ERROR, ACTS_VERBOSE, Acts::binX, Acts::binY, Acts::binZ, Acts::PlaneLayer::create(), Acts::ProtoLayer::max(), Acts::ProtoLayer::min(), and Acts::s_idTransform.

+ Here is the call graph for this function:

void Acts::LayerCreator::setConfiguration ( const Config lcConfig)

Set the configuration object

Parameters
lcConfigis the configuration struct

Definition at line 32 of file LayerCreator.cpp.

View newest version in sPHENIX GitHub at line 32 of file LayerCreator.cpp

void Acts::LayerCreator::setLogger ( std::unique_ptr< const Logger newLogger)

set logging instance

Parameters
newLoggerthe logger instance

Definition at line 39 of file LayerCreator.cpp.

View newest version in sPHENIX GitHub at line 39 of file LayerCreator.cpp

Member Data Documentation

Config Acts::LayerCreator::m_cfg
private

configuration object

Definition at line 213 of file LayerCreator.hpp.

View newest version in sPHENIX GitHub at line 213 of file LayerCreator.hpp

Referenced by getConfiguration().

std::unique_ptr<const Logger> Acts::LayerCreator::m_logger
private

logging instance

Definition at line 219 of file LayerCreator.hpp.

View newest version in sPHENIX GitHub at line 219 of file LayerCreator.hpp

Referenced by logger().


The documentation for this class was generated from the following files: