CbmRoot
Loading...
Searching...
No Matches
cbm::algo::ca::Parameters< DataT > Class Template Reference

A container for all external parameters of the CA tracking algorithm. More...

#include <CaParameters.h>

Inheritance diagram for cbm::algo::ca::Parameters< DataT >:
[legend]
Collaboration diagram for cbm::algo::ca::Parameters< DataT >:
[legend]

Public Member Functions

 Parameters ()=default
 Default constructor.
 
 Parameters (ca::Setup< DataT > &&setup, ca::Config &&config, SearchWindowMapContainer &&searchWindows)
 Constructor from arguments.
 
template<typename DataIn>
 Parameters (const Parameters< DataIn > &other)
 Copy constructor with type conversion.
 
 Parameters (const Parameters &other)=default
 Copy constructor.
 
 ~Parameters () noexcept=default
 Destructor.
 
 Parameters (Parameters &&other)=default
 Move constructor.
 
Parametersoperator= (const Parameters &other)=default
 Copy assignment operator.
 
Parametersoperator= (Parameters &&other)=default
 Move assignment operator.
 
void Print (int verbosityLevel=0) const
 Prints configuration.
 
std::string ToString (int verbosity=0, int indentLevel=0) const
 String representation of the class contents.
 
kf::EFieldMode GetFieldMode () const
 Gets field mode.
 
int GetNstationsActive () const
 Gets total number of active stations.
 
int GetNstationsActive (EDetectorID detId) const
 Gets number of active stations for given detector ID.
 
int GetNstationsGeometry () const
 Gets total number of stations, provided by setup geometry.
 
int GetNstationsGeometry (EDetectorID detId) const
 Gets number of stations, provided by setup geometry for given detector ID.
 
std::pair< EDetectorID, int > GetStationIndexLocal (int geoId) const
 Provides access to the first index of the station on each particular detector (const)
 
int GetStationIndexGeometry (int locId, EDetectorID detId) const
 Provides access to local indexes of stations (const)
 
int GetStationIndexActive (int locId, EDetectorID detId) const
 Provides access to global indexes of stations among geometry (const)
 
const auto & GetCAIterations () const
 Provides access to L1CAIteration vector (const)
 
int GetNcaIterations () const
 Provides number of iterations.
 
const auto & GetActiveSetup () const
 Gets active setup.
 
const auto & GetGeometrySetup () const
 Gets active setup.
 
bool IsActive (EDetectorID detId) const
 Checks, if the detector subsystem active.
 
void CheckConsistency () const
 Class invariant checker.
 
const Setup< DataT > & GetSetup () const
 Constant accessor to CA setup.
 
const ConfigGetConfig () const
 Constant accessor to CA config.
 
const SearchWindowMapContainerGetSearchWindows () const
 Constant accessor to search window map container.
 

Private Types

using DetectorID_t = std::underlying_type_t<EDetectorID>
 
template<typename T>
using StationArray_t = std::array<T, constants::size::MaxNstations>
 

Private Member Functions

template<class Archive>
void serialize (Archive &ar, const unsigned int)
 

Private Attributes

Setup< DataT > fSetup
 Setup representation.
 
Config fConfig
 Configuration.
 
SearchWindowMapContainer fSwMaps
 Search window map.
 

Friends

class ParametersIO
 
class boost::serialization::access
 Serialization function.
 

Detailed Description

template<typename DataT>
class cbm::algo::ca::Parameters< DataT >

A container for all external parameters of the CA tracking algorithm.

Definition at line 52 of file CaParameters.h.

Member Typedef Documentation

◆ DetectorID_t

template<typename DataT>
using cbm::algo::ca::Parameters< DataT >::DetectorID_t = std::underlying_type_t<EDetectorID>
private

Definition at line 55 of file CaParameters.h.

◆ StationArray_t

template<typename DataT>
template<typename T>
using cbm::algo::ca::Parameters< DataT >::StationArray_t = std::array<T, constants::size::MaxNstations>
private

Definition at line 57 of file CaParameters.h.

Constructor & Destructor Documentation

◆ Parameters() [1/5]

template<typename DataT>
cbm::algo::ca::Parameters< DataT >::Parameters ( )
default

Default constructor.

Referenced by operator=(), operator=(), Parameters(), Parameters(), and Parameters().

◆ Parameters() [2/5]

template<typename DataT>
Parameters::Parameters ( ca::Setup< DataT > && setup,
ca::Config && config,
ca::SearchWindowMapContainer && searchWindows )

Constructor from arguments.

Parameters
setupinitialized CA-setup
configinitialized CA config
searchWindowsinitialized search window container

Definition at line 31 of file CaParameters.cxx.

