Analysis Software
Documentation for sPHENIX simulation software
|
#include <acts/blob/sPHENIX/Examples/Io/Csv/include/ActsExamples/Io/Csv/CsvMeasurementReader.hpp>
Classes | |
struct | Config |
Public Member Functions | |
CsvMeasurementReader (const Config &config, Acts::Logging::Level level) | |
std::string | name () const override |
The algorithm name. | |
std::pair< size_t, size_t > | availableEvents () const override |
Return the available events range. | |
ProcessCode | read (const ActsExamples::AlgorithmContext &ctx) override |
Read out data from the input stream. | |
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 Attributes | |
Config | m_cfg |
std::pair< size_t, size_t > | m_eventsRange |
std::unique_ptr< const Acts::Logger > | m_logger |
WriteDataHandle < MeasurementContainer > | m_outputMeasurements |
WriteDataHandle< IndexMultimap < Index > > | m_outputMeasurementSimHitsMap |
WriteDataHandle < GeometryIdMultiset < IndexSourceLink > > | m_outputSourceLinks |
WriteDataHandle< ClusterContainer > | m_outputClusters {this, "OutputClusters"} |
WriteDataHandle< IndexMultimap < ActsFatras::Barcode > > | m_outputMeasurementParticlesMap {this, "OutputMeasurementParticlesMap"} |
ReadDataHandle< SimHitContainer > | m_inputHits {this, "InputHits"} |
Read in a measurement cluster collection in comma-separated-value format.
This reads three files per event file in the configured input directory. By default it reads file in the current working directory. Files are assumed to be named using the following schema
event000000001-cells.csv (optional) event000000001-measurements.csv event000000001-measurement-simhit-map.csv event000000002-cells.csv (optional) event000000002-measurements.csv event000000001-measurement-simhit-map.csv
and each line in the file corresponds to one hit/cluster.
One file per fevent: thread-safe for parallel event processing.
Definition at line 54 of file CsvMeasurementReader.hpp.
View newest version in sPHENIX GitHub at line 54 of file CsvMeasurementReader.hpp
ActsExamples::CsvMeasurementReader::CsvMeasurementReader | ( | const Config & | config, |
Acts::Logging::Level | level | ||
) |
Construct the cluster reader.
config | is the configuration object |
level | is the logging level |
Definition at line 36 of file CsvMeasurementReader.cpp.
View newest version in sPHENIX GitHub at line 36 of file CsvMeasurementReader.cpp
References ActsExamples::determineEventFilesRange(), ActsExamples::WriteDataHandle< T >::initialize(), ActsExamples::CsvMeasurementReader::Config::inputDir, ActsExamples::CsvMeasurementReader::Config::inputSimHits, m_cfg, m_eventsRange, m_inputHits, m_outputClusters, m_outputMeasurementParticlesMap, m_outputMeasurements, m_outputMeasurementSimHitsMap, m_outputSourceLinks, ActsExamples::DataHandleBase::maybeInitialize(), ActsExamples::CsvMeasurementReader::Config::outputClusters, ActsExamples::CsvMeasurementReader::Config::outputMeasurementParticlesMap, ActsExamples::CsvMeasurementReader::Config::outputMeasurements, ActsExamples::CsvMeasurementReader::Config::outputMeasurementSimHitsMap, and ActsExamples::CsvMeasurementReader::Config::outputSourceLinks.
|
overridevirtual |
Return the available events range.
Implements ActsExamples::IReader.
Definition at line 76 of file CsvMeasurementReader.cpp.
View newest version in sPHENIX GitHub at line 76 of file CsvMeasurementReader.cpp
|
inline |
Readonly access to the config.
Definition at line 90 of file CsvMeasurementReader.hpp.
View newest version in sPHENIX GitHub at line 90 of file CsvMeasurementReader.hpp
References m_cfg.
|
inlineprivate |
Definition at line 97 of file CsvMeasurementReader.hpp.
View newest version in sPHENIX GitHub at line 97 of file CsvMeasurementReader.hpp
References m_logger.
|
overridevirtual |
The algorithm name.
Implements ActsExamples::SequenceElement.
|
overridevirtual |
Read out data from the input stream.
Implements ActsExamples::IReader.
Definition at line 184 of file CsvMeasurementReader.cpp.
View newest version in sPHENIX GitHub at line 184 of file CsvMeasurementReader.cpp
References _, ACTS_FATAL, cd(), clusters, ActsExamples::createMeasurement(), Acts::UnitConstants::e, Acts::eBoundLoc0, Acts::eBoundLoc1, Acts::eBoundPhi, Acts::eBoundSize, Acts::eBoundTheta, Acts::eBoundTime, ActsExamples::AlgorithmContext::eventNumber, ActsExamples::CellData::geometry_id, index, ActsExamples::DigitizedParameters::indices, Acts::UnitConstants::m, m_cfg(), testing::internal::move(), next, SUCCESS, Acts::Test::transform, ActsExamples::DigitizedParameters::values, and ActsExamples::DigitizedParameters::variances.
|
private |
Definition at line 93 of file CsvMeasurementReader.hpp.
View newest version in sPHENIX GitHub at line 93 of file CsvMeasurementReader.hpp
Referenced by config(), and CsvMeasurementReader().
|
private |
Definition at line 94 of file CsvMeasurementReader.hpp.
View newest version in sPHENIX GitHub at line 94 of file CsvMeasurementReader.hpp
Referenced by CsvMeasurementReader().
|
private |
Definition at line 113 of file CsvMeasurementReader.hpp.
View newest version in sPHENIX GitHub at line 113 of file CsvMeasurementReader.hpp
Referenced by CsvMeasurementReader().
|
private |
Definition at line 95 of file CsvMeasurementReader.hpp.
View newest version in sPHENIX GitHub at line 95 of file CsvMeasurementReader.hpp
Referenced by logger().
|
private |
Definition at line 108 of file CsvMeasurementReader.hpp.
View newest version in sPHENIX GitHub at line 108 of file CsvMeasurementReader.hpp
Referenced by CsvMeasurementReader().
|
private |
Definition at line 111 of file CsvMeasurementReader.hpp.
View newest version in sPHENIX GitHub at line 111 of file CsvMeasurementReader.hpp
Referenced by CsvMeasurementReader().
|
private |
Definition at line 99 of file CsvMeasurementReader.hpp.
View newest version in sPHENIX GitHub at line 99 of file CsvMeasurementReader.hpp
Referenced by CsvMeasurementReader().
|
private |
Definition at line 102 of file CsvMeasurementReader.hpp.
View newest version in sPHENIX GitHub at line 102 of file CsvMeasurementReader.hpp
Referenced by CsvMeasurementReader().
|
private |
Definition at line 105 of file CsvMeasurementReader.hpp.
View newest version in sPHENIX GitHub at line 105 of file CsvMeasurementReader.hpp
Referenced by CsvMeasurementReader().