Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • le.koch/cbmroot
  • patrick.pfistner_AT_kit.edu/cbmroot
  • lena.rossel_AT_stud.uni-frankfurt.de/cbmroot
  • i.deppner/cbmroot
  • fweig/cbmroot
  • karpushkin_AT_inr.ru/cbmroot
  • v.akishina/cbmroot
  • rishat.sultanov_AT_cern.ch/cbmroot
  • l_fabe01_AT_uni-muenster.de/cbmroot
  • pwg-c2f/cbmroot
  • j.decuveland/cbmroot
  • a.toia/cbmroot
  • i.vassiliev/cbmroot
  • n.herrmann/cbmroot
  • o.lubynets/cbmroot
  • se.gorbunov/cbmroot
  • cornelius.riesen_AT_physik.uni-giessen.de/cbmroot
  • zhangqn17_AT_mails.tsinghua.edu.cn/cbmroot
  • bartosz.sobol/cbmroot
  • ajit.kumar/cbmroot
  • computing/cbmroot
  • a.agarwal_AT_vecc.gov.in/cbmroot
  • osingh/cbmroot
  • wielanek_AT_if.pw.edu.pl/cbmroot
  • malgorzata.karabowicz.stud_AT_pw.edu.pl/cbmroot
  • m.shiroya/cbmroot
  • s.roy/cbmroot
  • p.-a.loizeau/cbmroot
  • a.weber/cbmroot
  • ma.beyer/cbmroot
  • d.klein/cbmroot
  • d.smith/cbmroot
  • mvdsoft/cbmroot
  • d.spicker/cbmroot
  • y.h.leung/cbmroot
  • aksharma/cbmroot
  • m.deveaux/cbmroot
  • mkunold/cbmroot
  • h.darwish/cbmroot
  • pk.sharma_AT_vecc.gov.in/cbmroot
  • f_fido01_AT_uni-muenster.de/cbmroot
  • g.kozlov/cbmroot
  • d.emschermann/cbmroot
  • evgeny.lavrik/cbmroot
  • v.friese/cbmroot
  • f.uhlig/cbmroot
  • ebechtel_AT_ikf.uni-frankfurt.de/cbmroot
  • a.senger/cbmroot
  • praisig/cbmroot
  • s.lebedev/cbmroot
  • redelbach_AT_compeng.uni-frankfurt.de/cbmroot
  • p.subramani/cbmroot
  • a_meye37_AT_uni-muenster.de/cbmroot
  • om/cbmroot
  • o.golosov/cbmroot
  • l.chlad/cbmroot
  • a.bercuci/cbmroot
  • d.ramirez/cbmroot
  • v.singhal/cbmroot
  • h.schiller/cbmroot
  • apuntke/cbmroot
  • f.zorn/cbmroot
  • rubio_AT_physi.uni-heidelberg.de/cbmroot
  • p.chudoba/cbmroot
  • apuntke/mcbmroot
  • r.karabowicz/cbmroot
