-
Notifications
You must be signed in to change notification settings - Fork 508
Expand file tree
/
Copy pathCorrectionMapsLoader.h
More file actions
70 lines (57 loc) · 2.74 KB
/
Copy pathCorrectionMapsLoader.h
File metadata and controls
70 lines (57 loc) · 2.74 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
// All rights not expressly granted are reserved.
//
// This software is distributed under the terms of the GNU General Public
// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
//
// In applying this license CERN does not waive the privileges and immunities
// granted to it by virtue of its status as an Intergovernmental Organization
// or submit itself to any jurisdiction.
/// \file CorrectionMapsLoader.h
/// \brief Helper class to access load maps from CCDB
/// \author matthias.kleiner@cern.ch
#ifndef TPC_CORRECTION_MAPS_LOADER_H_
#define TPC_CORRECTION_MAPS_LOADER_H_
#include <vector>
#include "CorrectionMapsHelper.h"
#include "CorrectionMapsTypes.h"
#include "TPCCalibration/SectorEdgeFluctuations.h"
namespace o2
{
namespace framework
{
class ProcessingContext;
class ConcreteDataMatcher;
class InputSpec;
class ConfigParamSpec;
class InitContext;
} // namespace framework
namespace tpc
{
class CorrectionMapsLoader : public o2::gpu::CorrectionMapsHelper
{
public:
CorrectionMapsLoader() = default;
~CorrectionMapsLoader() = default;
CorrectionMapsLoader(const CorrectionMapsLoader&) = delete;
bool accountCCDBInputs(const o2::framework::ConcreteDataMatcher& matcher, void* obj);
void extractCCDBInputs(o2::framework::ProcessingContext& pc, float tpcScaler = -1.f);
void init(o2::framework::InitContext& ic, bool idcsAvailable);
void checkMeanScaleConsistency(float meanLumi, float threshold) const;
static void requestCCDBInputs(std::vector<o2::framework::InputSpec>& inputs, const o2::tpc::CorrectionMapsGloOpts& gloOpts);
void enableSecEdgeFlucCorrection(const bool enable = true) { mApplySecEdgeFlucCorr = enable; }
bool applySecEdgeFlucCorrection() const { return mApplySecEdgeFlucCorr; }
const auto& getSectorEdgeFlucInfo() const { return mSecEdgeFlucInfo; }
protected:
static void addOption(std::vector<o2::framework::ConfigParamSpec>& options, o2::framework::ConfigParamSpec&& osp);
static void addInput(std::vector<o2::framework::InputSpec>& inputs, o2::framework::InputSpec&& isp);
float mInstLumiCTPFactor = 1.0; // multiplicative factor for inst. lumi
int mLumiCTPSource = 0; // 0: main, 1: alternative CTP lumi source
bool mIDC2CTPFallbackActive = false; // flag indicating that fallback from IDC to CTP scaling is active
o2::tpc::SectorEdgeFluctuations mSecEdgeFlucInfo; // definition of sector edge fluctuation distortion map scaling
bool mApplySecEdgeFlucCorr = true; // flag indicating if sector edge fluctuation correction is enabled
};
} // namespace tpc
} // namespace o2
#endif