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

#include <acts/blob/sPHENIX/Examples/Io/Root/include/ActsExamples/Io/Root/RootPropagationStepsWriter.hpp>

+ Inheritance diagram for ActsExamples::RootPropagationStepsWriter:
+ Collaboration diagram for ActsExamples::RootPropagationStepsWriter:

Classes

struct  Config
 

Public Member Functions

 RootPropagationStepsWriter (const Config &cfg, Acts::Logging::Level level=Acts::Logging::INFO)
 
 ~RootPropagationStepsWriter () override
 Virtual destructor.
 
ProcessCode finalize () override
 End-of-run hook.
 
const Configconfig () const
 Get readonly access to the config parameters.
 
- Public Member Functions inherited from ActsExamples::WriterT< std::vector< PropagationSteps > >
 WriterT (std::string objectName, std::string writerName, Acts::Logging::Level level)
 
std::string name () const override
 Provide the name of the writer.
 
ProcessCode write (const AlgorithmContext &context) override
 Read the object and call the type-specific member function.
 
ProcessCode finalize () override
 No-op default implementation.
 
- Public Member Functions inherited from ActsExamples::IWriter
ProcessCode internalExecute (const AlgorithmContext &context) final
 
ProcessCode initialize () override
 Fulfil the algorithm interface.
 
- Public Member Functions inherited from ActsExamples::SequenceElement
virtual ~SequenceElement ()=default
 
const std::vector< const
DataHandleBase * > & 
writeHandles () const
 
const std::vector< const
DataHandleBase * > & 
readHandles () const
 

Protected Member Functions

ProcessCode writeT (const AlgorithmContext &context, const std::vector< PropagationSteps > &stepCollection) override
 
- Protected Member Functions inherited from ActsExamples::WriterT< std::vector< PropagationSteps > >
const Acts::Loggerlogger () const
 

Private Attributes

Config m_cfg
 the configuration object
 
std::mutex m_writeMutex
 protect multi-threaded writes
 
TFile * m_outputFile = nullptr
 the output file name
 
TTree * m_outputTree = nullptr
 the output tree
 
int m_eventNr = 0
 the event number of
 
std::vector< int > m_volumeID
 volume identifier
 
std::vector< int > m_boundaryID
 boundary identifier
 
std::vector< int > m_layerID
 layer identifier if
 
std::vector< int > m_approachID
 surface identifier
 
std::vector< int > m_sensitiveID
 surface identifier
 
std::vector< int > m_material
 flag material if present
 
std::vector< float > m_x
 global x
 
std::vector< float > m_y
 global y
 
std::vector< float > m_z
 global z
 
std::vector< float > m_dx
 global direction x
 
std::vector< float > m_dy
 global direction y
 
std::vector< float > m_dz
 global direction z
 
std::vector< int > m_step_type
 step type
 
std::vector< float > m_step_acc
 accuracy
 
std::vector< float > m_step_act
 actor check
 
std::vector< float > m_step_abt
 aborter
 
std::vector< float > m_step_usr
 user
 
std::vector< size_t > m_nStepTrials
 

Detailed Description

Write out the steps of test propgations for stepping validation, each step sequence is one entry in the root file for optimised data writing speed. The event number is part of the written data.

A common file can be provided for the writer to attach his TTree, this is done by setting the Config::rootFile pointer to an existing file

Safe to use from multiple writer threads - uses a std::mutex lock.

Definition at line 40 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 40 of file RootPropagationStepsWriter.hpp

Constructor & Destructor Documentation

ActsExamples::RootPropagationStepsWriter::~RootPropagationStepsWriter ( )
override

Virtual destructor.

Definition at line 78 of file RootPropagationStepsWriter.cpp.

View newest version in sPHENIX GitHub at line 78 of file RootPropagationStepsWriter.cpp

Member Function Documentation

const Config& ActsExamples::RootPropagationStepsWriter::config ( ) const
inline

Get readonly access to the config parameters.

Definition at line 65 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 65 of file RootPropagationStepsWriter.hpp

References m_cfg.

ActsExamples::ProcessCode ActsExamples::RootPropagationStepsWriter::finalize ( )
overridevirtual

End-of-run hook.

Close the file if it's yours

Implements ActsExamples::SequenceElement.

Definition at line 84 of file RootPropagationStepsWriter.cpp.

View newest version in sPHENIX GitHub at line 84 of file RootPropagationStepsWriter.cpp