References fConfig, fSetup, and fSwMaps.

◆ Parameters() [3/5]

template<typename DataT>
template<typename DataIn>
cbm::algo::ca::Parameters< DataT >::Parameters ( const Parameters< DataIn > & other)
inline

Copy constructor with type conversion.

Definition at line 71 of file CaParameters.h.

References fConfig, fSetup, fSwMaps, GetConfig(), GetSearchWindows(), GetSetup(), and Parameters().

◆ Parameters() [4/5]

template<typename DataT>
cbm::algo::ca::Parameters< DataT >::Parameters ( const Parameters< DataT > & other)
default

Copy constructor.

References Parameters().

◆ ~Parameters()

template<typename DataT>
cbm::algo::ca::Parameters< DataT >::~Parameters ( )
defaultnoexcept

Destructor.

◆ Parameters() [5/5]

template<typename DataT>
cbm::algo::ca::Parameters< DataT >::Parameters ( Parameters< DataT > && other)
default

Move constructor.

References Parameters().

Member Function Documentation

◆ CheckConsistency()

template<typename DataT>
void Parameters::CheckConsistency ( ) const

Class invariant checker.

Definition at line 43 of file CaParameters.cxx.

◆ GetActiveSetup()

template<typename DataT>
const auto & cbm::algo::ca::Parameters< DataT >::GetActiveSetup ( ) const
inline

Gets active setup.

Definition at line 160 of file CaParameters.h.

References fSetup.

◆ GetCAIterations()

template<typename DataT>
const auto & cbm::algo::ca::Parameters< DataT >::GetCAIterations ( ) const
inline

Provides access to L1CAIteration vector (const)

Definition at line 154 of file CaParameters.h.

References fConfig.

◆ GetConfig()

template<typename DataT>
const Config & cbm::algo::ca::Parameters< DataT >::GetConfig ( ) const
inline

Constant accessor to CA config.

Definition at line 176 of file CaParameters.h.

References fConfig.

Referenced by Parameters().

◆ GetFieldMode()

template<typename DataT>
kf::EFieldMode cbm::algo::ca::Parameters< DataT >::GetFieldMode ( ) const
inline

Gets field mode.

Definition at line 102 of file CaParameters.h.

References fSetup, and GetFieldMode().

Referenced by GetFieldMode().

◆ GetGeometrySetup()

template<typename DataT>
const auto & cbm::algo::ca::Parameters< DataT >::GetGeometrySetup ( ) const
inline

Gets active setup.

Definition at line 163 of file CaParameters.h.

References fSetup.

◆ GetNcaIterations()

template<typename DataT>
int cbm::algo::ca::Parameters< DataT >::GetNcaIterations ( ) const
inline

Provides number of iterations.

Definition at line 157 of file CaParameters.h.

References fConfig.

Referenced by ToString().

◆ GetNstationsActive() [1/2]

template<typename DataT>
int cbm::algo::ca::Parameters< DataT >::GetNstationsActive ( ) const
inline

Gets total number of active stations.

Definition at line 105 of file CaParameters.h.

References fSetup.

Referenced by CbmBbaAlignmentMcbmTask::Exec(), CbmBbaAlignmentMcbmTask::Init(), IsActive(), and ToString().

◆ GetNstationsActive() [2/2]

template<typename DataT>
int cbm::algo::ca::Parameters< DataT >::GetNstationsActive ( EDetectorID detId) const
inline

Gets number of active stations for given detector ID.

Definition at line 108 of file CaParameters.h.

References fSetup.

◆ GetNstationsGeometry() [1/2]

template<typename DataT>
int cbm::algo::ca::Parameters< DataT >::GetNstationsGeometry ( ) const
inline

Gets total number of stations, provided by setup geometry.

Definition at line 111 of file CaParameters.h.

References fSetup.

Referenced by GetStationIndexGeometry(), and ToString().

◆ GetNstationsGeometry() [2/2]

template<typename DataT>
int cbm::algo::ca::Parameters< DataT >::GetNstationsGeometry ( EDetectorID detId) const
inline

Gets number of stations, provided by setup geometry for given detector ID.

Definition at line 114 of file CaParameters.h.

References fSetup.

◆ GetSearchWindows()

template<typename DataT>
const SearchWindowMapContainer & cbm::algo::ca::Parameters< DataT >::GetSearchWindows ( ) const
inline

Constant accessor to search window map container.

Definition at line 179 of file CaParameters.h.

References fSwMaps.

Referenced by Parameters().

◆ GetSetup()

template<typename DataT>
const Setup< DataT > & cbm::algo::ca::Parameters< DataT >::GetSetup ( ) const
inline

Constant accessor to CA setup.

Definition at line 173 of file CaParameters.h.

References fSetup.

Referenced by Parameters().

◆ GetStationIndexActive()

template<typename DataT>
int cbm::algo::ca::Parameters< DataT >::GetStationIndexActive ( int locId,
EDetectorID detId ) const
inline

Provides access to global indexes of stations among geometry (const)

Calculates global index of station used by track finder

Parameters
locIdlocal index of the tracking station (for a particular detector)
detIdID of the detector subsystem

Definition at line 148 of file CaParameters.h.

References fSetup.

◆ GetStationIndexGeometry()

template<typename DataT>
int cbm::algo::ca::Parameters< DataT >::GetStationIndexGeometry ( int locId,
EDetectorID detId ) const
inline

Provides access to local indexes of stations (const)

Calculates global index of station among geometry (accounts for inactive stations)

Parameters
locIdlocal index of the tracking station (for a particular detector)
detIdID of the detector subsystem

Definition at line 134 of file CaParameters.h.

References fSetup, and GetNstationsGeometry().

◆ GetStationIndexLocal()

template<typename DataT>
std::pair< EDetectorID, int > cbm::algo::ca::Parameters< DataT >::GetStationIndexLocal ( int geoId) const
inline

Provides access to the first index of the station on each particular detector (const)

Gets local index of station

Parameters
geoIdgeometry index of the tracking station
Returns
A pair (detectorID, local index of the tracking station)

Definition at line 122 of file CaParameters.h.

References fSetup.

◆ IsActive()

template<typename DataT>
bool cbm::algo::ca::Parameters< DataT >::IsActive ( EDetectorID detId) const
inline

Checks, if the detector subsystem active.

Parameters
detIdDetector ID

Definition at line 167 of file CaParameters.h.

References GetNstationsActive().

◆ operator=() [1/2]

template<typename DataT>
Parameters & cbm::algo::ca::Parameters< DataT >::operator= ( const Parameters< DataT > & other)
default

Copy assignment operator.

References Parameters().

◆ operator=() [2/2]

template<typename DataT>
Parameters & cbm::algo::ca::Parameters< DataT >::operator= ( Parameters< DataT > && other)
default

Move assignment operator.

References Parameters(), Print(), and ToString().

◆ Print()

template<typename DataT>
void Parameters::Print ( int verbosityLevel = 0) const

Prints configuration.

Definition at line 271 of file CaParameters.cxx.

References ToString().

Referenced by operator=().

◆ serialize()

template<typename DataT>
template<class Archive>
void cbm::algo::ca::Parameters< DataT >::serialize ( Archive & ar,
const unsigned int  )
inlineprivate

Definition at line 189 of file CaParameters.h.

References fConfig, fSetup, and fSwMaps.

◆ ToString()

template<typename DataT>
std::string Parameters::ToString ( int verbosity = 0,
int indentLevel = 0 ) const

String representation of the class contents.

Parameters
verbosityA verbose level for output
indentLevelIndent level of the string output

Sets red/green color dependently from flag

Definition at line 279 of file CaParameters.cxx.

References fConfig, fSetup, fSwMaps, GetNcaIterations(), GetNstationsActive(), GetNstationsGeometry(), cbm::algo::ca::constants::size::MaxNdetectors, cbm::algo::ca::constants::size::MaxNstations, cbm::algo::ca::constants::size::MaxNtriplets, cbm::algo::ca::constants::size::StationBits, and cbm::algo::ca::constants::size::TripletBits.

Referenced by operator=().

Friends And Related Symbol Documentation

◆ boost::serialization::access

template<typename DataT>
friend class boost::serialization::access
friend

Serialization function.

Definition at line 187 of file CaParameters.h.

References boost::serialization::access.

Referenced by boost::serialization::access.

◆ ParametersIO

template<typename DataT>
friend class ParametersIO
friend

Definition at line 53 of file CaParameters.h.

References ParametersIO.

Referenced by ParametersIO.

Member Data Documentation

◆ fConfig

template<typename DataT>
Config cbm::algo::ca::Parameters< DataT >::fConfig
private

Configuration.

Definition at line 183 of file CaParameters.h.

Referenced by GetCAIterations(), GetConfig(), GetNcaIterations(), Parameters(), Parameters(), serialize(), and ToString().

◆ fSetup

◆ fSwMaps

template<typename DataT>
SearchWindowMapContainer cbm::algo::ca::Parameters< DataT >::fSwMaps
private

Search window map.

Definition at line 184 of file CaParameters.h.

Referenced by GetSearchWindows(), Parameters(), Parameters(), serialize(), and ToString().


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