CbmRoot
Loading...
Searching...
No Matches
cbm::algo::TrackingChain Class Reference

A chain for tracking algorithm. More...

#include <TrackingChain.h>

Inheritance diagram for cbm::algo::TrackingChain:
[legend]
Collaboration diagram for cbm::algo::TrackingChain:
[legend]

Classes

struct  Input_t
 Input to the TrackingChain. More...
 
struct  Output_t
 Output from the TrackingChain. More...
 

Public Member Functions

 TrackingChain (ECbmRecoMode recoMode, const std::unique_ptr< cbm::algo::qa::Manager > &qaManager=nullptr, std::string_view name="")
 Constructor from parameters.
 
const ca::TrackingMonitorGetCaMonitor () const
 Gets internal monitor.
 
void Init (const std::string &caParPath)
 Provides action in the initialization of the run.
 
void RegisterSetup (std::shared_ptr< RecoSetup > pSetup)
 Registers reco-setup.
 
Output_t Run (Input_t recoResults)
 Provides action for a given time-slice.
 
void Finalize ()
 Provides action in the end of the run.
 
const ChainContextGetContext ()
 
void SetContext (const ChainContext *ctx)
 
const OptionsOpts () const
 
const RecoParamsParams () const
 
bool HasMonitor () const
 
MonitorGetMonitor () const
 

Private Member Functions

void PrepareInput (Input_t recoResults)
 Prepares input data.
 
Output_t PrepareOutput ()
 Prepares output data.
 
template<ca::EDetectorID DetID>
void ReadHits (PartitionedSpan< const ca::HitTypes_t::at< DetID > > hits)
 Reads from different detector subsystems.
 

Private Attributes

ca::TrackingMonitor fCaMonitor {}
 CA internal monitor (debug purposes)
 
ca::TrackingMonitorData fCaMonitorData {}
 CA monitor data object.
 
ca::Framework fCaFramework {}
 CA framework instance.
 
ca::DataManager fCaDataManager {}
 CA data manager.
 
ca::Qa fQa
 CA QA builder.
 
std::shared_ptr< RecoSetupfpSetup
 setup interface
 
ca::DetIdArray_t< bool > fbDetUsed
 Flags of detector subsystems used in tracking.
 
ca::HitKeyIndex_t fNofHitKeys = 0
 Current number of hit keys (aux)
 
ca::Vector< std::tuple< ca::EDetectorID, uint32_t, uint32_t > > faHitExternalIndices {"faHitExternalIndices"}
 External indices of used hits.
 
ECbmRecoMode fRecoMode {ECbmRecoMode::Undefined}
 Reconstruction mode.
 
const ChainContextfContext = nullptr
 

Static Private Attributes

static constexpr bool kDEBUG = false
 Debug mode.
 
static constexpr bool kStoreMonitor = false
 Store monitor (debug)
 

Detailed Description

A chain for tracking algorithm.

The class executes a tracking algorithm in the online data reconstruction chain.

Definition at line 43 of file TrackingChain.h.

Constructor & Destructor Documentation

◆ TrackingChain()

TrackingChain::TrackingChain ( ECbmRecoMode recoMode,
const std::unique_ptr< cbm::algo::qa::Manager > & qaManager = nullptr,
std::string_view name = "" )

Constructor from parameters.

Parameters
recoModeReconstruction mode
pManagera QA-manager
nameA name of the task (histograms directory)

Definition at line 40 of file TrackingChain.cxx.

References fQa, and fRecoMode.

Member Function Documentation

◆ Finalize()

void TrackingChain::Finalize ( )

Provides action in the end of the run.

Definition at line 112 of file TrackingChain.cxx.

References fCaMonitor, kStoreMonitor, and L_.

◆ GetCaMonitor()

const ca::TrackingMonitor & cbm::algo::TrackingChain::GetCaMonitor ( ) const
inline

Gets internal monitor.

Definition at line 83 of file TrackingChain.h.

References fCaMonitor.

◆ GetContext()

const ChainContext * cbm::algo::SubChain::GetContext ( )
inlineinherited

Definition at line 16 of file SubChain.h.

References fContext.

◆ GetMonitor()

◆ HasMonitor()

◆ Init()

void TrackingChain::Init ( const std::string & caParPath)

Provides action in the initialization of the run.

Parameters
caParPathPath to the CA parameters file

Definition at line 50 of file TrackingChain.cxx.

References CL, fbDetUsed, fCaFramework, fCaMonitor, fpSetup, fQa, fRecoMode, cbm::algo::openmp::GetMaxThreads(), GNb, cbm::algo::ca::kMcbm, cbm::algo::ca::kSts, cbm::algo::ca::kTof, cbm::algo::ca::kTrd, L_, cbm::algo::ca::ParametersIO::Load(), cbm::algo::SubChain::Opts(), and Timeslice.