References ACTS_VERBOSE, m_cfg(), and SUCCESS.

+ Here is the call graph for this function:

ActsExamples::ProcessCode ActsExamples::RootPropagationStepsWriter::writeT ( const AlgorithmContext context,
const std::vector< PropagationSteps > &  stepCollection 
)
overrideprotectedvirtual

This implementation holds the actual writing method and is called by the WriterT<>::write interface

Parameters
contextThe Algorithm context with per event information
stepCollectionis the data to be written out

Implements ActsExamples::WriterT< std::vector< PropagationSteps > >.

Definition at line 99 of file RootPropagationStepsWriter.cpp.

View newest version in sPHENIX GitHub at line 99 of file RootPropagationStepsWriter.cpp

References Acts::ConstrainedStep::aborter, Acts::ConstrainedStep::actor, ActsExamples::AlgorithmContext::eventNumber, material, step, propagation_timing::steps, SUCCESS, and Acts::ConstrainedStep::user.

Member Data Documentation

std::vector<int> ActsExamples::RootPropagationStepsWriter::m_approachID
private

surface identifier

Definition at line 86 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 86 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<int> ActsExamples::RootPropagationStepsWriter::m_boundaryID
private

boundary identifier

Definition at line 84 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 84 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

Config ActsExamples::RootPropagationStepsWriter::m_cfg
private

the configuration object

Definition at line 78 of file RootPropagationStepsWriter.hpp.

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

Referenced by config(), and RootPropagationStepsWriter().

std::vector<float> ActsExamples::RootPropagationStepsWriter::m_dx
private

global direction x

Definition at line 92 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 92 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<float> ActsExamples::RootPropagationStepsWriter::m_dy
private

global direction y

Definition at line 93 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 93 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<float> ActsExamples::RootPropagationStepsWriter::m_dz
private

global direction z

Definition at line 94 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 94 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

int ActsExamples::RootPropagationStepsWriter::m_eventNr = 0
private

the event number of

Definition at line 82 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 82 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<int> ActsExamples::RootPropagationStepsWriter::m_layerID
private

layer identifier if

Definition at line 85 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 85 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<int> ActsExamples::RootPropagationStepsWriter::m_material
private

flag material if present

Definition at line 88 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 88 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<size_t> ActsExamples::RootPropagationStepsWriter::m_nStepTrials
private

Number of iterations needed by the stepsize finder (e.g. Runge-Kutta) of the stepper.

Definition at line 101 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 101 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

TFile* ActsExamples::RootPropagationStepsWriter::m_outputFile = nullptr
private

the output file name

Definition at line 80 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 80 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

TTree* ActsExamples::RootPropagationStepsWriter::m_outputTree = nullptr
private

the output tree

Definition at line 81 of file RootPropagationStepsWriter.hpp.

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

Referenced by RootPropagationStepsWriter().

std::vector<int> ActsExamples::RootPropagationStepsWriter::m_sensitiveID
private

surface identifier

Definition at line 87 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 87 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<float> ActsExamples::RootPropagationStepsWriter::m_step_abt
private

aborter

Definition at line 98 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 98 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<float> ActsExamples::RootPropagationStepsWriter::m_step_acc
private

accuracy

Definition at line 96 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 96 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<float> ActsExamples::RootPropagationStepsWriter::m_step_act
private

actor check

Definition at line 97 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 97 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<int> ActsExamples::RootPropagationStepsWriter::m_step_type
private

step type

Definition at line 95 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 95 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<float> ActsExamples::RootPropagationStepsWriter::m_step_usr
private

user

Definition at line 99 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 99 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<int> ActsExamples::RootPropagationStepsWriter::m_volumeID
private

volume identifier

Definition at line 83 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 83 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::mutex ActsExamples::RootPropagationStepsWriter::m_writeMutex
private

protect multi-threaded writes

Definition at line 79 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 79 of file RootPropagationStepsWriter.hpp

std::vector<float> ActsExamples::RootPropagationStepsWriter::m_x
private

global x

Definition at line 89 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 89 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<float> ActsExamples::RootPropagationStepsWriter::m_y
private

global y

Definition at line 90 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 90 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().

std::vector<float> ActsExamples::RootPropagationStepsWriter::m_z
private

global z

Definition at line 91 of file RootPropagationStepsWriter.hpp.

View newest version in sPHENIX GitHub at line 91 of file RootPropagationStepsWriter.hpp

Referenced by RootPropagationStepsWriter().


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