CbmRoot
Loading...
Searching...
No Matches
cbm::algo Namespace Reference

Namespaces

namespace  algo_traits
 
namespace  bmon
 
namespace  BuildInfo
 
namespace  ca
 TODO: SZh 8.11.2022: add selection of parameterisation.
 
namespace  detail
 
namespace  evbuild
 
namespace  kf
 
namespace  much
 
namespace  mvd
 
namespace  openmp
 
namespace  qa
 
namespace  rich
 
namespace  sts
 
namespace  tof
 
namespace  trd
 
namespace  trd2d
 
namespace  ts_utils
 
namespace  yaml
 

Classes

struct  AuxDigiData
 Collection of auxiliary digi objects from different module unpackers. More...
 
struct  ChainContext
 
class  CommonUnpacker
 
struct  DigiData
 Collection of digis from all detector systems. More...
 
struct  DigiEvent
 Event data with event number and trigger time. More...
 
struct  FatalError
 Indicates an unrecoverable error. Should tear down the process. More...
 
struct  GPUReco
 
class  Histo1D
 
class  HistogramSender
 
class  MainConfig
 Configuration of online data processing. More...
 
class  MemoryLogger
 Track the memory usage of the process and write it to the log. More...
 
class  Options
 
class  PaddedValue
 A class that represents a value with padding to a certain size. More...
 
struct  Params
 
class  ParFiles
 Class to hold the paths to the parameter files for the different detectors. More...
 
class  PartitionedSpan
 
class  PartitionedVector
 A vector that is partitioned into multiple subvectors. More...
 
class  PODAllocator
 Allocator for plain old data types. More...
 
struct  ProcessingError
 
struct  ProcessingExtraMonitor
 Monitor for additional processing steps. More...
 
struct  ProcessingMonitor
 
class  Reco
 
struct  RecoParams
 RecoParams contains all parameters to configure reconstruction. More...
 
struct  RecoResults
 
class  StorableRecoResults
 
class  SubChain
 
class  TimingsFormat
 
class  TrackingChain
 A chain for tracking algorithm. More...
 
struct  TrackingChainConfig
 Configuration reader for the TrackingChain class. More...
 
class  TrackingSetup
 A detector setup interface class for tracking input data initialization. More...
 
struct  UnpackAux
 
struct  UnpackKey
 
struct  UnpackMonitor
 
class  UnpackMSBase
 

Typedefs

using i8 = std::int8_t
 
using u8 = std::uint8_t
 
using i16 = std::int16_t
 
using u16 = std::uint16_t
 
using i32 = std::int32_t
 
using u32 = std::uint32_t
 
using i64 = std::int64_t
 
using u64 = std::uint64_t
 
using f32 = float
 
using f64 = double
 
using real = f32
 
template<typename T >
using PaddedToCacheLine = PaddedValue<T, SizeOfCacheLine>
 
template<typename T >
using PartitionedPODVector = PartitionedVector<T, PODAllocator<T>>
 
template<class T >
using PODVector = std::vector<T, PODAllocator<T>>
 PODVector is a std::vector that doesn't initialize its elements.
 
template<class Unpacker >
using UnpackResult_t = std::tuple<algo_traits::Output_t<Unpacker>, algo_traits::Aux_t<Unpacker>>
 
using RecoResultsInputArchive
 
using RecoResultsOutputArchive
 

Enumerations

enum class  Step { Unpack , DigiTrigger , LocalReco , Tracking }
 
enum class  RecoData {
  DigiTimeslice , DigiEvent , Cluster , Hit ,
  Track
}
 
enum class  Setup { mCBM2022 , mCBM2024_03 , mCBM2024_05 }
 
enum class  QaStep {
  BeamBmon , UnpackBmon , UnpackSts , UnpackMvd ,
  UnpackRich , UnpackTrd1d , UnpackTrd2d , UnpackMuch ,
  UnpackTof , UnpackFsd , EventBuilding , RecoBmon ,
  RecoSts , RecoMvd , RecoRich , RecoTrd1d ,
  RecoTrd2d , RecoMuch , RecoTof , RecoFsd ,
  Tracking
}
 
