Analysis Software
Documentation for sPHENIX simulation software
|
Reads in Particles information from a root file. More...
#include <acts/blob/sPHENIX/Examples/Io/Root/include/ActsExamples/Io/Root/RootParticleReader.hpp>
Classes | |
struct | Config |
The nested configuration struct. More... | |
Public Member Functions | |
RootParticleReader (const Config &config, Acts::Logging::Level level) | |
~RootParticleReader () override | |
Destructor. | |
std::string | name () const override |
Framework name() method. | |
std::pair< size_t, size_t > | availableEvents () const override |
Return the available events range. | |
ProcessCode | read (const ActsExamples::AlgorithmContext &context) override |
const Config & | config () const |
Readonly access to the config. | |
Public Member Functions inherited from ActsExamples::IReader | |
ProcessCode | internalExecute (const AlgorithmContext &context) final |
ProcessCode | initialize () override |
Fulfill the algorithm interface. | |
ProcessCode | finalize () override |
Fulfill 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 |
Private Member Functions | |
const Acts::Logger & | logger () const |
Private access to the logging instance. | |
Private Attributes | |
Config | m_cfg |
The config class. | |
WriteDataHandle < SimParticleContainer > | m_outputParticles |
WriteDataHandle< std::vector < uint32_t > > | m_outputPrimaryVertices |
WriteDataHandle< std::vector < uint32_t > > | m_outputSecondaryVertices |
std::unique_ptr< const Acts::Logger > | m_logger |
std::mutex | m_read_mutex |
mutex used to protect multi-threaded reads | |
size_t | m_events = 0 |
The number of events. | |
TChain * | m_inputChain = nullptr |
The input tree name. | |
uint32_t | m_eventId = 0 |
Event identifier. | |
std::vector< long long > | m_entryNumbers = {} |
std::vector< uint64_t > * | m_particleId = new std::vector<uint64_t> |
std::vector< int32_t > * | m_particleType = new std::vector<int32_t> |
std::vector< uint32_t > * | m_process = new std::vector<uint32_t> |
std::vector< float > * | m_vx = new std::vector<float> |
std::vector< float > * | m_vy = new std::vector<float> |
std::vector< float > * | m_vz = new std::vector<float> |
std::vector< float > * | m_vt = new std::vector<float> |
std::vector< float > * | m_px = new std::vector<float> |
std::vector< float > * | m_py = new std::vector<float> |
std::vector< float > * | m_pz = new std::vector<float> |
std::vector< float > * | m_m = new std::vector<float> |
std::vector< float > * | m_q = new std::vector<float> |
std::vector< float > * | m_eta = new std::vector<float> |
std::vector< float > * | m_phi = new std::vector<float> |
std::vector< float > * | m_pt = new std::vector<float> |
std::vector< float > * | m_p = new std::vector<float> |
std::vector< uint32_t > * | m_vertexPrimary = new std::vector<uint32_t> |
std::vector< uint32_t > * | m_vertexSecondary = new std::vector<uint32_t> |
std::vector< uint32_t > * | m_particle = new std::vector<uint32_t> |
std::vector< uint32_t > * | m_generation = new std::vector<uint32_t> |
std::vector< uint32_t > * | m_subParticle = new std::vector<uint32_t> |
Reads in Particles information from a root file.
Definition at line 35 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 35 of file RootParticleReader.hpp
ActsExamples::RootParticleReader::RootParticleReader | ( | const Config & | config, |
Acts::Logging::Level | level | ||
) |
Constructor
config | The Configuration struct |
Definition at line 25 of file RootParticleReader.cpp.
View newest version in sPHENIX GitHub at line 25 of file RootParticleReader.cpp
References ACTS_DEBUG, ActsExamples::RootParticleReader::Config::filePath, ActsExamples::WriteDataHandle< T >::initialize(), m_cfg, m_entryNumbers, m_eta, m_eventId, m_events, m_generation, m_inputChain, m_m, m_outputParticles, m_outputPrimaryVertices, m_outputSecondaryVertices, m_p, m_particle, m_particleId, m_particleType, m_phi, m_process, m_pt, m_px, m_py, m_pz, m_q, m_subParticle, m_vertexPrimary, m_vertexSecondary, m_vt, m_vx, m_vy, m_vz, ActsExamples::DataHandleBase::maybeInitialize(), ActsExamples::RootParticleReader::Config::orderedEvents, ActsExamples::RootParticleReader::Config::particleCollection, path, ActsExamples::RootParticleReader::Config::treeName, ActsExamples::RootParticleReader::Config::vertexPrimaryCollection, and ActsExamples::RootParticleReader::Config::vertexSecondaryCollection.
|
override |
Destructor.
Definition at line 92 of file RootParticleReader.cpp.
View newest version in sPHENIX GitHub at line 92 of file RootParticleReader.cpp
|
overridevirtual |
Return the available events range.
Implements ActsExamples::IReader.
Definition at line 87 of file RootParticleReader.cpp.
View newest version in sPHENIX GitHub at line 87 of file RootParticleReader.cpp
References physmon_ckf_tracking::u.
|
inline |
Readonly access to the config.
Definition at line 69 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 69 of file RootParticleReader.hpp
References m_cfg.
|
inlineprivate |
Private access to the logging instance.
Definition at line 73 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 73 of file RootParticleReader.hpp
References m_logger.
|
inlineoverridevirtual |
Framework name() method.
Implements ActsExamples::SequenceElement.
Definition at line 58 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 58 of file RootParticleReader.hpp
|
overridevirtual |
Read out data from the input stream
context | The algorithm context |
Implements ActsExamples::IReader.
Definition at line 116 of file RootParticleReader.cpp.
View newest version in sPHENIX GitHub at line 116 of file RootParticleReader.cpp
References ACTS_DEBUG, ACTS_INFO, Acts::UnitConstants::e, entry, ActsExamples::AlgorithmContext::eventNumber, Acts::UnitConstants::GeV, i, m_cfg(), Acts::UnitConstants::mm, testing::internal::move(), Acts::UnitConstants::ns, merge_hashes::p, ActsFatras::Particle::setAbsoluteMomentum(), ActsFatras::Particle::setCharge(), ActsFatras::Particle::setDirection(), ActsFatras::Particle::setMass(), ActsFatras::Particle::setParticleId(), ActsFatras::Particle::setPdg(), ActsFatras::Particle::setPosition4(), ActsFatras::Particle::setProcess(), and SUCCESS.
|
private |
The config class.
Definition at line 76 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 76 of file RootParticleReader.hpp
Referenced by config(), and RootParticleReader().
|
private |
The entry numbers for accessing events in increased order (there could be multiple entries corresponding to one event number)
Definition at line 102 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 102 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 116 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 116 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Event identifier.
Definition at line 98 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 98 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
The number of events.
Definition at line 92 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 92 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 123 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 123 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
The input tree name.
Definition at line 95 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 95 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 86 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 86 of file RootParticleReader.hpp
Referenced by logger().
|
private |
Definition at line 114 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 114 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 78 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 78 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 81 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 81 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 83 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 83 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 119 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 119 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 122 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 122 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 104 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 104 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 105 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 105 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 117 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 117 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 106 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 106 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 118 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 118 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 111 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 111 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 112 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 112 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 113 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 113 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 115 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 115 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
mutex used to protect multi-threaded reads
Definition at line 89 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 89 of file RootParticleReader.hpp
|
private |
Definition at line 124 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 124 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 120 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 120 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 121 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 121 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 110 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 110 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 107 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 107 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 108 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 108 of file RootParticleReader.hpp
Referenced by RootParticleReader().
|
private |
Definition at line 109 of file RootParticleReader.hpp.
View newest version in sPHENIX GitHub at line 109 of file RootParticleReader.hpp
Referenced by RootParticleReader().