◆ Opts()

◆ Params()

const RecoParams & cbm::algo::SubChain::Params ( ) const
inlineinherited

◆ PrepareInput()

◆ PrepareOutput()

◆ ReadHits()

◆ RegisterSetup()

void cbm::algo::TrackingChain::RegisterSetup ( std::shared_ptr< RecoSetup > pSetup)
inline

Registers reco-setup.

Definition at line 90 of file TrackingChain.h.

References fpSetup.

◆ Run()

TrackingChain::Output_t TrackingChain::Run ( Input_t recoResults)

Provides action for a given time-slice.

Parameters
recoResultsStructure of reconstruction results
Returns
A pair (vector of tracks, tracking monitor)

Definition at line 90 of file TrackingChain.cxx.

References fCaFramework, fCaMonitorData, PrepareInput(), cbm::algo::ca::PrepareInputData, PrepareOutput(), and cbm::algo::ca::TrackingChain.

◆ SetContext()

void cbm::algo::SubChain::SetContext ( const ChainContext * ctx)
inlineinherited

Definition at line 18 of file SubChain.h.

References fContext.

Referenced by cbm::algo::Reco::Init().

Member Data Documentation

◆ faHitExternalIndices

ca::Vector<std::tuple<ca::EDetectorID, uint32_t, uint32_t> > cbm::algo::TrackingChain::faHitExternalIndices {"faHitExternalIndices"}
private

External indices of used hits.

Note
Indexing: [globalHitID], value: (DetID, partitionID, hitID)

Definition at line 138 of file TrackingChain.h.

Referenced by PrepareInput(), PrepareOutput(), and ReadHits().

◆ fbDetUsed

ca::DetIdArray_t<bool> cbm::algo::TrackingChain::fbDetUsed
private

Flags of detector subsystems used in tracking.

Definition at line 129 of file TrackingChain.h.

Referenced by Init(), and PrepareInput().

◆ fCaDataManager

ca::DataManager cbm::algo::TrackingChain::fCaDataManager {}
private

CA data manager.

Definition at line 124 of file TrackingChain.h.

Referenced by PrepareInput(), and ReadHits().

◆ fCaFramework

ca::Framework cbm::algo::TrackingChain::fCaFramework {}
private

CA framework instance.

Definition at line 123 of file TrackingChain.h.

Referenced by Init(), PrepareInput(), PrepareOutput(), ReadHits(), and Run().

◆ fCaMonitor

ca::TrackingMonitor cbm::algo::TrackingChain::fCaMonitor {}
private

CA internal monitor (debug purposes)

Definition at line 121 of file TrackingChain.h.

Referenced by Finalize(), GetCaMonitor(), Init(), and PrepareOutput().

◆ fCaMonitorData

ca::TrackingMonitorData cbm::algo::TrackingChain::fCaMonitorData {}
private

CA monitor data object.

Definition at line 122 of file TrackingChain.h.

Referenced by PrepareInput(), PrepareOutput(), ReadHits(), and Run().

◆ fContext

const ChainContext* cbm::algo::SubChain::fContext = nullptr
privateinherited

Definition at line 34 of file SubChain.h.

Referenced by GetContext(), GetMonitor(), HasMonitor(), Opts(), Params(), and SetContext().

◆ fNofHitKeys

ca::HitKeyIndex_t cbm::algo::TrackingChain::fNofHitKeys = 0
private

Current number of hit keys (aux)

Definition at line 134 of file TrackingChain.h.

Referenced by PrepareInput(), and ReadHits().

◆ fpSetup

std::shared_ptr<RecoSetup> cbm::algo::TrackingChain::fpSetup
private

setup interface

Definition at line 127 of file TrackingChain.h.

Referenced by Init(), ReadHits(), and RegisterSetup().

◆ fQa

ca::Qa cbm::algo::TrackingChain::fQa
private

CA QA builder.

Definition at line 125 of file TrackingChain.h.

Referenced by Init(), PrepareOutput(), and TrackingChain().

◆ fRecoMode

ECbmRecoMode cbm::algo::TrackingChain::fRecoMode {ECbmRecoMode::Undefined}
private

Reconstruction mode.

Definition at line 140 of file TrackingChain.h.

Referenced by Init(), PrepareOutput(), ReadHits(), and TrackingChain().

◆ kDEBUG

bool cbm::algo::TrackingChain::kDEBUG = false
staticconstexprprivate

Debug mode.

Definition at line 142 of file TrackingChain.h.

Referenced by PrepareOutput().

◆ kStoreMonitor

bool cbm::algo::TrackingChain::kStoreMonitor = false
staticconstexprprivate

Store monitor (debug)

Definition at line 143 of file TrackingChain.h.

Referenced by Finalize().


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