Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
ActsExamples::SensitiveSurfaceMapper Class Reference

#include <acts/blob/sPHENIX/Examples/Algorithms/Geant4/include/ActsExamples/Geant4/SensitiveSurfaceMapper.hpp>

+ Collaboration diagram for ActsExamples::SensitiveSurfaceMapper:

Classes

struct  Config
 Configuration struct for the surface mapper. More...
 

Public Member Functions

 SensitiveSurfaceMapper (const Config &cfg, std::unique_ptr< const Acts::Logger > logger=Acts::getDefaultLogger("SensitiveSurfaceMapper", Acts::Logging::INFO))
 
 ~SensitiveSurfaceMapper ()=default
 
void remapSensitiveNames (G4VPhysicalVolume *g4PhysicalVolume, const Acts::Transform3 &motherTransform, int &sCounter) const
 

Static Public Attributes

static constexpr std::string_view mappingPrefix = "ActsGeoID#"
 

Protected Attributes

Config m_cfg
 Configuration object.
 

Private Member Functions

const Acts::Loggerlogger () const
 Private access method to the logging instance.
 

Private Attributes

std::unique_ptr< const
Acts::Logger
m_logger
 The looging instance.
 

Detailed Description

This Mapper takes a (non-const) Geant4 geometry and maps it such that name will be containing the mapping prefix and the Acts::GeometryIdentifier of the surface.

The mapping is done by matching the position of the G4 physical volume with the center position of an Acts::Surface.

This allows to directly associate Geant4 hits to the sensitive elements of the Acts::TrackingGeoemtry w/o map lookup.

Definition at line 35 of file SensitiveSurfaceMapper.hpp.

View newest version in sPHENIX GitHub at line 35 of file SensitiveSurfaceMapper.hpp

Constructor & Destructor Documentation

ActsExamples::SensitiveSurfaceMapper::SensitiveSurfaceMapper ( const Config cfg,
std::unique_ptr< const Acts::Logger logger = Acts::getDefaultLogger("SensitiveSurfaceMapper",                                                    Acts::Logging::INFO) 
)

Constructor with:

Parameters
cfgthe configuration struct
loggerthe logging instance

Definition at line 28 of file SensitiveSurfaceMapper.cpp.

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

References m_cfg, and ActsExamples::SensitiveSurfaceMapper::Config::trackingGeometry.

ActsExamples::SensitiveSurfaceMapper::~SensitiveSurfaceMapper ( )
default

Member Function Documentation

const Acts::Logger& ActsExamples::SensitiveSurfaceMapper::logger ( ) const
inlineprivate

Private access method to the logging instance.

Definition at line 78 of file SensitiveSurfaceMapper.hpp.

View newest version in sPHENIX GitHub at line 78 of file SensitiveSurfaceMapper.hpp

References m_logger.

void ActsExamples::SensitiveSurfaceMapper::remapSensitiveNames ( G4VPhysicalVolume g4PhysicalVolume,
const Acts::Transform3 motherTransform,
int &  sCounter 
) const

Recursive mapping function that walks through the Geant4 hierarchy and applies name remapping to the Physical volumes of the Geant4 geometry.

Parameters
g4PhysicalVolumethe current physical volume in process
motherPositionthe absolute position of the mother
sCountera counter of how many volumes have been remapped

Definition at line 36 of file SensitiveSurfaceMapper.cpp.

View newest version in sPHENIX GitHub at line 36 of file SensitiveSurfaceMapper.cpp

References ACTS_VERBOSE, Acts::GeometryObject::geometryId(), train_ambiguity_solver::id, m_cfg(), mappingPrefix, Acts::UnitConstants::mm, to_string(), Acts::Test::transform, translation(), and Acts::GeometryIdentifier::value().

Referenced by ActsExamples::Geant4Simulation::Geant4Simulation().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Member Data Documentation

Config ActsExamples::SensitiveSurfaceMapper::m_cfg
protected

Configuration object.

Definition at line 74 of file SensitiveSurfaceMapper.hpp.

View newest version in sPHENIX GitHub at line 74 of file SensitiveSurfaceMapper.hpp

Referenced by SensitiveSurfaceMapper().

std::unique_ptr<const Acts::Logger> ActsExamples::SensitiveSurfaceMapper::m_logger
private

The looging instance.

Definition at line 81 of file SensitiveSurfaceMapper.hpp.

View newest version in sPHENIX GitHub at line 81 of file SensitiveSurfaceMapper.hpp

Referenced by logger().

constexpr std::string_view ActsExamples::SensitiveSurfaceMapper::mappingPrefix = "ActsGeoID#"
static

Definition at line 37 of file SensitiveSurfaceMapper.hpp.

View newest version in sPHENIX GitHub at line 37 of file SensitiveSurfaceMapper.hpp

Referenced by remapSensitiveNames(), and ActsExamples::SensitiveSteppingAction::UserSteppingAction().


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