enum  ProfilingLevel { ProfilingNone = 0 , ProfilingSummary = 1 , ProfilingPerTS = 2 }
 
enum  GpuConstants {
  kSortDigisBlockSize = 512 , kSortDigisItemsPerThread = 15 , kSortClustersBlockSize = 512 , kSortClustersItemsPerThread = 15 ,
  kFindClusterBlockSize = 1024 , kFindHitsBlockSize = 64 , kFindHitsChunksPerModule = 16
}
 

Functions

task_thread_pool::task_thread_pool & GetGlobalSTLThreadPool ()
 Get the global thread pool for parallel stl algorithms.
 
template<typename It , typename Compare >
void Sort (It first, It last, Compare comp)
 Wrapper for std::sort.
 
template<typename T , template< typename > class Container>
 PartitionedSpan (Container< T > &, gsl::span< const size_t >, gsl::span< const u32 >) -> PartitionedSpan< T >
 
template<typename T , template< typename > class Container>
 PartitionedSpan (const Container< T > &, gsl::span< const size_t >, gsl::span< const u32 >) -> PartitionedSpan< const T >
 
template<typename T , typename Allocator >
 PartitionedSpan (PartitionedVector< T, Allocator > &) -> PartitionedSpan< T >
 
template<typename T , typename Allocator >
 PartitionedSpan (const PartitionedVector< T, Allocator > &) -> PartitionedSpan< const T >
 
template<typename T >
std::vector< T > ToStdVector (const PODVector< T > &vec)
 
template<typename T >
PODVector< T > ToPODVector (const std::vector< T > &vec)
 
size_t GetCurrentRSS ()
 Get the current resident set size (pyhysical memory usage) of the process.
 
size_t GetPeakRSS ()
 Get the peak resident set size (pyhysical memory usage) of the process.
 
template<typename T , typename = std::enable_if_t<detail::EnumHasDict_v<T>>>
std::optional< T > FromString (std::string_view str, bool caseSensitive=false)
 
template<typename T , typename = std::enable_if_t<detail::EnumHasDict_v<T>>>
std::string_view ToString (T t)
 
std::string MakeReport (std::string_view title, const xpu::timings &t, size_t align=40)
 Print timings from top-level times and subtimers.
 
std::string MakeReportSubtimers (std::string_view title, const xpu::timings &t, size_t align=40)
 Print timings from subtimers.
 
std::string MakeReportSummary (std::string_view, const xpu::timings &t, size_t align=40)
 Only print the top-level times (Elapsed time, total kernel time, memcpy and memset times). Disregard subtimers and kernel times.
 
std::string MakeReportYaml (const xpu::timings &t)
 Print timings in YAML format.
 
Histo1D operator+ (Histo1D h1, const Histo1D &h2)
 Adding two histograms.
 

Variables

constexpr size_t SizeOfCacheLine = 64
 

Typedef Documentation

◆ f32

using cbm::algo::f32 = float

Definition at line 24 of file Definitions.h.

◆ f64

using cbm::algo::f64 = double

Definition at line 25 of file Definitions.h.

◆ i16

using cbm::algo::i16 = std::int16_t

Definition at line 18 of file Definitions.h.

◆ i32

using cbm::algo::i32 = std::int32_t

Definition at line 20 of file Definitions.h.

◆ i64

using cbm::algo::i64 = std::int64_t

Definition at line 22 of file Definitions.h.

◆ i8

using cbm::algo::i8 = std::int8_t

Definition at line 16 of file Definitions.h.

◆ PaddedToCacheLine

template<typename T >
using cbm::algo::PaddedToCacheLine = PaddedValue<T, SizeOfCacheLine>

Definition at line 80 of file PaddedValue.h.

◆ PartitionedPODVector

template<typename T >
using cbm::algo::PartitionedPODVector = PartitionedVector<T, PODAllocator<T>>

Definition at line 224 of file PartitionedVector.h.

◆ PODVector

template<class T >
using cbm::algo::PODVector = std::vector<T, PODAllocator<T>>

PODVector is a std::vector that doesn't initialize its elements.

Definition at line 17 of file PODVector.h.

◆ real

