Analysis Software
Documentation for sPHENIX simulation software
|
Algorithm to run Geant4 simulation in the ActsExamples framework. More...
#include <acts/blob/sPHENIX/Examples/Algorithms/Geant4/include/ActsExamples/Geant4/Geant4Simulation.hpp>
Classes | |
struct | Config |
Public Member Functions | |
Geant4Simulation (const Config &cfg, Acts::Logging::Level level=Acts::Logging::INFO) | |
~Geant4Simulation () override | |
ActsExamples::ProcessCode | execute (const ActsExamples::AlgorithmContext &ctx) const final |
const Config & | config () const final |
Readonly access to the configuration. | |
Public Member Functions inherited from ActsExamples::Geant4SimulationBase | |
Geant4SimulationBase (const Config &cfg, std::string name, Acts::Logging::Level level) | |
~Geant4SimulationBase () override | |
ProcessCode | initialize () final |
Initialize the algorithm. | |
std::shared_ptr< Geant4Handle > | geant4Handle () const |
Public Member Functions inherited from ActsExamples::IAlgorithm | |
IAlgorithm (std::string name, Acts::Logging::Level level=Acts::Logging::INFO) | |
std::string | name () const override |
The algorithm name. | |
ProcessCode | internalExecute (const AlgorithmContext &context) final |
ProcessCode | initialize () override |
Initialize the algorithm. | |
ProcessCode | finalize () override |
Finalize the algorithm. | |
Private Attributes | |
Config | m_cfg |
std::unique_ptr< G4MagneticField > | m_magneticField |
The (wrapped) ACTS Magnetic field provider as a Geant4 module. | |
std::unique_ptr< G4FieldManager > | m_fieldManager |
WriteDataHandle < SimParticleContainer > | m_outputParticlesInitial |
WriteDataHandle < SimParticleContainer > | m_outputParticlesFinal |
WriteDataHandle< SimHitContainer > | m_outputSimHits {this, "OutputSimHIts"} |
Additional Inherited Members | |
Protected Member Functions inherited from ActsExamples::Geant4SimulationBase | |
void | commonInitialization () |
G4RunManager & | runManager () const |
EventStore & | eventStore () const |
Protected Attributes inherited from ActsExamples::Geant4SimulationBase | |
std::unique_ptr< const Acts::Logger > | m_logger |
std::shared_ptr< EventStore > | m_eventStore |
int | m_geant4Level {} |
std::shared_ptr< Geant4Handle > | m_geant4Instance |
G4VUserDetectorConstruction * | m_detectorConstruction {} |
ReadDataHandle < SimParticleContainer > | m_inputParticles {this, "InputParticles"} |
Algorithm to run Geant4 simulation in the ActsExamples framework.
Definition at line 112 of file Geant4Simulation.hpp.
View newest version in sPHENIX GitHub at line 112 of file Geant4Simulation.hpp
ActsExamples::Geant4Simulation::Geant4Simulation | ( | const Config & | cfg, |
Acts::Logging::Level | level = Acts::Logging::INFO |
||
) |
Simulation constructor
config | is the configuration struct |
level | is the logging level to be used |
Definition at line 174 of file Geant4Simulation.cpp.
View newest version in sPHENIX GitHub at line 174 of file Geant4Simulation.cpp
References ActsExamples::SteppingActionList::Config::actions, ACTS_INFO, ActsExamples::SensitiveSteppingAction::Config::charged, ActsExamples::Geant4SimulationBase::commonInitialization(), ActsExamples::Geant4Manager::createHandle(), ActsExamples::SensitiveSteppingAction::Config::eventStore, ActsExamples::ParticleTrackingAction::Config::eventStore, ActsExamples::SimParticleTranslation::Config::eventStore, ActsExamples::Geant4SimulationBase::Config::geant4Handle, ActsExamples::WriteDataHandle< T >::initialize(), ActsExamples::ReadDataHandle< T >::initialize(), ActsExamples::Geant4SimulationBase::Config::inputParticles, ActsExamples::Geant4Manager::instance(), ActsExamples::ParticleTrackingAction::Config::keepParticlesWithoutHits, m_cfg, ActsExamples::Geant4SimulationBase::m_detectorConstruction, ActsExamples::Geant4SimulationBase::m_eventStore, m_fieldManager, ActsExamples::Geant4SimulationBase::m_geant4Instance, ActsExamples::Geant4SimulationBase::m_geant4Level, ActsExamples::Geant4SimulationBase::m_inputParticles, ActsExamples::Geant4SimulationBase::m_logger, m_magneticField, m_outputParticlesFinal, m_outputParticlesInitial, m_outputSimHits, ActsExamples::MagneticFieldWrapper::Config::magneticField, ActsExamples::SensitiveSurfaceMapper::Config::materialMappings, ActsExamples::ParticleKillAction::Config::maxTime, ActsExamples::SensitiveSteppingAction::Config::neutral, ActsExamples::Geant4Simulation::Config::physicsList, ActsExamples::SensitiveSteppingAction::Config::primary, ActsExamples::SensitiveSurfaceMapper::remapSensitiveNames(), ActsExamples::Geant4SimulationBase::runManager(), ActsExamples::ParticleKillAction::Config::secondaries, ActsExamples::SensitiveSteppingAction::Config::secondary, ActsExamples::SensitiveSurfaceMapper::Config::trackingGeometry, ActsExamples::ParticleKillAction::Config::volume, and ActsExamples::SensitiveSurfaceMapper::Config::volumeMappings.
|
overridedefault |
|
inlinefinalvirtual |
Readonly access to the configuration.
Implements ActsExamples::Geant4SimulationBase.
Definition at line 162 of file Geant4Simulation.hpp.
View newest version in sPHENIX GitHub at line 162 of file Geant4Simulation.hpp
References m_cfg.
|
finalvirtual |
Algorithm execute method, called once per event with context
ctx | the AlgorithmContext for this event |
Reimplemented from ActsExamples::Geant4SimulationBase.
Definition at line 299 of file Geant4Simulation.cpp.
View newest version in sPHENIX GitHub at line 299 of file Geant4Simulation.cpp
References container, ActsExamples::Geant4SimulationBase::execute(), testing::internal::move(), and SUCCESS.
|
private |
Definition at line 165 of file Geant4Simulation.hpp.
View newest version in sPHENIX GitHub at line 165 of file Geant4Simulation.hpp
Referenced by config(), and Geant4Simulation().
|
private |
Definition at line 169 of file Geant4Simulation.hpp.
View newest version in sPHENIX GitHub at line 169 of file Geant4Simulation.hpp
Referenced by Geant4Simulation().
|
private |
The (wrapped) ACTS Magnetic field provider as a Geant4 module.
Definition at line 168 of file Geant4Simulation.hpp.
View newest version in sPHENIX GitHub at line 168 of file Geant4Simulation.hpp
Referenced by Geant4Simulation().
|
private |
Definition at line 173 of file Geant4Simulation.hpp.
View newest version in sPHENIX GitHub at line 173 of file Geant4Simulation.hpp
Referenced by Geant4Simulation().
|
private |
Definition at line 171 of file Geant4Simulation.hpp.
View newest version in sPHENIX GitHub at line 171 of file Geant4Simulation.hpp
Referenced by Geant4Simulation().
|
private |
Definition at line 175 of file Geant4Simulation.hpp.
View newest version in sPHENIX GitHub at line 175 of file Geant4Simulation.hpp
Referenced by Geant4Simulation().