R3BROOT
R3B analysis software
Loading...
Searching...
No Matches
R3BNeulandCalToHitParTask.h
Go to the documentation of this file.
1/******************************************************************************
2 * Copyright (C) 2019 GSI Helmholtzzentrum für Schwerionenforschung GmbH *
3 * Copyright (C) 2019-2023 Members of R3B Collaboration *
4 * *
5 * This software is distributed under the terms of the *
6 * GNU General Public Licence (GPL) version 3, *
7 * copied verbatim in the file "LICENSE". *
8 * *
9 * In applying this license GSI does not waive the privileges and immunities *
10 * granted to it by virtue of its status as an Intergovernmental Organization *
11 * or submit itself to any jurisdiction. *
12 ******************************************************************************/
13
14#pragma once
15
16#include "R3BDataMonitor.h"
18#include <FairRootManager.h>
19#include <FairRuntimeDb.h>
20#include <R3BIOConnector.h>
21#include <R3BNeulandBasePar.h>
22#include <R3BNeulandCalData2.h>
25#include <cstdint>
26#include <memory>
27#include <string_view>
28
29namespace R3B::Neuland
30{
31 enum class Cal2HitParMethod : uint8_t
32 {
36 };
37
39 {
40 public:
42 std::string_view cal_data_name = "NeulandCalData",
43 std::string_view base_par_name = "NeulandCalibrationBasePar",
44 std::string_view hit_par_name = "NeulandHitPar",
45 std::string_view name = "NeulandCal2HitParTask",
46 int iVerbose = 1);
47 void SetMinStat(int min) { engine_->SetMinStat(min); }
48 void SetErrorScale(float scale) { engine_->SetErrorScale(scale); }
49 auto GetCal2HitPar() -> auto* { return hit_par_; }
50
51 private:
53
54 CalibrationBasePar* base_par_ = nullptr; // input par
55 Cal2HitPar* hit_par_ = nullptr; // output par
56
57 std::unique_ptr<Calibration::CosmicEngineInterface> engine_;
58
59 // overriden functions:
60 void HistogramInit(DataMonitor& histograms) override;
61 void ExtraInit(FairRootManager* rootMan) override;
62 void SetExtraPar(FairRuntimeDb* rtdb) override;
63 void TriggeredExec() override;
64 void EndOfTask() override;
65 [[nodiscard]] auto CheckConditions() const -> bool override;
66
67 // private non virtual functions:
68 };
69
70} // namespace R3B::Neuland
InputVectorConnector< BarCalData > cal_data_
void ExtraInit(FairRootManager *rootMan) override
std::unique_ptr< Calibration::CosmicEngineInterface > engine_
void SetExtraPar(FairRuntimeDb *rtdb) override
void HistogramInit(DataMonitor &histograms) override
auto CheckConditions() const -> bool override
Cal2HitParTask(Cal2HitParMethod method=Cal2HitParMethod::LSQT, std::string_view cal_data_name="NeulandCalData", std::string_view base_par_name="NeulandCalibrationBasePar", std::string_view hit_par_name="NeulandHitPar", std::string_view name="NeulandCal2HitParTask", int iVerbose=1)
Simulation of NeuLAND Bar/Paddle.
InputConnector< std::vector< ElementType > > InputVectorConnector