Definition at line 30 of file Definitions.h.

◆ RecoResultsInputArchive

Initial value:
fles::InputArchive<StorableRecoResults, StorableRecoResults, fles::ArchiveType::RecoResultsArchive>

Definition at line 13 of file RecoResultsInputArchive.h.

◆ RecoResultsOutputArchive

Initial value:
fles::OutputArchive<StorableRecoResults, StorableRecoResults, fles::ArchiveType::RecoResultsArchive>

Definition at line 13 of file RecoResultsOutputArchive.h.

◆ u16

using cbm::algo::u16 = std::uint16_t

Definition at line 19 of file Definitions.h.

◆ u32

using cbm::algo::u32 = std::uint32_t

Definition at line 21 of file Definitions.h.

◆ u64

using cbm::algo::u64 = std::uint64_t

Definition at line 23 of file Definitions.h.

◆ u8

using cbm::algo::u8 = std::uint8_t

Definition at line 17 of file Definitions.h.

◆ UnpackResult_t

template<class Unpacker >
using cbm::algo::UnpackResult_t = std::tuple<algo_traits::Output_t<Unpacker>, algo_traits::Aux_t<Unpacker>>

Definition at line 87 of file Reco.h.

Enumeration Type Documentation

◆ GpuConstants

Enumerator
kSortDigisBlockSize 
kSortDigisItemsPerThread 
kSortClustersBlockSize 
kSortClustersItemsPerThread 
kFindClusterBlockSize 
kFindHitsBlockSize 
kFindHitsChunksPerModule 

Definition at line 23 of file Hitfinder.h.

◆ ProfilingLevel

Enumerator
ProfilingNone 
ProfilingSummary 
ProfilingPerTS 

Definition at line 12 of file ProfilingLevel.h.

◆ QaStep

enum class cbm::algo::QaStep
strong
Enumerator
BeamBmon 
UnpackBmon 
UnpackSts 
UnpackMvd 
UnpackRich 
UnpackTrd1d 
UnpackTrd2d 
UnpackMuch 
UnpackTof 
UnpackFsd 
EventBuilding 
RecoBmon 
RecoSts 
RecoMvd 
RecoRich 
RecoTrd1d 
RecoTrd2d 
RecoMuch 
RecoTof 
RecoFsd 
Tracking 

Definition at line 57 of file Definitions.h.

◆ RecoData

enum class cbm::algo::RecoData
strong
Enumerator
DigiTimeslice 
DigiEvent 
Cluster 
Hit 
Track 

Definition at line 41 of file Definitions.h.

◆ Setup

enum class cbm::algo::Setup
strong
Enumerator
mCBM2022 
mCBM2024_03 
mCBM2024_05 

Definition at line 50 of file Definitions.h.

◆ Step

enum class cbm::algo::Step
strong
Enumerator
Unpack 
DigiTrigger 
LocalReco 
Tracking 

Definition at line 33 of file Definitions.h.

Function Documentation

◆ FromString()

template<typename T , typename = std::enable_if_t<detail::EnumHasDict_v<T>>>
std::optional< T > cbm::algo::FromString ( std::string_view str,
bool caseSensitive = false )

Definition at line 50 of file EnumDict.h.

References cbm::algo::detail::EnumDict.

Referenced by std::operator>>(), and cbm::algo::yaml::Read().

◆ GetCurrentRSS()

size_t cbm::algo::GetCurrentRSS ( )

Get the current resident set size (pyhysical memory usage) of the process.

Returns
The current resident set size in bytes
Note
Returns zero if the value cannot be determined

Definition at line 15 of file System.cxx.

Referenced by cbm::algo::MemoryLogger::Log().

◆ GetGlobalSTLThreadPool()

task_thread_pool::task_thread_pool & cbm::algo::GetGlobalSTLThreadPool ( )

Get the global thread pool for parallel stl algorithms.

This function returns a reference to the global thread pool used by the parallel stl algorithms. At the beginning it's initialized with the number of available threads. Otherwise this function should only be used in conjunction with the parallel stl algorithms via poolstl.

Definition at line 8 of file Algorithm.cxx.

Referenced by main(), and Sort().