66 results
Show changes
Showing
with 677 additions and 50 deletions
......@@ -37,7 +37,7 @@ using namespace std;
CbmTsConsumerReqDevExample::CbmTsConsumerReqDevExample()
// ALGO: : fMonitorAlgo {new CbmMcbm2018MonitorAlgoT0()}
// ALGO: : fMonitorAlgo {new CbmMcbm2018MonitorAlgoBmon()}
{
}
......
......@@ -54,7 +54,7 @@ private:
std::chrono::system_clock::time_point fLastPublishTime = std::chrono::system_clock::now();
/// Processing algo
// ALGO: CbmMcbm2018MonitorAlgoT0* fMonitorAlgo;
// ALGO: CbmMcbm2018MonitorAlgoBmon* fMonitorAlgo;
/// Array of histograms to send to the histogram server
TObjArray fArrayHisto = {};
......
......@@ -23,7 +23,6 @@ set(PRIVATE_DEPS
CbmBase
CbmFlibMcbm2018
FairLogger::FairLogger
FairMQ::Tools
FairRoot::ParBase
ROOT::Hist
external::fles_ipc
......
......@@ -104,7 +104,7 @@ CbmDeviceUnpackTofCri::CbmDeviceUnpackTofCri()
, fdLastDigiTime(0.)
, fdFirstDigiTimeDif(0.)
//, fdEvTime0(0.)
, fhRawTDigEvT0(nullptr)
, fhRawTDigEvBmon(nullptr)
, fhRawTDigRef0(nullptr)
, fhRawTDigRef(nullptr)
, fhRawTRefDig0(nullptr)
......@@ -417,9 +417,9 @@ void CbmDeviceUnpackTofCri::CreateHistograms()
{
LOG(info) << "create Histos for " << fuNrOfGdpbs << " gDPBs ";
fhRawTDigEvT0 =
new TH1F(Form("Raw_TDig-EvT0"), Form("Raw digi time difference to 1st digi ; time [ns]; cts"), 500, 0, 100.);
// fHM->Add( Form("Raw_TDig-EvT0"), fhRawTDigEvT0);
fhRawTDigEvBmon =
new TH1F(Form("Raw_TDig-EvBmon"), Form("Raw digi time difference to 1st digi ; time [ns]; cts"), 500, 0, 100.);
// fHM->Add( Form("Raw_TDig-EvBmon"), fhRawTDigEvBmon);
fhRawTDigRef0 =
new TH1F(Form("Raw_TDig-Ref0"), Form("Raw digi time difference to Ref ; time [ns]; cts"), 6000, -10000, 50000);
......@@ -738,7 +738,7 @@ void CbmDeviceUnpackTofCri::BuildTint(uint64_t ulTsStartTime, int iMode)
if (str == 31)
if (digi->GetTot() > fiPulTotMin && digi->GetTot() < fiPulTotMax) bPul[i][0] = kTRUE;
if (str == 0) bPul[i][1] = kFALSE;
if ((UInt_t) fiReqDigiAddr[i] == fiAddrRef) { //special mapping for MAr2019 diamond (T0)
if ((UInt_t) fiReqDigiAddr[i] == fiAddrRef) { //special mapping for MAr2019 diamond (Bmon)
if (str == 0) bPul[i][0] = kTRUE;
if (str == 40) bPul[i][1] = kTRUE;
}
......
......@@ -125,7 +125,7 @@ private:
Double_t fdLastDigiTime;
Double_t fdFirstDigiTimeDif;
//Double_t fdEvTime0;
TH1* fhRawTDigEvT0;
TH1* fhRawTDigEvBmon;
TH1* fhRawTDigRef0;
TH1* fhRawTDigRef;
TH1* fhRawTRefDig0;
......@@ -190,7 +190,7 @@ private:
/// Control flags
// Bool_t fbMonitorMode; //! Switch ON the filling of a minimal set of histograms
// Bool_t fbDebugMonitorMode; //! Switch ON the filling of a additional set of histograms
// Bool_t fbSeparateArrayT0; //! If ON, T0 digis are saved in separate TClonesArray
// Bool_t fbSeparateArrayBmon; //! If ON, Bmon digis are saved in separate TClonesArray
// Bool_t fbWriteOutput; //! If ON the output TClonesArray of digi is written to disk
CbmDeviceUnpackTofCri(const CbmDeviceUnpackTofCri&) = delete;
......
......@@ -99,7 +99,7 @@ CbmDeviceUnpackTofMcbm2018::CbmDeviceUnpackTofMcbm2018()
, fdLastDigiTime(0.)
, fdFirstDigiTimeDif(0.)
//, fdEvTime0(0.)
, fhRawTDigEvT0(nullptr)
, fhRawTDigEvBmon(nullptr)
, fhRawTDigRef0(nullptr)
, fhRawTDigRef(nullptr)
, fhRawTRefDig0(nullptr)
......@@ -508,7 +508,7 @@ Bool_t CbmDeviceUnpackTofMcbm2018::ReInitContainers()
uFee * fUnpackPar->GetNrOfChannelsPerFee() / 4 + uCh / 4 + 40 * fviRpcSide[iGbtx],
// 0, uFee + 10 * fviRpcSide[iGbtx],
0, fviRpcType[iGbtx]);
LOG(info) << Form("Map T0 Ch %d to Address 0x%08x", iCh, fviRpcChUId[iCh]);
LOG(info) << Form("Map Bmon Ch %d to Address 0x%08x", iCh, fviRpcChUId[iCh]);
}
else
fviRpcChUId[iCh] = 0;
......@@ -713,9 +713,9 @@ void CbmDeviceUnpackTofMcbm2018::CreateHistograms()
{
LOG(info) << "create Histos for " << fuNrOfGdpbs << " gDPBs ";
fhRawTDigEvT0 =
new TH1F(Form("Raw_TDig-EvT0"), Form("Raw digi time difference to 1st digi ; time [ns]; cts"), 500, 0, 100.);
// fHM->Add( Form("Raw_TDig-EvT0"), fhRawTDigEvT0);
fhRawTDigEvBmon =
new TH1F(Form("Raw_TDig-EvBmon"), Form("Raw digi time difference to 1st digi ; time [ns]; cts"), 500, 0, 100.);
// fHM->Add( Form("Raw_TDig-EvBmon"), fhRawTDigEvBmon);
fhRawTDigRef0 =
new TH1F(Form("Raw_TDig-Ref0"), Form("Raw digi time difference to Ref ; time [ns]; cts"), 6000, -10000, 50000);
......@@ -1011,7 +1011,7 @@ void CbmDeviceUnpackTofMcbm2018::BuildTint(int iMode = 0)
if (str == 31)
if (digi->GetTot() > fiPulTotMin && digi->GetTot() < fiPulTotMax) bPul[i][0] = kTRUE;
if (str == 0) bPul[i][1] = kFALSE;
if ((UInt_t) fiReqDigiAddr[i] == fiAddrRef) { //special mapping for MAr2019 diamond (T0)
if ((UInt_t) fiReqDigiAddr[i] == fiAddrRef) { //special mapping for MAr2019 diamond (Bmon)
if (str == 0) bPul[i][0] = kTRUE;
if (str == 40) bPul[i][1] = kTRUE;
}
......
......@@ -125,7 +125,7 @@ private:
Double_t fdLastDigiTime;
Double_t fdFirstDigiTimeDif;
//Double_t fdEvTime0;
TH1* fhRawTDigEvT0;
TH1* fhRawTDigEvBmon;
TH1* fhRawTDigRef0;
TH1* fhRawTDigRef;
TH1* fhRawTRefDig0;
......@@ -190,7 +190,7 @@ private:
/// Control flags
// Bool_t fbMonitorMode; //! Switch ON the filling of a minimal set of histograms
// Bool_t fbDebugMonitorMode; //! Switch ON the filling of a additional set of histograms
// Bool_t fbSeparateArrayT0; //! If ON, T0 digis are saved in separate TClonesArray
// Bool_t fbSeparateArrayBmon; //! If ON, Bmon digis are saved in separate TClonesArray
// Bool_t fbWriteOutput; //! If ON the output TClonesArray of digi is written to disk
CbmDeviceUnpackTofMcbm2018(const CbmDeviceUnpackTofMcbm2018&) = delete;
......
......@@ -76,7 +76,7 @@ CbmDeviceUnpackTofStar2018::CbmDeviceUnpackTofStar2018()
, fdLastDigiTime(0.)
, fdFirstDigiTimeDif(0.)
, fdEvTime0(0.)
, fhRawTDigEvT0(nullptr)
, fhRawTDigEvBmon(nullptr)
, fhRawTDigRef0(nullptr)
, fhRawTDigRef(nullptr)
, fhRawTRefDig0(nullptr)
......@@ -241,9 +241,9 @@ void CbmDeviceUnpackTofStar2018::CreateHistograms()
{
LOG(info) << "create Histos for " << fuNrOfGdpbs << " gDPBs ";
fhRawTDigEvT0 =
new TH1F(Form("Raw_TDig-EvT0"), Form("Raw digi time difference to 1st digi ; time [ns]; cts"), 500, 0, 100.);
// fHM->Add( Form("Raw_TDig-EvT0"), fhRawTDigEvT0);
fhRawTDigEvBmon =
new TH1F(Form("Raw_TDig-EvBmon"), Form("Raw digi time difference to 1st digi ; time [ns]; cts"), 500, 0, 100.);
// fHM->Add( Form("Raw_TDig-EvBmon"), fhRawTDigEvBmon);
fhRawTDigRef0 =
new TH1F(Form("Raw_TDig-Ref0"), Form("Raw digi time difference to Ref ; time [ns]; cts"), 6000, -10000, 50000);
......
......@@ -104,7 +104,7 @@ private:
Double_t fdLastDigiTime;
Double_t fdFirstDigiTimeDif;
Double_t fdEvTime0;
TH1* fhRawTDigEvT0;
TH1* fhRawTDigEvBmon;
TH1* fhRawTDigRef0;
TH1* fhRawTDigRef;
TH1* fhRawTRefDig0;
......
......@@ -24,7 +24,7 @@ void addCustomOptions(bpo::options_description& options)
options.add_options()("PulTotMin", bpo::value<uint64_t>()->default_value(0), "Min pulser TimeOverThreshold");
options.add_options()("PulTotMax", bpo::value<uint64_t>()->default_value(1000), "Max pulser TimeOverThreshold");
options.add_options()("ToffTof", bpo::value<double_t>()->default_value(0.),
"Time offset of Tof digis with respect to T0");
"Time offset of Tof digis with respect to Bmon");
options.add_options()("RefModType", bpo::value<int64_t>()->default_value(5), "Module type of reference counter");
options.add_options()("RefModId", bpo::value<int64_t>()->default_value(0), "Module Id of reference counter");
options.add_options()("RefCtrType", bpo::value<int64_t>()->default_value(4), "Counter type of reference counter");
......
......@@ -24,7 +24,7 @@ void addCustomOptions(bpo::options_description& options)
options.add_options()("PulTotMin", bpo::value<uint64_t>()->default_value(0), "Min pulser TimeOverThreshold");
options.add_options()("PulTotMax", bpo::value<uint64_t>()->default_value(1000), "Max pulser TimeOverThreshold");
options.add_options()("ToffTof", bpo::value<double_t>()->default_value(0.),
"Time offset of Tof digis with respect to T0");
"Time offset of Tof digis with respect to Bmon");
options.add_options()("RefModType", bpo::value<int64_t>()->default_value(5), "Module type of reference counter");
options.add_options()("RefModId", bpo::value<int64_t>()->default_value(0), "Module Id of reference counter");
options.add_options()("RefCtrType", bpo::value<int64_t>()->default_value(4), "Counter type of reference counter");
......
......@@ -46,8 +46,8 @@ with SQLite support will lead to a crash during the CbmRoot compilation
which results in a complete reinstallation of FairSoft and FairRoot after
the package was installed.
There have also been reports about problems with other missing packages.
Mainly these were the Threading Building Blocks (tbb) and the GNU Scientific
Library.
Mainly these were the Threading Building Blocks (tbb), the GNU Scientific
Library and ZSTD, which is used for compressing experimental data since May 2024.
Since these packages may be missing in the instructions from the FairRoot
webpage please install them using the following commands depending on your
OS.
......@@ -57,6 +57,7 @@ Debian/Ubuntu:
sudo apt install sqlite3 libsqlite3-dev
sudo apt install libgsl-dev
sudo apt install libtbb-dev
sudo apt install libzstd-dev
OpenSuse:
......@@ -138,15 +139,15 @@ From your build directory, then call
After your build is complete, before running any part of CbmRoot from a shell,
a large number of environment variables must be set, which contain various
library and include paths. This is done automatically by executing the "config.sh"
or "config.csh" script from your CbmRoot build directory.
or "config.csh" script from your CbmRoot build directory.
Please note, that you must supply the argument "-p" (prepend) or "-a" (append) to
these scripts, depending on whether you wish to add the new entries at the front or
Please note, that you must supply the argument "-p" (prepend) or "-a" (append) to
these scripts, depending on whether you wish to add the new entries at the front or
back of existing environment variables. Failing to do so will cause the variables
to be overwritten, and may render your shell inoperable. This behavior may be desired
in some cases, e.g. on the Virgo cluster.
If you are using a Bash shell, you can add the following line to .bashrc to further
If you are using a Bash shell, you can add the following line to .bashrc to further
automate this step:
source ~/build_cbmroot/config.sh -a > /dev/null 2>&1
......@@ -204,13 +205,20 @@ combinations of FairSoft and FairRoot
# 4. Recommended versions
GCC : >= 7
GCC : `>= 7`
or
Clang: >= 6
Clang: `>= 6`
FairSoft: apr21p2
FairSoft: `apr21p2`
FairRoot: v18.6.7
FairRoot: `v18.6.7`
Clang-format: `v11.0`
Boost archives being only ensured to be `backward compatible` (and therefore not necessarily
`forward compatible`), care must be taken when writing data and/or parameter files with it
that the versions used when writing and when using/reading are compatible. \
More information in the [following document](docs/boost_serialization_version.md).
# 5. Further remarks
......@@ -218,3 +226,8 @@ Compiling CbmRoot with multicore support using "make -j", without
specifying the number of threads, is known to cause MacOS and Ubuntu
20.04 LTS systems to freeze. Please explicitly choose a number of cores
which is suitable for your system.
# 6. CI and Code formatting
For information about our Merge-Request CI chain, including code formatting, please refere to this
[description page](docs/CiDescription.md)
cmake_minimum_required(VERSION 3.14.0 FATAL_ERROR)
cmake_policy(VERSION 3.14...3.23)
if (NOT DEFINED CBM_ONLINE_STANDALONE)
if (CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR)
set(CBM_ONLINE_STANDALONE ON)
project(CbmOnline)
else()
set(CBM_ONLINE_STANDALONE OFF)
endif()
endif()
if (CBM_ONLINE_STANDALONE)
message(STATUS "Building online standalone")
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_EXTENSIONS OFF)
Set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/lib")
Set(EXECUTABLE_OUTPUT_PATH "${CMAKE_BINARY_DIR}/bin")
Set(INCLUDE_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/include")
set(CMAKE_INSTALL_LIBDIR lib)
# Set default build type
if (NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE "RelWithDebInfo" CACHE STRING "Build type" FORCE)
endif()
#Fairsoft Modules Path, SIMPATH must always be set
if (NOT DEFINED SIMPATH)
message(FATAL_ERROR "SIMPATH not set")
endif()
list(PREPEND CMAKE_PREFIX_PATH ${SIMPATH})
find_package(OpenMP REQUIRED)
find_package(Boost REQUIRED COMPONENTS serialization regex filesystem log log_setup container program_options thread iostreams)
find_package(ROOT CONFIG REQUIRED GenVector)
find_package(Vc 1.4.1 CONFIG REQUIRED)
find_package(fmt CONFIG REQUIRED)
include(ExternalProject)
# cmake is symlinked to ../cmake by the install script in the container
# We use the symlink because some cmake macros use relative path from the project root
# to locate files (e.g. Gen_Exe_Script).
# Thus we need the same path if the project root changes.
set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake")
list(PREPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/modules")
include(CbmMacros) # for 'download_project_if_needed', 'Gen_Exe_Script' macro
add_subdirectory(../external external)
endif()
add_subdirectory(kfp)
add_subdirectory(log)
add_subdirectory(data)
add_subdirectory(test)
add_subdirectory(kf)
add_subdirectory(ca)
add_subdirectory(base)
#add_subdirectory(kfp) # For KFParticleOnline
# exclude unittests from being build inside the container
if (NOT CBM_ONLINE_STANDALONE)
add_subdirectory(test)
endif()
# FIXME!!!!
# After the merge-request !2086 CBmRunDatabase should be moved somewhere else. The
# file requers a proper Yaml-interface, which is still unavailable before the !2086.
#
set(FIXME_I_AM_TMP_CBM_RUN_SRC ${CMAKE_CURRENT_SOURCE_DIR}/../core/run)
set(DEVICE_SRCS
base/gpu/DeviceImage.cxx
base/gpu/Params.cxx
detectors/sts/Hitfinder.cxx
)
# Create a library libCbmAlgo
set(SRCS
${DEVICE_SRCS}
${FIXME_I_AM_TMP_CBM_RUN_SRC}/CbmRunDatabase.cxx
base/ChainContext.cxx
base/DigiData.cxx
base/Options.cxx
base/MainConfig.cxx
base/RecoParams.cxx
base/System.cxx
base/compat/Algorithm.cxx
base/util/MemoryLogger.cxx
base/util/StlUtils.cxx
base/util/EnumDict.cxx
base/util/TimingsFormat.cxx
data/sts/HitfinderPars.cxx
data/sts/LandauTable.cxx
evbuild/Config.cxx
evbuild/EventBuilder.cxx
evbuild/EventBuilderConfig.cxx
evbuild/EventbuildChain.cxx
trigger/DigiTriggerConfig.cxx
trigger/HitMultTrigger.cxx
trigger/TimeClusterTrigger.cxx
detectors/sts/StsReadoutConfig.cxx
detectors/sts/UnpackSts.cxx
detectors/much/MuchReadoutConfig.cxx
detectors/much/UnpackMuch.cxx
trigger/V0Trigger.cxx
trigger/V0TriggerConfig.cxx
evselector/DigiEventSelector.cxx
evselector/DigiEventSelectorConfig.cxx
unpack/CommonUnpacker.cxx
detectors/bmon/Calibrate.cxx
detectors/bmon/Clusterizer.cxx
detectors/bmon/Hitfind.cxx
detectors/bmon/ReadoutConfig.cxx
detectors/bmon/Unpack.cxx
detectors/bmon/UnpackMS.cxx
detectors/sts/ChannelMaskSet.cxx
detectors/sts/ReadoutConfig.cxx
detectors/sts/HitfinderChain.cxx
detectors/sts/TrackingInterface.cxx
detectors/sts/Unpack.cxx
detectors/sts/UnpackMS.cxx
detectors/sts/WalkMap.cxx
detectors/much/ReadoutConfig.cxx
detectors/much/Unpack.cxx
detectors/much/UnpackMS.cxx
detectors/tof/HitFinder.cxx
detectors/tof/Calibrate.cxx
detectors/tof/Clusterizer.cxx
detectors/tof/ReadoutConfig.cxx
detectors/tof/Unpack.cxx
detectors/tof/UnpackMS.cxx
detectors/tof/Hitfind.cxx
detectors/tof/TrackingInterface.cxx
detectors/trd/Cluster.cxx
detectors/trd/Clusterizer.cxx
detectors/trd/Cluster2D.cxx
detectors/trd/Clusterizer2D.cxx
detectors/trd/DigiRec.cxx
detectors/trd/Hit.cxx
detectors/trd/Hitfind.cxx
detectors/trd/HitFactory2D.cxx
detectors/trd/HitFinder.cxx
detectors/trd/HitFinder2D.cxx
detectors/trd/HitMerger.cxx
detectors/trd/HitMerger2D.cxx
detectors/trd/ReadoutConfig.cxx
detectors/trd/TrackingInterface.cxx
detectors/trd/Unpack.cxx
detectors/trd/UnpackMS.cxx
detectors/trd2d/ReadoutConfig.cxx
detectors/trd2d/Unpack.cxx
detectors/trd2d/UnpackMS.cxx
detectors/rich/ReadoutConfig.cxx
detectors/rich/Unpack.cxx
detectors/rich/UnpackMS.cxx
global/ParFiles.cxx
global/StorableRecoResults.cxx
global/Reco.cxx
global/RecoResultsInputArchive.cxx
global/RecoResultsOutputArchive.cxx
qa/DigiEventQa.cxx
qa/Histo1D.cxx
qa/HistogramContainer.cxx
qa/CanvasConfig.cxx
qa/PadConfig.cxx
qa/QaData.cxx
qa/RecoGeneralQa.cxx
qa/QaManager.cxx
qa/hitfind/BmonHitfindQa.cxx
qa/hitfind/BmonHitfindQaParameters.cxx
qa/trigger/V0TriggerQa.cxx
qa/hitfind/TofHitfindQa.cxx
qa/hitfind/TofHitfindQaParameters.cxx
qa/unpack/StsDigiQa.cxx
ca/TrackingSetup.cxx
ca/TrackingChain.cxx
ca/qa/CaQa.cxx
kfp/KfpV0Finder.cxx
kfp/KfpV0FinderChain.cxx
kfp/KfpV0FinderConfig.cxx
kfp/KfpV0FinderQa.cxx
)
set(BUILD_INFO_CXX ${CMAKE_CURRENT_BINARY_DIR}/base/BuildInfo.cxx)
set(SRCS ${SRCS} ${BUILD_INFO_CXX})
add_custom_target(generateBuildInfo
COMMAND ${CMAKE_COMMAND}
-DBUILD_TYPE=${CMAKE_BUILD_TYPE}
-DXPU_DEBUG=${XPU_DEBUG}
-DINFILE=${CMAKE_CURRENT_SOURCE_DIR}/base/BuildInfo.cxx.in
-DOUTFILE=${BUILD_INFO_CXX}
-P ${CMAKE_SOURCE_DIR}/cmake/modules/GenerateBuildInfo.cmake
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/base/BuildInfo.cxx.in
${CMAKE_SOURCE_DIR}/cmake/modules/GenerateBuildInfo.cmake
BYPRODUCTS ${BUILD_INFO_CXX}
COMMENT "Generating build info"
)
add_library(Algo SHARED ${SRCS})
target_include_directories(Algo
PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}
PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/data
${CMAKE_CURRENT_SOURCE_DIR}/base
${CMAKE_CURRENT_SOURCE_DIR}/evbuild
${CMAKE_CURRENT_SOURCE_DIR}/global
${CMAKE_CURRENT_SOURCE_DIR}/trigger
${CMAKE_CURRENT_SOURCE_DIR}/detectors/sts
${CMAKE_CURRENT_SOURCE_DIR}/detectors/much
)
${CMAKE_CURRENT_SOURCE_DIR}/evselector
${CMAKE_CURRENT_SOURCE_DIR}/unpack
${CMAKE_CURRENT_SOURCE_DIR}/detectors
${CMAKE_CURRENT_SOURCE_DIR}/qa
${CMAKE_CURRENT_SOURCE_DIR}/qa/unpack
${CMAKE_CURRENT_SOURCE_DIR}/qa/hitfind
${CMAKE_CURRENT_SOURCE_DIR}/qa/trigger
${CMAKE_CURRENT_SOURCE_DIR}/kf
${CMAKE_CURRENT_SOURCE_DIR}/kf/core
${CMAKE_CURRENT_SOURCE_DIR}/kf/core/utils
${CMAKE_CURRENT_SOURCE_DIR}/kfp
${CMAKE_CURRENT_SOURCE_DIR}/ca
${CMAKE_CURRENT_SOURCE_DIR}/ca/qa
${CMAKE_CURRENT_SOURCE_DIR}/ca/core/data
${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_SOURCE_DIR}/core/data/global
${FIXME_I_AM_TMP_CBM_RUN_SRC}
)
target_link_libraries(Algo PUBLIC OnlineData INTERFACE FairLogger::FairLogger external::fles_ipc)
target_link_libraries(Algo
PUBLIC OnlineData
KfCore
CaCore
ROOT::GenVector
GSL
fmt::fmt
Boost::program_options
Boost::filesystem
Boost::iostreams
Boost::headers
xpu
external::yaml-cpp
external::fles_logging
external::fles_ipc
external::fles_monitoring
cppzmq
poolstl
PRIVATE CbmKFParticleOnlineInterface
INTERFACE CbmYamlInterface
)
target_compile_definitions(Algo PUBLIC NO_ROOT)
xpu_attach(Algo ${DEVICE_SRCS})
# Link against OpenMP if available
if (OpenMP_CXX_FOUND)
target_link_libraries(Algo PUBLIC OpenMP::OpenMP_CXX)
endif()
# Try to enable parallel execution in c++17 if TBB is available
if (CMAKE_SYSTEM_NAME STREQUAL "Linux")
list(APPEND CMAKE_PREFIX_PATH "/opt/intel/oneapi/tbb/latest/")
find_package(TBB)
if (TBB_FOUND)
message(STATUS "Found TBB")
target_compile_definitions(Algo PUBLIC -DHAVE_TBB)
target_link_libraries(Algo PUBLIC TBB::tbb)
else()
message(STATUS "TBB not found")
endif()
endif()
if (CBM_ONLINE_STANDALONE)
# Add online binary
add_subdirectory(../reco/app/cbmreco cbmreco)
endif()
##### Offline version without the NO_ROOT in order to get standard logger! #############################################
if (NOT CBM_ONLINE_STANDALONE)
add_library(AlgoOffline SHARED ${SRCS})
target_include_directories(AlgoOffline
PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/data
${CMAKE_CURRENT_SOURCE_DIR}/base
${CMAKE_CURRENT_SOURCE_DIR}/evbuild
${CMAKE_CURRENT_SOURCE_DIR}/global
${CMAKE_CURRENT_SOURCE_DIR}/trigger
${CMAKE_CURRENT_SOURCE_DIR}/evselector
${CMAKE_CURRENT_SOURCE_DIR}/unpack
${CMAKE_CURRENT_SOURCE_DIR}/detectors
${CMAKE_CURRENT_SOURCE_DIR}/qa
${CMAKE_CURRENT_SOURCE_DIR}/qa/unpack
${CMAKE_CURRENT_SOURCE_DIR}/qa/hitfind
${CMAKE_CURRENT_SOURCE_DIR}/qa/trigger
${CMAKE_CURRENT_SOURCE_DIR}/kf
${CMAKE_CURRENT_SOURCE_DIR}/kf/core
${CMAKE_CURRENT_SOURCE_DIR}/kf/core/utils
${CMAKE_CURRENT_SOURCE_DIR}/kfp
${CMAKE_CURRENT_SOURCE_DIR}/ca
${CMAKE_CURRENT_SOURCE_DIR}/ca/qa
${CMAKE_CURRENT_SOURCE_DIR}/ca/core/data
${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_SOURCE_DIR}/core/data/global
${FIXME_I_AM_TMP_CBM_RUN_SRC}
)
target_link_libraries(AlgoOffline
PUBLIC CbmData
KfCoreOffline
CaCoreOffline
ROOT::GenVector
GSL
fmt::fmt
Boost::program_options
Boost::filesystem
Boost::iostreams
Boost::headers
FairLogger::FairLogger
xpu
external::yaml-cpp
external::fles_ipc
external::fles_monitoring
cppzmq
poolstl
PRIVATE CbmKFParticleOnlineInterface
INTERFACE CbmYamlInterface
)
xpu_attach(AlgoOffline ${DEVICE_SRCS})
# Link against OpenMP if available
if (OpenMP_CXX_FOUND)
target_link_libraries(AlgoOffline PUBLIC OpenMP::OpenMP_CXX)
endif()
# Try to enable parallel execution in c++17 if TBB is available
if (CMAKE_SYSTEM_NAME STREQUAL "Linux")
list(APPEND CMAKE_PREFIX_PATH "/opt/intel/oneapi/tbb/latest/")
find_package(TBB)
if (TBB_FOUND)
message(STATUS "AlgoOffline: Found TBB")
target_compile_definitions(AlgoOffline PUBLIC -DHAVE_TBB)
target_link_libraries(AlgoOffline PUBLIC TBB::tbb)
else()
message(STATUS "Algo Offline: TBB not found")
endif()
endif()
install(TARGETS AlgoOffline DESTINATION lib)
endif()
########################################################################################################################
install(TARGETS Algo DESTINATION lib)
install(DIRECTORY base/compat TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
#install(DIRECTORY base/yaml TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY base/util TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY base/gpu TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY data/sts TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY detectors/bmon TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY detectors/much TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY detectors/sts TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY detectors/tof TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY detectors/trd TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY detectors/trd2d TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY detectors/rich TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY ca/qa TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY qa TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY qa/unpack TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY ca TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY kfp TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(DIRECTORY evbuild TYPE INCLUDE FILES_MATCHING PATTERN "*.h")
install(FILES ca/simd/CaSimd.h
ca/simd/CaSimdVc.h
ca/simd/CaSimdPseudo.h
DESTINATION include/
install(
FILES
${FIXME_I_AM_TMP_CBM_RUN_SRC}/CbmRunDatabase.h
base/ChainContext.h
base/Definitions.h
base/HistogramSender.h
base/Options.h
base/RecoParams.h
base/SubChain.h
base/System.h
base/PartitionedVector.h
base/PartitionedSpan.h
base/DigiData.h
base/PODVector.h
base/AlgoTraits.h
base/AuxDigiData.h
base/BuildInfo.h
base/Exceptions.h
base/MainConfig.h
evselector/DigiEventSelector.h
evselector/DigiEventSelectorConfig.h
trigger/DigiTriggerConfig.h
trigger/HitMultTrigger.h
trigger/TimeClusterTrigger.h
trigger/V0Trigger.h
trigger/V0TriggerConfig.h
unpack/CommonUnpacker.h
unpack/UnpackMSBase.h
global/ParFiles.h
global/Reco.h
global/RecoResults.h
global/RecoResultsInputArchive.h
global/RecoResultsOutputArchive.h
global/StorableRecoResults.h
qa/Accumulators.h
qa/Histogram.h
ca/TrackingChain.h
ca/TrackingChainConfig.h
ca/TrackingDefs.h
ca/TrackingSetup.h
# NOTE: SZh 20.11.2023:
# The ca/qa directory depends on the online qa classes, so for now it has to be a part of the Algo library.
ca/qa/CaQa.h
DESTINATION
include/
)
/* Copyright (C) 2024 FIAS Frankfurt Institute for Advanced Studies, Frankfurt / Main
SPDX-License-Identifier: GPL-3.0-only
Authors: Felix Weiglhofer [committer] */
#pragma once
#include <tuple>
#include <type_traits>
/**
* @file AlgoTraits.h
* @brief Type traits for online algorithms
*/
namespace cbm::algo::algo_traits
{
namespace detail
{
template<typename...>
struct ResultOf {
};
template<typename R, typename Algo, typename... Args>
struct ResultOf<R (Algo::*)(Args...) const> {
using type = R;
};
template<typename R, typename Algo, typename... Args>
struct ResultOf<R (Algo::*)(Args...)> {
using type = R;
};
template<typename Algo>
struct ResultOf<Algo> : ResultOf<decltype(&Algo::operator())> {
};
} // namespace detail
/**
* @brief Type alias for the return type produced by an algorithm when invoked via callable-operator
*/
template<typename Algo>
using ResultOf_t = typename detail::ResultOf<Algo>::type;
// Currently assume algorithms return std::tuple<R, M, A>
// where R is the output, M is the monitoring data and A is auxiliary data
/**
* @brief Type alias for the output type produced by an algorithm
*/
template<typename Algo>
using Output_t = typename std::tuple_element<0, ResultOf_t<Algo>>::type;
/**
* @brief Type alias for the monitoring type produced by an algorithm
*/
template<typename Algo>
using Monitor_t = typename std::tuple_element<1, ResultOf_t<Algo>>::type;
/**
* @brief Type alias for the auxiliary data type produced by an algorithm
*/
template<typename Algo>
using Aux_t = typename std::tuple_element<2, ResultOf_t<Algo>>::type;
} // namespace cbm::algo::algo_traits
/* Copyright (C) 2024 GSI Helmholtzzentrum fuer Schwerionenforschung, Darmstadt
SPDX-License-Identifier: GPL-3.0-only
Authors: Sergei Zharko [committer] */
/// \file AuxDigiData.h
/// \date 10.06.2024
/// \brief Collection of auxiliary data from unpackers (header)
/// \author Sergei Zharko <s.zharko@gsi.de>
#pragma once
#include "CommonUnpacker.h"
#include "bmon/UnpackMS.h"
#include "much/UnpackMS.h"
#include "rich/UnpackMS.h"
#include "sts/UnpackMS.h"
#include "tof/UnpackMS.h"
#include "trd/UnpackMS.h"
#include "trd2d/UnpackMS.h"
#include <vector>
namespace cbm::algo
{
/// \struct AuxDigiData
/// \brief Collection of auxiliary digi objects from different module unpackers
struct AuxDigiData {
UnpackAux<bmon::UnpackAuxData> fBmon;
UnpackAux<much::UnpackAuxData> fMuch;
UnpackAux<rich::UnpackAuxData> fRich;
UnpackAux<sts::UnpackAuxData> fSts;
UnpackAux<tof::UnpackAuxData> fTof;
UnpackAux<trd::UnpackAuxData> fTrd;
UnpackAux<trd2d::UnpackAuxData> fTrd2d;
};
} // namespace cbm::algo
/* Copyright (C) 2022 FIAS Frankfurt Institute for Advanced Studies, Frankfurt / Main
SPDX-License-Identifier: GPL-3.0-only
Authors: Felix Weiglhofer [committer]*/
#include "BuildInfo.h"
// GENERATED BY CMAKE.
// DON'T CHANGE BY HAND. MODIFY .in-File INSTEAD.
namespace cbm::algo::BuildInfo {
const std::string GIT_HASH = "@GIT_HASH@";
const std::string BUILD_TYPE = "@BUILD_TYPE@";
const bool GPU_DEBUG = @GPU_DEBUG@;
} // namespace cbm::algo::BuildInfo
/* Copyright (C) 2022 FIAS Frankfurt Institute for Advanced Studies, Frankfurt / Main
SPDX-License-Identifier: GPL-3.0-only
Authors: Felix Weiglhofer [committer]*/
#ifndef CBM_ALGO_BUILD_INFO_H
#define CBM_ALGO_BUILD_INFO_H
#include <string>
#define MAKE_GCC_VERSION(major, minor, patch) ((major) *10000 + (minor) *100 + (patch))
#define GCC_VERSION MAKE_GCC_VERSION(__GNUC__, __GNUC_MINOR__, __GNUC_PATCHLEVEL__)
#if __has_include(<execution>) && !defined(__CLING__)
#include <execution> // for feature test macro __cpp_lib_parallel_algorithm
#endif
#if defined(HAVE_TBB) && defined(__cpp_lib_parallel_algorithm)
#define HAVE_PARALLEL_STL_LIBTBB
#endif
// PoolSTL triggers an internal error in GCC 10, so only enable it for GCC 11 and later
#if GCC_VERSION >= MAKE_GCC_VERSION(11, 0, 0)
#define HAVE_PARALLEL_STL_POOLSTL
#endif
#if __has_include(<omp.h>)
#define HAVE_OMP
#endif
// Ensure we have the boost compression header AND flesnet is compiled with compression enabled
#if __has_include(<boost/iostreams/filter/zstd.hpp>) && defined(BOOST_IOS_HAS_ZSTD)
#define HAVE_ZSTD
#endif
namespace cbm::algo::BuildInfo
{
extern const std::string GIT_HASH;
extern const std::string BUILD_TYPE;
extern const bool GPU_DEBUG;
inline constexpr bool WITH_TBB =
#ifdef HAVE_TBB
true;
#else
false;
#endif
inline constexpr bool WITH_PARALLEL_STL =
#ifdef HAVE_PARALLEL_STL_LIBTBB
true;
#else
false;
#endif
inline constexpr bool WITH_OMP =
#ifdef HAVE_OMP
true;
#else
false;
#endif
inline constexpr bool WITH_ZSTD =
#ifdef HAVE_ZSTD
true;
#else
false;
#endif
} // namespace cbm::algo::BuildInfo
#endif // CBM_ALGO_BUILD_INFO_H
add_subdirectory(yaml)
/* Copyright (C) 2023 FIAS Frankfurt Institute for Advanced Studies, Frankfurt / Main
SPDX-License-Identifier: GPL-3.0-only
Authors: Felix Weiglhofer [committer] */
#include "ChainContext.h"
#include <Monitor.hpp>
using namespace cbm::algo;
ChainContext::ChainContext() {}
ChainContext::~ChainContext() {}
/* Copyright (C) 2023 FIAS Frankfurt Institute for Advanced Studies, Frankfurt / Main
SPDX-License-Identifier: GPL-3.0-only
Authors: Felix Weiglhofer [committer] */
#ifndef CBM_ALGO_BASE_CHAINCONTEXT_H
#define CBM_ALGO_BASE_CHAINCONTEXT_H
#include "Options.h"
#include "RecoParams.h"
#include <memory>
#include <optional>
namespace cbm
{
// cbm::Monitor must be forward declared. This prevents an issue in older ROOT versions,
// where cling would crash upon parsing the header file (in some stl header)
class Monitor;
} // namespace cbm
namespace cbm::algo
{
struct ChainContext {
// default constructor / destructor
// But have to be defined in the .cxx file, because of forward declaration of cbm::Monitor
ChainContext();
~ChainContext();
Options opts;
RecoParams recoParams;
std::unique_ptr<cbm::Monitor> monitor; //! Monitor
};
} // namespace cbm::algo
#endif