CbmRoot
Loading...
Searching...
No Matches
CbmReco.h
Go to the documentation of this file.
1/* Copyright (C) 2022 GSI Helmholtzzentrum fuer Schwerionenforschung, Darmstadt
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Volker Friese [committer] */
4
5#ifndef CBMRECO_H
6#define CBMRECO_H 1
7
8#include "CbmDefs.h"
9
10// Hide the Monitor class from ROOT to not confuse it.
11// A similar issue with ROOT and gcc9 was already discovered by ALICE O2:
12// https://github.com/AliceO2Group/AliceO2/pull/4858
13#if !defined(__CLING__) && !defined(__ROOTCLING__)
14#include "Monitor.hpp"
15#else
16namespace cbm
17{
18 class Monitor;
19}
20#endif
21
22#include "evbuild/Config.h"
23
24#include <TString.h>
25
26#include <map>
27#include <string>
28#include <utility>
29
30
44class CbmReco {
45
46 public:
47 // Configuration structure
48 // TODO: move more settings here
49 struct Config {
50 bool dumpSetup = false;
51 };
52
54 //CbmReco() {};
55
56
64 CbmReco(Config config, std::string source, std::string outFile, std::string configFile,
65 int32_t numTs = std::numeric_limits<int32_t>::max(), uint16_t port = 0, cbm::Monitor* monitor = nullptr);
66
67
75 CbmReco(Config config, std::vector<std::string> sources, std::string outFile, std::string configFile,
76 int32_t numTs = std::numeric_limits<int32_t>::max(), uint16_t port = 0, cbm::Monitor* monitor = nullptr);
77
78
80 virtual ~CbmReco(){};
81
82
86 std::string ListSources() const;
87
88
92 int32_t Run();
93
94
95 private:
97 std::vector<std::string> fSourceNames = {};
98 std::string fOutputFileName = "";
99 std::string fConfigFileName = "";
100 int32_t fNumTs = 0;
101 uint16_t fHttpServerPort = 0;
102 cbm::Monitor* fMonitor = nullptr;
103
105};
106
107#endif /* CBMRECO_H */
Main steering class of reconstruction in CBM.
Definition CbmReco.h:44
CbmReco(Config config, std::vector< std::string > sources, std::string outFile, std::string configFile, int32_t numTs=std::numeric_limits< int32_t >::max(), uint16_t port=0, cbm::Monitor *monitor=nullptr)
Standard constructor for list of sources.
virtual ~CbmReco()
Destructor.
Definition CbmReco.h:80
cbm::Monitor * fMonitor
Definition CbmReco.h:102
std::string ListSources() const
List all entries in the input vector.
Definition CbmReco.cxx:65
int32_t Run()
Configure and execute run.
Definition CbmReco.cxx:78
Config fConfig
Configuration.
Definition CbmReco.h:96
ClassDef(CbmReco, 1)
std::string fOutputFileName
Output file (ROOT)
Definition CbmReco.h:98
int32_t fNumTs
Number of timeslices to process.
Definition CbmReco.h:100
CbmReco(Config config, std::string source, std::string outFile, std::string configFile, int32_t numTs=std::numeric_limits< int32_t >::max(), uint16_t port=0, cbm::Monitor *monitor=nullptr)
Default constructor.
std::vector< std::string > fSourceNames
Sources (input files or stream)
Definition CbmReco.h:97
std::string fConfigFileName
Configuration file (YAML)
Definition CbmReco.h:99
uint16_t fHttpServerPort
Definition CbmReco.h:101