◆ GetPeakRSS()

size_t cbm::algo::GetPeakRSS ( )

Get the peak resident set size (pyhysical memory usage) of the process.

Returns
The peak resident set size in bytes
Note
Returns zero if the value cannot be determined

Definition at line 35 of file System.cxx.

Referenced by cbm::algo::MemoryLogger::Log().

◆ MakeReport()

std::string cbm::algo::MakeReport ( std::string_view title,
const xpu::timings & t,
size_t align )

Print timings from top-level times and subtimers.

Definition at line 184 of file TimingsFormat.cxx.

References cbm::algo::TimingsFormat::Begin(), cbm::algo::TimingsFormat::Finalize(), cbm::algo::TimingsFormat::Fmt(), and cbm::algo::TimingsFormat::Title().

◆ MakeReportSubtimers()

std::string cbm::algo::MakeReportSubtimers ( std::string_view title,
const xpu::timings & t,
size_t align )

◆ MakeReportSummary()

std::string cbm::algo::MakeReportSummary ( std::string_view title,
const xpu::timings & t,
size_t align )

Only print the top-level times (Elapsed time, total kernel time, memcpy and memset times). Disregard subtimers and kernel times.

Definition at line 202 of file TimingsFormat.cxx.

References cbm::algo::TimingsFormat::Begin(), cbm::algo::TimingsFormat::Finalize(), cbm::algo::TimingsFormat::FmtSummary(), and cbm::algo::TimingsFormat::Title().

Referenced by cbm::algo::Reco::Finalize(), and cbm::algo::Reco::PrintTimings().

◆ MakeReportYaml()

std::string cbm::algo::MakeReportYaml ( const xpu::timings & t)

Print timings in YAML format.

Definition at line 211 of file TimingsFormat.cxx.

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

◆ operator+()

Histo1D cbm::algo::operator+ ( Histo1D h1,
const Histo1D & h2 )
inline

Adding two histograms.

Parameters
h1,h2Histograms to be added
Returns
Sum histogram

Definition at line 151 of file Histo1D.h.

◆ PartitionedSpan() [1/4]

template<typename T , template< typename > class Container>
cbm::algo::PartitionedSpan ( const Container< T > & ,
gsl::span< const size_t > ,
gsl::span< const u32 >  ) -> PartitionedSpan< const T >

◆ PartitionedSpan() [2/4]

template<typename T , typename Allocator >
cbm::algo::PartitionedSpan ( const PartitionedVector< T, Allocator > & ) -> PartitionedSpan< const T >

◆ PartitionedSpan() [3/4]

template<typename T , template< typename > class Container>
cbm::algo::PartitionedSpan ( Container< T > & ,
gsl::span< const size_t > ,
gsl::span< const u32 >  ) -> PartitionedSpan< T >

◆ PartitionedSpan() [4/4]

template<typename T , typename Allocator >
cbm::algo::PartitionedSpan ( PartitionedVector< T, Allocator > & ) -> PartitionedSpan< T >

◆ Sort()

template<typename It , typename Compare >
void cbm::algo::Sort ( It first,
It last,
Compare comp )

Wrapper for std::sort.

Attempts to use the parallel version of std::sort if available. Falls back to the sequential version otherwise. Parallel version currently requires Linux, GCC compiler and libTBB.

Definition at line 46 of file Algorithm.h.

References first, and GetGlobalSTLThreadPool().

Referenced by cbm::algo::CommonUnpacker< Digi, MSMonitor, MSAux >::DoSort().

◆ ToPODVector()

template<typename T >
PODVector< T > cbm::algo::ToPODVector ( const std::vector< T > & vec)

Definition at line 26 of file PODVector.h.

◆ ToStdVector()

template<typename T >
std::vector< T > cbm::algo::ToStdVector ( const PODVector< T > & vec)

Definition at line 20 of file PODVector.h.

Referenced by makeStorableRecoResults(), and cbm::algo::DigiData::ToStorable().

◆ ToString()

Variable Documentation

◆ SizeOfCacheLine

size_t cbm::algo::SizeOfCacheLine = 64
inlineconstexpr

Definition at line 77 of file PaddedValue.h.