Skip to content
Snippets Groups Projects
Commit 1680d075 authored by Pierre-Alain Loizeau's avatar Pierre-Alain Loizeau
Browse files

Use the TZD unpacker instead of BMon one in Reco steering class

parent a76f2c44
No related branches found
No related tags found
1 merge request!1019Support for CbmTzdDigi in unpacking, event builder and TOF reco.
......@@ -29,6 +29,7 @@ set(PRIVATE_DEPENDENCIES
CbmRichReco
CbmRecoSts
CbmTrdReco
CbmTzdReco
)
set(INTERFACE_DEPENDENCIES
......
......@@ -49,7 +49,7 @@ void CbmRecoUnpack::Finish()
if (fTofConfig) fTofConfig->GetUnpacker()->Finish();
if (fTrd1DConfig) fTrd1DConfig->GetUnpacker()->Finish();
if (fTrd2DConfig) fTrd2DConfig->GetUnpacker()->Finish();
if (fBmonConfig) fBmonConfig->GetUnpacker()->Finish();
if (fTzdConfig) fTzdConfig->GetUnpacker()->Finish();
// Create some default performance profiling histograms and write them to a file
if (fDoPerfProf) performanceProfiling();
......@@ -152,14 +152,14 @@ Bool_t CbmRecoUnpack::Init()
// for fasp created CbmTrdDigis PR 072021
// --- Bmon
if (fBmonConfig) {
fBmonConfig->InitOutput();
RegisterOutputs(ioman, fBmonConfig); /// Framework bound work = kept in this Task
fBmonConfig->SetAlgo();
fBmonConfig->LoadParFileName(); /// Needed to change the Parameter file name before it is used!!!
initParContainers(fBmonConfig->GetParContainerRequest()); /// Framework bound work = kept in this Task
fBmonConfig->InitAlgo();
initPerformanceMaps(fkFlesBmon, "Bmon");
if (fTzdConfig) {
fTzdConfig->InitOutput();
RegisterOutputs(ioman, fTzdConfig); /// Framework bound work = kept in this Task
fTzdConfig->SetAlgo();
fTzdConfig->LoadParFileName(); /// Needed to change the Parameter file name before it is used!!!
initParContainers(fTzdConfig->GetParContainerRequest()); /// Framework bound work = kept in this Task
fTzdConfig->InitAlgo();
initPerformanceMaps(fkFlesTzd, "Tzd");
}
if (fDoPerfProfPerTs) {
......@@ -379,8 +379,8 @@ void CbmRecoUnpack::Reset()
if (fTrd1DConfig) fTrd1DConfig->Reset();
// ---- Trd2D ----
if (fTrd2DConfig) fTrd2DConfig->Reset();
// ---- Bmon ----
if (fBmonConfig) fBmonConfig->Reset();
// ---- Tzd ----
if (fTzdConfig) fTzdConfig->Reset();
}
// ----------------------------------------------------------------------------
......@@ -458,14 +458,10 @@ void CbmRecoUnpack::Unpack(unique_ptr<Timeslice> ts)
}
break;
}
case fkFlesBmon: {
if (fBmonConfig) {
fCbmTsEventHeader->AddNDigisBmon(unpack(systemId, &timeslice, component, fBmonConfig,
fBmonConfig->GetOptOutAVec(), fBmonConfig->GetOptOutBVec()));
}
else if (fTofConfig) {
fCbmTsEventHeader->AddNDigisTof(unpack(fkFlesTof, &timeslice, component, fTofConfig,
fTofConfig->GetOptOutAVec(), fTofConfig->GetOptOutBVec()));
case fkFlesTzd: {
if (fTzdConfig) {
fCbmTsEventHeader->AddNDigisBmon(unpack(systemId, &timeslice, component, fTzdConfig,
fTzdConfig->GetOptOutAVec(), fTzdConfig->GetOptOutBVec()));
}
break;
}
......@@ -485,7 +481,7 @@ void CbmRecoUnpack::Unpack(unique_ptr<Timeslice> ts)
if (fTofConfig && fTofConfig->GetOutputVec()) { timesort(fTofConfig->GetOutputVec()); }
if (fTrd1DConfig && fTrd1DConfig->GetOutputVec()) { timesort(fTrd1DConfig->GetOutputVec()); }
if (fTrd2DConfig && fTrd2DConfig->GetOutputVec()) { timesort(fTrd2DConfig->GetOutputVec()); }
if (fBmonConfig && fBmonConfig->GetOutputVec()) { timesort(fBmonConfig->GetOutputVec()); }
if (fTzdConfig && fTzdConfig->GetOutputVec()) { timesort(fTzdConfig->GetOutputVec()); }
/// Time sort the output vectors of all unpackers present
if (fMuchConfig && fMuchConfig->GetOptOutAVec()) { timesort(fMuchConfig->GetOptOutAVec()); }
......@@ -495,7 +491,7 @@ void CbmRecoUnpack::Unpack(unique_ptr<Timeslice> ts)
if (fTofConfig && fTofConfig->GetOptOutAVec()) { timesort(fTofConfig->GetOptOutAVec()); }
if (fTrd1DConfig && fTrd1DConfig->GetOptOutAVec()) { timesort(fTrd1DConfig->GetOptOutAVec()); }
if (fTrd2DConfig && fTrd2DConfig->GetOptOutAVec()) { timesort(fTrd2DConfig->GetOptOutAVec()); }
if (fBmonConfig && fBmonConfig->GetOptOutAVec()) { timesort(fBmonConfig->GetOptOutAVec()); }
if (fTzdConfig && fTzdConfig->GetOptOutAVec()) { timesort(fTzdConfig->GetOptOutAVec()); }
}
if (fDoPerfProfPerTs) {
......
......@@ -12,7 +12,6 @@
#ifndef CBMRECOUNPACK_H
#define CBMRECOUNPACK_H 1
#include "CbmBmonUnpackConfig.h"
#include "CbmMuchUnpackConfig.h"
#include "CbmPsdUnpackConfig.h"
#include "CbmRichUnpackConfig.h"
......@@ -21,6 +20,7 @@
#include "CbmTrdUnpackConfig.h"
#include "CbmTrdUnpackFaspConfig.h"
#include "CbmTsEventHeader.h"
#include "CbmTzdUnpackConfig.h"
#include <MicrosliceDescriptor.hpp>
#include <Timeslice.hpp>
......@@ -31,13 +31,13 @@
#include <RtypesCore.h>
#include <THnSparse.h>
#include <TObject.h>
#include <type_traits> // this is std::lib used for template is_member_function_pointer
#include <chrono>
#include <cstddef>
#include <cstdint>
#include <ctime>
#include <memory>
#include <type_traits> // this is std::lib used for template is_member_function_pointer
#include <utility>
#include <vector>
......@@ -149,7 +149,7 @@ public:
void SetUnpackConfig(std::shared_ptr<CbmTrdUnpackFaspConfig> config) { fTrd2DConfig = config; }
/** @brief Set the Bmon Unpack Config @param config */
void SetUnpackConfig(std::shared_ptr<CbmBmonUnpackConfig> config) { fBmonConfig = config; }
void SetUnpackConfig(std::shared_ptr<CbmTzdUnpackConfig> config) { fTzdConfig = config; }
/** @brief Trigger the unpacking procedure **/
void Unpack(std::unique_ptr<fles::Timeslice> ts);
......@@ -163,7 +163,7 @@ private:
static constexpr std::uint16_t fkFlesTrd = static_cast<std::uint16_t>(fles::SubsystemIdentifier::TRD);
static constexpr std::uint16_t fkFlesTrd2D = static_cast<std::uint16_t>(fles::SubsystemIdentifier::TRD2D);
static constexpr std::uint16_t fkFlesTof = static_cast<std::uint16_t>(fles::SubsystemIdentifier::RPC);
static constexpr std::uint16_t fkFlesBmon = static_cast<std::uint16_t>(fles::SubsystemIdentifier::T0);
static constexpr std::uint16_t fkFlesTzd = static_cast<std::uint16_t>(fles::SubsystemIdentifier::T0);
/** @brief Flag if extended debug output is to be printed or not*/
bool fDoDebugPrints = false; //!
......@@ -424,8 +424,8 @@ private:
/** @brief Configuration of the Trd unpacker. Provides the configured algorithm */
std::shared_ptr<CbmTrdUnpackFaspConfig> fTrd2DConfig = nullptr; //!
/** @brief Configuration of the Bmon unpacker. Provides the configured algorithm */
std::shared_ptr<CbmBmonUnpackConfig> fBmonConfig = nullptr; //!
/** @brief Configuration of the Tzd unpacker. Provides the configured algorithm */
std::shared_ptr<CbmTzdUnpackConfig> fTzdConfig = nullptr; //!
/** @brief Pointer to the Timeslice start time used to write it to the output tree @remark since we hand this to the FairRootManager it also wants to delete it and we do not have to take care of deletion */
CbmTsEventHeader* fCbmTsEventHeader = nullptr;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment