59namespace chron = std::chrono;
70 bool hasOutputFile = !opts.
OutputFile().empty();
73 if (!hasOutputFile && hasOutputType) {
74 throw FatalError(
"Output types specified, but no output file given: -o <file> missing");
77 if (hasOutputFile && !hasOutputType) {
78 throw FatalError(
"Output file specified, but no output types given: -O <types> missing");
82 throw FatalError(
"Archive compression enabled but compiled without Zstd: Remove --archive-compression flag");
86 throw FatalError(
"Local reco can't run without unpacking: Add 'Unpack' to the reco steps");
90 throw FatalError(
"Tracking can't run without local reco: Add 'LocalReco' to the reco steps");
100 const auto& readout = parFiles.
readout;
101 if (readout == std::nullopt) {
102 throw FatalError(
"Unpacking was required, but cannot run without readout parameters. Please specify the "
103 "\"readout\" node in the main config \""
104 +
Opts().MainConfigPath().
string() +
"\"");
108 auto Check = [&](Subsystem subsystem,
const auto& parNode) ->
bool {
109 if (
Opts().Has(subsystem) && parNode == std::nullopt) {
110 L_(error) <<
"Unpacking was required for " << subsystem <<
", but the parameters are not found in readout node";
118 valid = Check(Subsystem::MVD, readout->mvd) && valid;
119 valid = Check(Subsystem::STS, readout->sts) && valid;
121 valid = Check(Subsystem::MUCH, readout->much) && valid;
122 valid = Check(Subsystem::TRD, readout->trd) && valid;
123 valid = Check(Subsystem::TOF, readout->tof) && valid;
124 valid = Check(Subsystem::BMON, readout->bmon) && valid;
125 valid = Check(Subsystem::TRD2D, readout->trd2d) && valid;
129 throw FatalError(
"Some of the readout parameters were not provided for required unpacking steps (see errors "
130 "above). Please specify the parameters in "
131 +
Opts().MainConfigPath().
string() +
". Stop execution.");
138 if (
reco == std::nullopt) {
139 throw FatalError(
"Reconstruction of digi-timeslices was required, but cannot run without readout parameters. "
140 "Please specify the \"timesliceReco\" node in the main config "
141 +
Opts().MainConfigPath().
string() +
". Stop execution.");
145 auto Check = [&](Subsystem subsystem,
const auto& parNode) ->
bool {
146 if (
Opts().Has(subsystem) && parNode == std::nullopt) {
147 L_(error) <<
"Local reconstruction of digi-timeslice was required for " << subsystem
148 <<
", but the parameters"
149 " are not found in timesliceReco node";
156 valid = Check(Subsystem::STS,
reco->sts) && valid;
157 valid = Check(Subsystem::TRD,
reco->trd) && valid;
158 valid = Check(Subsystem::TRD,
reco->trd2d) && valid;
159 valid = Check(Subsystem::TOF,
reco->tof) && valid;
162 "Some of the parameters for local reconstruction of digi-timeslices were not provided (see errors "
163 "above). Please specify the parameters in "
164 +
Opts().MainConfigPath().
string() +
". Stop execution.");
169 "Parameters for tracking in timeslice were not provided (see errors above). Please specify the parameters in "
170 +
Opts().MainConfigPath().
string() +
". Stop execution.");
177 if (
Opts().ReconstructDigiEvents()) {
179 if (
reco == std::nullopt) {
180 throw FatalError(
"Reconstruction of digi-events was required, but cannot run without readout parameters. "
181 "Please specify the \"eventReco\" node in the main config "
182 +
Opts().MainConfigPath().
string() +
". Stop execution.");
186 auto Check = [&](Subsystem subsystem,
const auto& parNode) ->
bool {
187 if (
Opts().Has(subsystem) && parNode == std::nullopt) {
188 L_(error) <<
"Local reconstruction of digi-events was required for " << subsystem
189 <<
", but the parameters"
190 " are not found in eventReco node";
197 valid = Check(Subsystem::STS,
reco->sts) && valid;
198 valid = Check(Subsystem::TRD,
reco->trd) && valid;
199 valid = Check(Subsystem::TRD,
reco->trd2d) && valid;
200 valid = Check(Subsystem::TOF,
reco->tof) && valid;
201 if (
reco->tracking == std::nullopt) {
202 LOG(error) <<
"Parameters for tracking in digi-events were not found in eventReco node";
205 throw FatalError(
"Some of the parameters for local reconstruction of digi-events were not provided (see errors "
206 "above). Please specify the parameters in "
207 +
Opts().MainConfigPath().
string() +
". Stop execution.");
218 throw FatalError(
"digi-trigger, tracking or digi-event reconstruction were required, but the recoSetupPath node"
219 "is not provided with the config "
220 +
Opts().MainConfigPath().
string()
221 +
". Please specify it. "
231 if (
fInitialized)
throw std::runtime_error(
"Chain already initialized");
238 if (
Opts().HistogramUri() !=
"") {
240 std::make_shared<HistogramSender>(
Opts().HistogramUri(),
Opts().HistogramHwm(),
Opts().CompressHistograms());
245 fRunStartTimeNs = chron::duration_cast<chron::nanoseconds>(chron::system_clock::now().time_since_epoch()).count();
246 L_(info) <<
"Start time for run " << opts.
RunId() <<
" not provided => using current time";
251 if ((
fSender !=
nullptr) &&
Opts().DumpBatchQaHistograms()) {
252 L_(warn) <<
"Storing of the histograms in the batch mode was required with option --batch-qa-output=<file>, but "
253 "the histogram server is available. Since the priority of sending the histograms on the histogram "
254 "server is higher, the option --batch-qa-output=<file> will be ignored.";
257 xpu::device_prop props{xpu::device::active()};
259 <<
" OpenMP threads)";
263 L_(info) <<
"Monitoring enabled, sending to " << opts.
MonitorUri();
268 auto mainConfigNode = YAML::LoadFile(
Opts().MainConfigPath().
string());
272 fContext.recoParams.sts = yaml::Read<RecoParams::STS>(mainConfigNode[
"sts"]);
274 auto parFiles = yaml::Read<ParFiles>(mainConfigNode[
"parFiles"]);
291 yaml::ReadFromFile<bmon::ReadoutSetup>(
Opts().ParamsDir() / parFiles.readout->bmon->readout);
298 bool bLoadingOk =
false;
299 std::string sDefaultMessage =
"MUCH params file not defined for this setup => using hardcoded values";
300 if (std::nullopt != parFiles.readout->much &&
"" != parFiles.readout->much->readout) {
302 readoutSetup = yaml::ReadFromFile<much::ReadoutSetup>(
Opts().ParamsDir() / parFiles.readout->much->readout);
305 catch (YAML::BadFile&) {
309 "MUCH param file not found at " + parFiles.readout->much->readout +
" => using hardcoded values";
311 catch (YAML::ParserException& err) {
314 sDefaultMessage =
"Bad MUCH param file at " + parFiles.readout->much->readout +
": " + err.what()
315 +
" => using hardcoded values";
324 L_(info) << sDefaultMessage;
337 yaml::ReadFromFile<sts::ReadoutSetup>(
Opts().ParamsDir() / parFiles.readout->sts->readout);
338 auto chanMask = yaml::ReadFromFile<sts::ChannelMaskSet>(
Opts().ParamsDir() / parFiles.readout->sts->channelMask);
339 auto walkMap = yaml::ReadFromFile<sts::WalkMap>(
Opts().ParamsDir() / parFiles.readout->sts->walkMap);
342 sts::Unpack::Config cfg{.readout = readout, .walkMap = walkMap, .bCollectAuxData = bCollectAux};
343 fStsUnpack = std::make_unique<sts::Unpack>(cfg);
347 fStsDigiQa->RegisterReadoutSetup(readoutSetup);
354 bool bLoadingOk =
false;
355 std::string sDefaultMessage =
"MVD params file not defined for this setup => using hardcoded values";
356 if (std::nullopt != parFiles.readout->mvd &&
"" != parFiles.readout->mvd->readout) {
358 readoutSetup = yaml::ReadFromFile<mvd::ReadoutSetup>(
Opts().ParamsDir() / parFiles.readout->mvd->readout);
361 catch (YAML::BadFile&) {
365 "MVD param file not found at " + parFiles.readout->mvd->readout +
" => using hardcoded values";
367 catch (YAML::ParserException& err) {
371 "Bad MVD param file at " + parFiles.readout->mvd->readout +
": " + err.what() +
" => using hardcoded values";
379 fMvdUnpack = std::make_unique<mvd::Unpack>(cfg);
382 L_(info) << sDefaultMessage;
384 fMvdUnpack = std::make_unique<mvd::Unpack>(cfg);
396 yaml::ReadFromFile<tof::ReadoutSetup>(
Opts().ParamsDir() / parFiles.readout->tof->readout);
398 fTofUnpack = std::make_unique<tof::Unpack>(cfg);
402 auto cfg = yaml::ReadFromFile<trd::ReadoutConfig>(
Opts().ParamsDir() / parFiles.readout->trd->readout);
403 fTrdUnpack = std::make_unique<trd::Unpack>(cfg);
407 auto setup = yaml::ReadFromFile<trd2d::ReadoutSetup>(
Opts().ParamsDir() / parFiles.readout->trd2d->readout);
408 auto calib = yaml::ReadFromFile<trd2d::ReadoutCalib>(
Opts().ParamsDir() / parFiles.readout->trd2d->fee);
418 std::shared_ptr<RecoSetup> pRecoSetup{
nullptr};
420 pRecoSetup = std::make_shared<RecoSetup>((
Opts().ParamsDir() / parFiles.recoSetupPath.value()).string());
432 auto pTriggerQa = std::make_shared<evbuild::V0TriggerQa>(
fQaManager);
442 yaml::ReadFromFile<sts::HitfinderPars>(opts.
ParamsDir() / parFiles.timesliceReco->sts->hitfinder);
446 hitFinderPars.
setup = std::move(hitFinderSetup);
456 yaml::ReadFromFile<tof::CalibrateSetup>(opts.
ParamsDir() / parFiles.timesliceReco->tof->calibrate);
460 yaml::ReadFromFile<tof::HitfindSetup>(opts.
ParamsDir() / parFiles.timesliceReco->tof->hitfinder);
461 fTofHitFinder = std::make_unique<tof::Hitfind>(hitfindSetup);
471 auto setup = yaml::ReadFromFile<trd::HitfindSetup>(opts.
ParamsDir() / parFiles.timesliceReco->trd->hitfinder);
472 auto setup2d = yaml::ReadFromFile<trd::Hitfind2DSetup>(opts.
ParamsDir() / parFiles.timesliceReco->trd2d->hitfinder);
473 fTrdHitfind = std::make_unique<trd::Hitfind>(setup, setup2d);
496 std::string caParam = (
Opts().
ParamsDir() / parFiles.timesliceReco->tracking->capar).
string();
505 yaml::ReadFromFile<bmon::CalibrateSetup>(opts.
ParamsDir() / parFiles.eventReco->bmon->calibrate);
506 auto bmonHitSetup = yaml::ReadFromFile<bmon::HitfindSetup>(opts.
ParamsDir() / parFiles.eventReco->bmon->hitfinder);
524 std::string caParam = (
Opts().
ParamsDir() / parFiles.eventReco->tracking->capar).
string();
531 fV0Finder = std::make_unique<V0FinderChain>();
536 auto config = yaml::Read<kfp::V0FinderConfig>(mainConfigNode[
"v0finder"]);
547 L_(debug) <<
"CBM Reco finished initialization";
555 throw std::runtime_error(
"Chain not initialized");
564 xpu::scoped_timer t_(fmt::format(
"TS {}", ts.index()), &procMon.
time);
567 L_(info) <<
">>> Processing TS " << ts.index();
568 xpu::set<cbm::algo::Params>(
Params());
574 xpu::scoped_timer timerU(
"Unpack", &procMon.
timeUnpack);
587 L_(info) <<
"TS contains Digis: STS=" << digis.
fSts.size() <<
" MUCH=" << digis.
fMuch.size()
588 <<
" TOF=" << digis.
fTof.size() <<
" BMON=" << digis.
fBmon.size() <<
" TRD=" << digis.
fTrd.size()
589 <<
" TRD2D=" << digis.
fTrd2d.size() <<
" RICH=" << digis.
fRich.size() <<
" MVD=" << digis.
fMvd.size()
590 <<
" FSD=" << digis.
fFsd.size();
617 xpu::scoped_timer timerSTS(
"STS Reco", &procMon.
timeSTS);
620 auto stsResults = (*fStsHitFinder)(digis.
fSts, storeClusters);
621 stsHitfinderMonitor = std::move(stsResults.monitor);
622 recoData.
stsHits = stsResults.hits;
623 recoData.
stsClusters = std::move(stsResults.clusters);
629 xpu::scoped_timer timerTOF(
"TOF Reco", &procMon.
timeTOF);
631 auto [caldigis, calmonitor] = (*fTofCalibrator)(digis.
fTof);
632 auto nUnknownRPC = calmonitor.fDigiCalibUnknownRPC;
633 if (nUnknownRPC > 0) {
634 L_(error) <<
"TOF Digis with unknown RPCs: " << nUnknownRPC;
636 auto [
hits, hitmonitor, digiindices] = (*fTofHitFinder)(caldigis);
648 xpu::scoped_timer timerTRD(
"TRD Reco", &procMon.
timeTRD);
651 const auto& digis1d = digis.
fTrd;
652 const auto& digis2d = digis.
fTrd2d;
654 allDigis.reserve(digis1d.size() + digis2d.size());
655 std::copy(digis1d.begin(), digis1d.end(), std::back_inserter(allDigis));
656 std::copy(digis2d.begin(), digis2d.end(), std::back_inserter(allDigis));
657 auto trdResults = (*fTrdHitfind)(allDigis);
658 recoData.
trdHits = std::move(std::get<0>(trdResults));
662 L_(info) <<
"TS contains Hits: STS=" << recoData.
stsHits.NElements() <<
" TOF=" << recoData.
tofHits.NElements()
663 <<
" TRD=" << recoData.
trdHits.NElements();
669 xpu::scoped_timer timerCA(
"CA", &procMon.
timeCA);
679 recoData.
tracks = std::move(trackingOutput.tracks);
681 std::sort(recoData.
tracks.begin(), recoData.
tracks.end(),
683 return track1.fParPV.Time() < track2.fParPV.Time();
689 std::vector<DigiEvent> events;
691 auto [ev, mon] =
fEventBuild->Run(digis, recoData);
692 events = std::move(ev);
693 evbuildMonitor = mon;
701 for (
auto& event : events) {
706 auto v0FinderMonitor =
fV0Finder->GetMonitor();
755 (*fGeneralQa)(ts, (*fGeneralQaData));
774 L_(info) <<
"Track finding in a timeslice:";
778 L_(info) <<
"Track finding in digi events:";
791 if (
Opts().TimingsFile() !=
"") {
792 std::ofstream file(
Opts().TimingsFile().
string());
797 if (
fSender ==
nullptr &&
Opts().DumpBatchQaHistograms()) {
798 fQaManager->WriteHistograms(
Opts().BatchQaOutput().
string(),
Opts().CompressArchive());
806 if (
Opts().CollectKernelTimes()) {
814 L_(info) <<
"TS Processing time (Wall): " << timings.wall() <<
" ms";
827 auto [calDigis, calMonitor] = (*fBmonCalibrator)(digiEvent.
fBmon);
828 auto [
hits, hitMonitor, digiIndices] = (*fBmonHitFinder)(calDigis);
842 auto stsResults = (*fStsHitFinder)(digiEvent.
fSts);
844 if (stsResults.hits.NElements() < 4) {
848 recoEvent.
stsHits = stsResults.hits;
854 auto [caldigis, calmonitor] = (*fTofCalibrator)(digiEvent.
fTof);
855 auto [
hits, hitmonitor, digiindices] = (*fTofHitFinder)(caldigis);
857 if (
hits.NElements() < 2) {
868 const auto& digis1d = digiEvent.
fTrd;
869 const auto& digis2d = digiEvent.
fTrd2d;
871 allDigis.reserve(digis1d.size() + digis2d.size());
872 std::copy(digis1d.begin(), digis1d.end(), std::back_inserter(allDigis));
873 std::copy(digis2d.begin(), digis2d.end(), std::back_inserter(allDigis));
874 auto trdResults = (*fTrdHitfind)(allDigis);
876 recoEvent.
trdHits = std::move(std::get<0>(trdResults));
891 if (recoEvent.
tracks.size() < 2) {
899 triggers =
fV0Finder->ProcessEvent(recoEvent);
901 L_(info) <<
"!!! Found event with potential lambda candidates";
911template<
class Unpacker>
917 auto [digis, monitor, aux] = (*unpacker)(ts);
919 return std::make_tuple(digis, aux);
924template<
class MSMonitor>
936 auto MkKey = [&](std::string_view key) {
return fmt::format(
"{}{}", key,
Capitalize(det)); };
938 GetMonitor().QueueMetric(
"cbmreco", {{
"hostname", fles::system::current_hostname()}, {
"child",
Opts().
ChildId()}},
943 {MkKey(
"unpackNumMs"), monitor.
numMs},
955 GetMonitor().QueueMetric(
"cbmreco", {{
"hostname", fles::system::current_hostname()}, {
"child",
Opts().
ChildId()}},
957 {
"stsRecoNumClusters", (
unsigned long) monitor.
nClusterTotal},
958 {
"stsRecoNumHits", (
unsigned long) monitor.
nHitsTotal},
970 GetMonitor().QueueMetric(
"cbmreco", {{
"hostname", fles::system::current_hostname()}, {
"child",
Opts().
ChildId()}},
985 GetMonitor().QueueMetric(
"cbmreco", {{
"hostname", fles::system::current_hostname()}, {
"child",
Opts().
ChildId()}},
987 {
"trdRecoNumDigisIn", mon.
numDigis},
988 {
"trdRecoNumHits", mon.
numHits},
998 GetMonitor().QueueMetric(
"cbmreco", {{
"hostname", fles::system::current_hostname()}, {
"child",
Opts().
ChildId()}},
1000 {
"tofCalibTimeTotal", mon.
fTime.wall()},
1021 const MetricTagSet tags = {{
"hostname", fles::system::current_hostname()}, {
"child",
Opts().
ChildId()}};
1023 size_t nDigisTotal = 0;
1024 size_t nDigisInEventsTotal = 0;
1026 auto queueDetMetrics = [&](std::string_view det,
auto& detMon) {
1027 size_t nDigis = detMon.nDigis;
1028 size_t nDigisInEvents = detMon.nDigisInEvents;
1029 double selectionRatio = nDigis > 0 ? double(nDigisInEvents) / nDigis : 0;
1031 nDigisTotal += nDigis;
1032 nDigisInEventsTotal += nDigisInEvents;
1035 {{fmt::format(
"{}NumDigisTotal", det), nDigis},
1036 {fmt::format(
"{}NumDigisInEvents", det), nDigisInEvents},
1037 {fmt::format(
"{}EvSelectionRatio", det), selectionRatio}});
1050 double totalSelectionRatio = nDigisTotal > 0 ? double(nDigisInEventsTotal) / nDigisTotal : 0;
1065 {
"totalEvSelectionRatio", totalSelectionRatio}});
1076 GetMonitor().QueueMetric(
"cbmreco", {{
"hostname", fles::system::current_hostname()}, {
"child",
Opts().
ChildId()}},
1102 MetricFieldSet fields = {
1103 {
"processingTimeTotal", mon.
time.wall()}, {
"processingThroughput",
FilterNan(mon.
time.throughput())},
1111 fields.emplace_back(
"tsDelta", *mon.
tsDelta);
1114 GetMonitor().QueueMetric(
"cbmreco", {{
"hostname", fles::system::current_hostname()}, {
"child",
Opts().
ChildId()}},
1131 GetMonitor().QueueMetric(
"cbmreco", {{
"hostname", fles::system::current_hostname()}, {
"child",
Opts().
ChildId()}},
Collection of auxiliary data from unpackers (header)
source file for the ca::Track class
static vector< vector< QAHit > > hits
Configuration structure for V0 selector in mCBM.
This file contains the definition of the ParFiles class.
QA manager for the online data reconstruction.
A structure to keep parameter files for reconstruction.
A collection of reconstruction setup unit interfaces for different CBM subsystems.
QA module for STS raw digis (source)
A chain class to execute CA tracking algorithm in online reconstruction (header)
Calibrator for the BMON digis (implementation)
Class to store different triggers for a given event.
bool Test(ETrigger key) const
Tests a particular single trigger.
Data class for a single-channel message in the STS.
Data class for expanded digital TOF information.
A vector that is partitioned into multiple subvectors.
const std::vector< RecoData > & OutputTypes() const
const std::string & MonitorUri() const
fs::path ParamsDir() const
bool ReconstructDigiEvents() const
uint64_t RunStart() const
bool CompressArchive() const
bool DumpBatchQaHistograms() const
fs::path OutputFile() const
bool HasOutput(RecoData recoData) const
bool CollectAuxData() const
bool Has(fles::Subsystem detector) const
const std::string & ChildId() const
std::unique_ptr< tof::Hitfind > fTofHitFinder
std::unique_ptr< tof::HitfindQa > fTofHitFinderQa
bool fbReconstructDigiEvents
std::optional< u64 > prevTsId
std::unique_ptr< TrackingChain > fTrackingEvent
Tracking in event.
void Init(const Options &)
std::unique_ptr< bmon::HitfindQa > fBmonHitFinderQa
void Validate(const Options &opts) const
Validation of program options.
std::unique_ptr< trd::Hitfind > fTrdHitfind
void QueueTofRecoMetrics(const tof::HitfindMonitorData &)
std::unique_ptr< mvd::Unpack > fMvdUnpack
std::shared_ptr< HistogramSender > fSender
std::unique_ptr< bmon::Unpack > fBmonUnpack
std::unique_ptr< sts::Unpack > fStsUnpack
std::unique_ptr< rich::Unpack > fRichUnpack
std::unique_ptr< V0FinderChain > fV0Finder
V0-finding chain (in event or a bunch of events)
void QueueTrdRecoMetrics(const trd::HitfindMonitorData &)
std::unique_ptr< much::Unpack > fMuchUnpack
CbmEventTriggers ReconstructEvent(const DigiEvent &event)
auto RunUnpacker(const std::unique_ptr< Unpacker > &, const fles::Timeslice &) -> UnpackResult_t< Unpacker >
xpu::timings fTimesliceTimesAcc
evselect::Monitor fEvSelectingMonitor
Monitor for event selecting.
std::unique_ptr< sts::DigiQa > fStsDigiQa
Raw STS-digis QA.
std::unique_ptr< tof::Unpack > fTofUnpack
void QueueProcessingMetrics(const ProcessingMonitor &)
std::unique_ptr< qa::GeneralQaData > fGeneralQaData
Object aggregating the data points used in the GeneralQa.
std::unique_ptr< qa::Manager > fQaManager
static double FilterNan(double x)
std::unique_ptr< bmon::Calibrate > fBmonCalibrator
void QueueStsRecoMetrics(const sts::HitfinderMon &)
std::unique_ptr< bmon::Hitfind > fBmonHitFinder
std::unique_ptr< tof::Calibrate > fTofCalibrator
void QueueTofCalibMetrics(const tof::CalibrateMonitorData &)
std::unique_ptr< trd2d::Unpack > fTrd2dUnpack
std::unique_ptr< qa::RecoGeneralQa > fGeneralQa
QA of online processing itself.
std::unique_ptr< sts::HitfinderChain > fStsHitFinder
std::unique_ptr< TrackingChain > fTracking
Tracking in timeslice.
std::unique_ptr< trd::Unpack > fTrdUnpack
std::unique_ptr< evbuild::EventbuildChain > fEventBuild
std::unique_ptr< fsd::Unpack > fFsdUnpack
RecoResults Run(const fles::Timeslice &)
void PrintTimings(xpu::timings &)
void QueueUnpackerMetricsDet(const UnpackMonitor< MSMonitor > &)
void QueueTrackingMetrics(const ca::TrackingMonitorData &)
void QueueEvbuildMetrics(const evbuild::EventbuildChainMonitorData &)
void QueueProcessingExtraMetrics(const ProcessingExtraMonitor &)
const RecoParams & Params() const
Monitor & GetMonitor() const
void SetContext(const ChainContext *ctx)
const Options & Opts() const
const Timer & GetTimer(ETimerKey key) const
Gets timer.
int GetCounterValue(ECounterKey key) const
Gets counter value.
double GetTotalMs() const
Gets total time [ms].
Class representing an output track in the CA tracking algorithm.
Configuration of digi event building.
Provides the hardware-to-software address mapping for the CBM-RICH.
Provides the hardware-to-software address mapping for the CBM-STS.
A light-weight TRD hit class for online reconstruction, based on CbmTrdHit. .
@ RecoHit
number of reconstructed hits
@ RecoTrack
number of reconstructed tracks
@ SubTS
number of sub time-slices
@ RecoHitUsed
number of used reconstructed hits
MonitorData< ECounter, ETimer > TrackingMonitorData
@ EventsNeStsHits
Events with not enough STS hits.
@ LambdaCandidates
Number of lambda-candidates, returned by KFParticleFinder.
@ EventsTotal
Total number of events processed.
@ EventsSelected
Number of selected events.
@ EventsNeTofHits
Events with enough STS hits, but not enough TOF hits.
@ Timeslices
number of processed timeslices
@ EventsNeTracks
Events with enough hits, but not enough tracks.
@ KfpLambdaCandidates
Number of lambda-candidates.
size_t SizeBytes(const fles::Timeslice &ts)
std::tuple< algo_traits::Output_t< Unpacker >, algo_traits::Aux_t< Unpacker > > UnpackResult_t
std::string MakeReportSubtimers(std::string_view title, const xpu::timings &t, size_t align)
Print timings from subtimers.
std::string MakeReportYaml(const xpu::timings &t)
Print timings in YAML format.
std::string 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)....
std::string_view ToString(T t)
std::vector< T, PODAllocator< T > > PODVector
PODVector is a std::vector that doesn't initialize its elements.
std::string Capitalize(std::string_view str)
Capitalize the first letter of a string. The rest of the string is made lowercase.
Collection of auxiliary digi objects from different module unpackers.
UnpackAux< bmon::UnpackAuxData > fBmon
UnpackAux< trd2d::UnpackAuxData > fTrd2d
UnpackAux< rich::UnpackAuxData > fRich
UnpackAux< sts::UnpackAuxData > fSts
UnpackAux< much::UnpackAuxData > fMuch
UnpackAux< fsd::UnpackAuxData > fFsd
UnpackAux< tof::UnpackAuxData > fTof
UnpackAux< trd::UnpackAuxData > fTrd
UnpackAux< mvd::UnpackAuxData > fMvd
Collection of digis from all detector systems.
PODVector< CbmRichDigi > fRich
Unpacked RICH digis.
PODVector< CbmTrdDigi > fTrd
Unpacked TRD digis.
PODVector< CbmStsDigi > fSts
Unpacked STS digis.
PODVector< CbmTrdDigi > fTrd2d
Unpacked TRD2D digis.
PODVector< CbmFsdDigi > fFsd
Unpacked FSD digis.
PODVector< CbmTofDigi > fTof
Unpacked TOF digis.
PODVector< CbmMvdRawDigi > fMvd
Unpacked MVD digis.
PODVector< CbmMuchDigi > fMuch
Unpacked MUCH digis.
PODVector< CbmBmonDigi > fBmon
Unpacked Bmon digis.
Event data with event number and trigger time.
Indicates an unrecoverable error. Should tear down the process.
Class to hold the paths to the parameter files for the different detectors.
std::optional< RecoParFiles > eventReco
event reconstruction parameters
std::optional< RecoParFiles > timesliceReco
timeslice reconstruction parameters
std::optional< ReadoutParFiles > readout
readout parameters
std::optional< std::string > recoSetupPath
Path to reco-setup.
std::optional< i64 > tsDelta
struct cbm::algo::RecoParams::STS::Memory memory
ca::Vector< std::vector< HitId_t > > trackTofHitIndices
PartitionedVector< trd::Hit > trdHits
PODVector< CbmMuchDigi > muchDigis
PartitionedVector< sts::Cluster > stsClusters
ca::Vector< ca::Track > tracks
PartitionedVector< tof::Hit > tofHits
ca::Vector< std::vector< HitId_t > > trackTrdHitIndices
std::vector< DigiEvent > events
PODVector< CbmTrdDigi > trd2dDigis
PartitionedVector< bmon::Hit > bmonHits
PODVector< CbmFsdDigi > fsdDigis
PODVector< CbmMvdRawDigi > mvdDigis
PartitionedSpan< sts::Hit > stsHits
PODVector< CbmTofDigi > tofDigis
ca::Vector< std::vector< HitId_t > > trackStsHitIndices
PODVector< CbmRichDigi > richDigis
PODVector< CbmStsDigi > stsDigis
PODVector< CbmTrdDigi > trdDigis
PODVector< CbmBmonDigi > bmonDigis
Output from the TrackingChain.
ca::Vector< ca::Track > tracks
Reconstructed tracks.
ca::Vector< std::vector< std::pair< uint32_t, uint32_t > > > trdHitIndices
TRD hit indices.
ca::Vector< std::vector< std::pair< uint32_t, uint32_t > > > tofHitIndices
TOF hit indices.
ca::Vector< std::vector< std::pair< uint32_t, uint32_t > > > stsHitIndices
STS hit indices.
std::string print() const
Readout setup / Hardware cabling for BMon Used to create the hardware mapping for the BMon unpacker.
double ExpansionFactor() const
size_t numTriggers
Number of input triggers.
EventBuilderDetectorMonitorData much
Monitoring data for MUCH.
EventBuilderDetectorMonitorData rich
Monitoring data for RICH.
size_t numEvents
Number of built and selected events.
EventBuilderDetectorMonitorData sts
Monitoring data for STS.
EventBuilderDetectorMonitorData tof
Monitoring data for TOF.
EventBuilderDetectorMonitorData mvd
Monitoring data for MVD.
EventBuilderDetectorMonitorData bmon
Monitoring data for Bmon.
EventBuilderDetectorMonitorData trd2d
Monitoring data for TRD2D.
xpu::timings time
Time for event building.
EventBuilderDetectorMonitorData trd
Monitoring data for TRD.
TimeClusterTriggerMonitorData hitMultTrigger
EventBuilderMonitorData evbuild
TimeClusterTriggerMonitorData digiMultTrigger
V0TriggerMoniData v0Trigger
xpu::timings time
Time for trigger building.
xpu::timings time
Time for trigger building.
size_t numTrackPairsAfterTimeCut
Readout setup / Hardware cabling for MUCH Used to create the hardware mapping for the MUCH unpacker.
Readout setup / Hardware cabling for MVD Used to create the hardware mapping for the MVD unpacker.
RecoParams::STS::Memory memory
i32 nClusterBucketOverflow
static LandauTable FromFile(fs::path path)
Readout setup / Hardware cabling for STS Used to create the hardware mapping for the STS unpacker.
Monitoring data for calibration.
size_t fDigiCalibUnknownRPC
Monitoring data for hitfinding.
Readout setup / Hardware cabling for TOF Used to create the hardware mapping for the TOF unpacker.
Monitoring data for hitfinding.