Project
Loading...
Searching...
No Matches
TPCScalerSpec.cxx
Go to the documentation of this file.
1// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3// All rights not expressly granted are reserved.
4//
5// This software is distributed under the terms of the GNU General Public
6// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7//
8// In applying this license CERN does not waive the privileges and immunities
9// granted to it by virtue of its status as an Intergovernmental Organization
10// or submit itself to any jurisdiction.
11
16
17#include "Framework/Task.h"
18#include "Framework/Logger.h"
26#include "TTree.h"
32
33using namespace o2::framework;
34
35namespace o2
36{
37namespace tpc
38{
39
40class TPCScalerSpec : public Task
41{
42 public:
43 TPCScalerSpec(std::shared_ptr<o2::base::GRPGeomRequest> req, const o2::tpc::CorrectionMapsGloOpts& sclOpts, bool enableIDCs, bool enableMShape) : mCCDBRequest(req), mEnableIDCs(enableIDCs), mEnableMShape(enableMShape), mGlobOpts(sclOpts)
44 {
45 mTPCCorrMapsLoader.setLumiScaleType(sclOpts.lumiType);
46 mTPCCorrMapsLoader.setLumiScaleMode(sclOpts.lumiMode);
47 mTPCCorrMapsLoader.setCheckCTPIDCConsistency(sclOpts.checkCTPIDCconsistency);
49 };
50
52 {
54 mIonDriftTimeMS = ic.options().get<float>("ion-drift-time");
55 mMaxTimeWeightsMS = ic.options().get<float>("max-time-for-weights");
56 mMShapeScalingFac = ic.options().get<float>("m-shape-scaling-factor");
57 mEnableWeights = !(ic.options().get<bool>("disableWeights"));
58 const bool enableStreamer = ic.options().get<bool>("enableStreamer");
59 const int mshapeThreads = ic.options().get<int>("n-threads");
60 mKnotsYMshape = ic.options().get<int>("n-knots-y");
61 mKnotsZMshape = ic.options().get<int>("n-knots-z");
64
65 if (enableStreamer) {
66 mStreamer = std::make_unique<o2::utils::TreeStreamRedirector>("M_Shape.root", "recreate");
67 }
68 mTPCCorrMapsLoader.init(ic, mEnableIDCs);
69 }
70
72 {
73 if (mStreamer) {
74 mStreamer->Close();
75 }
76 }
77
78 void run(ProcessingContext& pc) final
79 {
81 mTPCVDriftHelper.extractCCDBInputs(pc);
82 if (mTPCVDriftHelper.isUpdated()) {
83 mTPCVDriftHelper.acknowledgeUpdate();
84 }
85
86 if (mEnableIDCs && pc.inputs().isValid("tpcscaler")) {
87 pc.inputs().get<TTree*>("tpcscaler");
88 }
89
90 if (mEnableWeights && mEnableIDCs) {
91 if (pc.inputs().isValid("tpcscalerw")) {
92 pc.inputs().get<TPCScalerWeights*>("tpcscalerw");
93 }
94 }
95 if (mEnableMShape && pc.inputs().isValid("mshape")) {
96 pc.inputs().get<TTree*>("mshape");
97 }
98
99 const auto orbitResetTimeMS = o2::base::GRPGeomHelper::instance().getOrbitResetTimeMS();
100 const auto firstTFOrbit = pc.services().get<o2::framework::TimingInfo>().firstTForbit;
101 const double timestamp = orbitResetTimeMS + firstTFOrbit * o2::constants::lhc::LHCOrbitMUS * 0.001;
102 int currRun = pc.services().get<o2::framework::TimingInfo>().runNumber;
103 if (mEnableMShape) {
104 static int runWarningMS = -1;
105 if ((mMShapeTPCScaler.getRun() != -1) && currRun != mMShapeTPCScaler.getRun() && runWarningMS != currRun) {
106 LOGP(alarm, "Run number {} of processed data and run number {} of loaded TPC M-shape scaler doesnt match!", pc.services().get<o2::framework::TimingInfo>().runNumber, mMShapeTPCScaler.getRun());
107 runWarningMS = currRun;
108 }
109
110 const auto& boundaryPotential = mMShapeTPCScaler.getBoundaryPotential(timestamp);
111 if (!boundaryPotential.mPotential.empty()) {
112 LOGP(info, "Calculating M-shape correction from input boundary potential");
113 const Side side = Side::A;
114 o2::tpc::SpaceCharge<double> sc = o2::tpc::SpaceCharge<double>(mMShapeTPCScaler.getMShapes().mBField, mMShapeTPCScaler.getMShapes().mZ, mMShapeTPCScaler.getMShapes().mR, mMShapeTPCScaler.getMShapes().mPhi);
115 for (int iz = 0; iz < mMShapeTPCScaler.getMShapes().mZ; ++iz) {
116 for (int iphi = 0; iphi < mMShapeTPCScaler.getMShapes().mPhi; ++iphi) {
117 const float pot = mMShapeScalingFac * boundaryPotential.mPotential[iz];
118 sc.setPotential(iz, 0, iphi, side, pot);
119 }
120 }
121
123 sc.calcEField(side);
125
126 std::function<void(int, double, double, double, double&, double&, double&)> getCorrections = [&sc = sc](const int roc, double x, double y, double z, double& dx, double& dy, double& dz) {
127 Side side = roc < 18 ? Side::A : Side::C;
128 if (side == Side::C) {
129 dx = 0;
130 dy = 0;
131 dz = 0;
132 } else {
133 sc.getCorrections(x, y, z, side, dx, dy, dz);
134 }
135 };
136
137 std::unique_ptr<TPCFastSpaceChargeCorrection> spCorrection = TPCFastSpaceChargeCorrectionHelper::instance()->createFromGlobalCorrection(getCorrections, mKnotsYMshape, mKnotsZMshape);
138 std::unique_ptr<TPCFastTransform> fastTransform(TPCFastTransformHelperO2::instance()->create(0, *spCorrection));
139 mTPCCorrMapsLoader.setCorrMapMShape(std::move(fastTransform));
140 }
141
142 if (mStreamer) {
143 (*mStreamer) << "treeMShape"
144 << "firstTFOrbit=" << firstTFOrbit
145 << "timestamp=" << timestamp
146 << "boundaryPotential=" << boundaryPotential
147 << "mMShapeScalingFac=" << mMShapeScalingFac
148 << "\n";
149 }
150 }
151
152 float tpcScaler = -1.f;
153 if (mEnableIDCs) {
154 static int runWarningIDC = -1;
155 if (pc.services().get<o2::framework::TimingInfo>().runNumber != mTPCScaler.getRun() && runWarningIDC != currRun) {
156 LOGP(alarm, "Run number {} of processed data and run number {} of loaded TPC scaler doesnt match!", pc.services().get<o2::framework::TimingInfo>().runNumber, mTPCScaler.getRun());
157 runWarningIDC = currRun;
158 }
159 float scalerA = mTPCScaler.getMeanScaler(timestamp, o2::tpc::Side::A);
160 float scalerC = mTPCScaler.getMeanScaler(timestamp, o2::tpc::Side::C);
161 float meanScaler = (scalerA + scalerC) / 2;
162 tpcScaler = meanScaler;
163 if (mStreamer) {
164 (*mStreamer) << "treeIDC"
165 << "scalerA=" << scalerA
166 << "scalerC=" << scalerC
167 << "firstTFOrbit=" << firstTFOrbit
168 << "timestamp=" << timestamp
169 << "\n";
170 }
171 }
172 // check for Maps update
173 mTPCCorrMapsLoader.extractCCDBInputs(pc, tpcScaler);
174
175 if (mGlobOpts.requestCTPLumi) {
176 const float lumiCTP = mTPCCorrMapsLoader.getInstLumiCTP();
177 // if CTP lumi was notrequest - defualt of 0 is published, otherwise the value is scaled with the provided factor
178 LOGP(info, "Publishing CTP Lumi: {} for timestamp: {}, firstTFOrbit: {}", lumiCTP, timestamp, firstTFOrbit);
179 pc.outputs().snapshot(Output{header::gDataOriginCTP, "LUMICTP"}, lumiCTP);
180 }
181
182 buildMap(pc, timestamp);
183 }
184
185 void buildMap(ProcessingContext& pc, int64_t timestamp)
186 {
187 const auto lumiMode = mTPCCorrMapsLoader.getLumiScaleMode();
189 std::vector<std::pair<const o2::gpu::TPCFastSpaceChargeCorrection*, TPCFastSpaceChargeCorrectionHelper::SectorScales>> additionalCorrections;
190
191 auto uniformScale = [](double s) {
193 ss.fill(s);
194 return ss;
195 };
196
197 if (lumiMode == LumiScaleMode::NoCorrection) {
198 std::unique_ptr<o2::gpu::TPCFastTransform> dummy(TPCFastTransformHelperO2::instance()->create(0));
199 finalMap.cloneFromObject(*dummy, nullptr);
200 finalMap.setApplyCorrectionOff();
201 } else {
202 auto* corrMap = mTPCCorrMapsLoader.getCorrMap();
203 const auto* corrMapRef = mTPCCorrMapsLoader.getCorrMapRef();
204 finalMap.cloneFromObject(lumiMode == LumiScaleMode::StaticMapOnly && corrMapRef ? *corrMapRef : *corrMap, nullptr);
205 finalMap.setApplyCorrectionOn();
206
207 const float lumiScale = mTPCCorrMapsLoader.getLumiScale();
208
209 // if standard scaling is used: map(lumi) = (mean_map - ref_map) * lumiScale + ref_map
210 if (lumiMode == LumiScaleMode::Linear) {
211 const std::vector<std::pair<const o2::gpu::TPCFastSpaceChargeCorrection*, double>> step0{{&(corrMapRef->getCorrection()), -1.f}};
212 // finalMap = (mean_map - finalMap)
214
215 // finalMap = finalMap * lumiScale + ref_map
216 const std::vector<std::pair<const o2::gpu::TPCFastSpaceChargeCorrection*, double>> step1{{&(corrMapRef->getCorrection()), 1.}};
218
219 } else if (lumiMode == LumiScaleMode::DerivativeMap || lumiMode == LumiScaleMode::DerivativeMapMC) {
220 additionalCorrections.emplace_back(&(corrMapRef->getCorrection()), uniformScale(lumiScale));
221 }
222
223 // if mshape map valid
224 if (!mTPCCorrMapsLoader.isCorrMapMShapeDummy()) {
225 LOGP(info, "Adding M-shape correction to the final map with scaling factor {}", mMShapeScalingFac);
226 additionalCorrections.emplace_back(&(mTPCCorrMapsLoader.getCorrMapMShape()->getCorrection()), uniformScale(1.));
227 }
228
229 // --- sector-edge fluctuation correction ---
230 if (mTPCCorrMapsLoader.applySecEdgeFlucCorrection()) {
231 LOGP(info, "Checking for sector edge fluctuation");
232 const int currRun = pc.services().get<o2::framework::TimingInfo>().runNumber;
233 const auto activeSectors = mTPCCorrMapsLoader.getSectorEdgeFlucInfo().getSectorsAtTime(currRun, static_cast<long>(timestamp));
234 if (!activeSectors.empty()) {
235 LOGP(info, "Adding edge-sector correction for {} active sector(s)", activeSectors.size());
237 for (const auto& [sector, scale] : activeSectors) {
238 sectorScales[sector] = static_cast<double>(scale);
239 }
240 additionalCorrections.emplace_back(&mTPCCorrMapsLoader.getCorrMapSecEdgeFluc()->getCorrection(), sectorScales);
241 }
242 }
243
244 if (!additionalCorrections.empty()) {
245 TPCFastSpaceChargeCorrectionHelper::instance()->addCorrections(finalMap.getCorrection(), uniformScale(1.), additionalCorrections);
246 }
247 }
248
249 Output corrMapOutput{header::gDataOriginTPC, "TPCCORRMAP", 0};
250 auto outputBuffer = o2::pmr::vector<char>(pc.outputs().getMemoryResource(corrMapOutput));
251 outputBuffer.resize(TPCFastTransformPOD::estimateSize(finalMap.getCorrection()));
252 auto* pod = TPCFastTransformPOD::create(outputBuffer.data(), outputBuffer.size(), finalMap);
253 const auto& vd = mTPCVDriftHelper.getVDriftObject();
254 o2::tpc::TPCFastTransformHelperO2::instance()->updateCalibration(*pod, 0, vd.corrFact, vd.refVDrift, vd.getTimeOffset());
255 pc.outputs().adoptContainer(corrMapOutput, std::move(outputBuffer));
256 }
257
258 void finaliseCCDB(o2::framework::ConcreteDataMatcher& matcher, void* obj) final
259 {
261 mTPCVDriftHelper.accountCCDBInputs(matcher, obj);
262 if (matcher == ConcreteDataMatcher(o2::header::gDataOriginTPC, "TPCSCALERCCDB", 0)) {
263 LOGP(info, "Updating TPC scaler");
264 mTPCScaler.setFromTree(*((TTree*)obj));
265 if (mIonDriftTimeMS > 0) {
266 LOGP(info, "Setting ion drift time to: {}", mIonDriftTimeMS);
267 mTPCScaler.setIonDriftTimeMS(mIonDriftTimeMS);
268 }
269 if (mScalerWeights.isValid()) {
270 LOGP(info, "Setting TPC scaler weights");
271 mTPCScaler.setScalerWeights(mScalerWeights);
272 mTPCScaler.useWeights(true);
273 if (mIonDriftTimeMS == -1) {
274 overWriteIntegrationTime();
275 }
276 }
277 }
278 if (matcher == ConcreteDataMatcher(o2::header::gDataOriginTPC, "TPCSCALERWCCDB", 0)) {
279 LOGP(info, "Updating TPC scaler weights");
280 mScalerWeights = *(TPCScalerWeights*)obj;
281 mTPCScaler.setScalerWeights(mScalerWeights);
282 mTPCScaler.useWeights(true);
283 // in case ion drift time is not specified it is overwritten by the value in the weight object
284 if (mIonDriftTimeMS == -1) {
285 overWriteIntegrationTime();
286 }
287 }
288 if (matcher == ConcreteDataMatcher(o2::header::gDataOriginTPC, "MSHAPEPOTCCDB", 0)) {
289 LOGP(info, "Updating M-shape TPC scaler");
290 mMShapeTPCScaler.setFromTree(*((TTree*)obj));
291 if (mMShapeTPCScaler.getRun() == -1) {
292 LOGP(info, "Loaded default M-Shape correction object from CCDB");
293 }
294 }
295 if (mTPCCorrMapsLoader.accountCCDBInputs(matcher, obj)) {
296 return;
297 }
298 }
299
300 private:
301 std::shared_ptr<o2::base::GRPGeomRequest> mCCDBRequest;
302 const bool mEnableIDCs{true};
303 const bool mEnableMShape{false};
304 const o2::tpc::CorrectionMapsGloOpts mGlobOpts;
305 bool mEnableWeights{false};
306 TPCScalerWeights mScalerWeights{};
307 float mIonDriftTimeMS{-1};
308 float mMaxTimeWeightsMS{500};
309 TPCScaler mTPCScaler;
310 float mMShapeScalingFac{0};
311 TPCMShapeCorrection mMShapeTPCScaler;
312 int mKnotsYMshape{4};
313 int mKnotsZMshape{4};
314 std::unique_ptr<o2::utils::TreeStreamRedirector> mStreamer;
315 o2::tpc::CorrectionMapsLoader mTPCCorrMapsLoader{};
316 o2::tpc::VDriftHelper mTPCVDriftHelper{};
317
318 void overWriteIntegrationTime()
319 {
320 float integrationTime = std::abs(mScalerWeights.mFirstTimeStampMS);
321 if (integrationTime <= 0) {
322 return;
323 }
324 if (integrationTime > mMaxTimeWeightsMS) {
325 integrationTime = mMaxTimeWeightsMS;
326 }
327 LOGP(info, "Setting maximum integration time for weights to: {}", integrationTime);
328 mTPCScaler.setIonDriftTimeMS(integrationTime);
329 }
330};
331
333{
334 std::vector<InputSpec> inputs;
335 if (enableIDCs) {
336 LOGP(info, "Publishing IDC scalers for space-charge distortion fluctuation correction");
337 inputs.emplace_back("tpcscaler", o2::header::gDataOriginTPC, "TPCSCALERCCDB", 0, Lifetime::Condition, ccdbParamSpec(o2::tpc::CDBTypeMap.at(o2::tpc::CDBType::CalScaler), {}, 1)); // time-dependent
338 inputs.emplace_back("tpcscalerw", o2::header::gDataOriginTPC, "TPCSCALERWCCDB", 0, Lifetime::Condition, ccdbParamSpec(o2::tpc::CDBTypeMap.at(o2::tpc::CDBType::CalScalerWeights), {}, 0)); // non time-dependent
339 }
340 if (enableMShape) {
341 LOGP(info, "Publishing M-shape correction map");
342 inputs.emplace_back("mshape", o2::header::gDataOriginTPC, "MSHAPEPOTCCDB", 0, Lifetime::Condition, ccdbParamSpec(o2::tpc::CDBTypeMap.at(o2::tpc::CDBType::CalMShape), {}, 1)); // time-dependent
343 }
344 auto ccdbRequest = std::make_shared<o2::base::GRPGeomRequest>(true, // orbitResetTime
345 false, // GRPECS=true for nHBF per TF
346 false, // GRPLHCIF
347 false, // GRPMagField
348 false, // askMatLUT
350 inputs);
351
352 std::vector<OutputSpec> outputs;
353 outputs.emplace_back(o2::header::gDataOriginTPC, "TPCCORRMAP", 0, Lifetime::Timeframe);
354 if (sclOpts.requestCTPLumi) {
355 outputs.emplace_back(o2::header::gDataOriginCTP, "LUMICTP", 0, Lifetime::Timeframe);
356 }
359
360 return DataProcessorSpec{
361 "tpc-scaler",
362 inputs,
363 outputs,
364 AlgorithmSpec{adaptFromTask<TPCScalerSpec>(ccdbRequest, sclOpts, enableIDCs, enableMShape)},
365 Options{
366 {"ion-drift-time", VariantType::Float, -1.f, {"Overwrite ion drift time if a value >0 is provided"}},
367 {"max-time-for-weights", VariantType::Float, 500.f, {"Maximum possible integration time in ms when weights are used"}},
368 {"m-shape-scaling-factor", VariantType::Float, 1.f, {"Scale M-shape scaler with this value"}},
369 {"disableWeights", VariantType::Bool, false, {"Disable weights for TPC scalers"}},
370 {"enableStreamer", VariantType::Bool, false, {"Enable streaming of M-shape scalers"}},
371 {"n-threads", VariantType::Int, 4, {"Number of threads used for the M-shape correction"}},
372 {"n-knots-y", VariantType::Int, 4, {"Number of knots in y-direction used for the M-shape correction"}},
373 {"n-knots-z", VariantType::Int, 4, {"Number of knots in z-direction used for the M-shape correction"}}}};
374}
375
376} // namespace tpc
377} // namespace o2
Simple interface to the CDB manager.
Helper class to access load maps from CCDB.
Helper for geometry and GRP related CCDB requests.
uint32_t roc
Definition RawData.h:3
uint32_t side
Definition RawData.h:0
This class contains the algorithms for calculation the distortions and corrections.
class to create TPC fast space charge correction
Helper class to extract VDrift from different sources.
auto getOrbitResetTimeMS() const
void checkUpdates(o2::framework::ProcessingContext &pc)
bool finaliseCCDB(o2::framework::ConcreteDataMatcher &matcher, void *obj)
static GRPGeomHelper & instance()
void setRequest(std::shared_ptr< GRPGeomRequest > req)
o2::pmr::FairMQMemoryResource * getMemoryResource(const Output &spec)
CacheId adoptContainer(const Output &, ContainerT &, CacheStrategy, o2::header::SerializationMethod)
DataAllocator & outputs()
The data allocator is used to allocate memory for the output data.
ServiceRegistryRef services()
The services registry associated with this processing context.
const o2::gpu::TPCFastTransform * getCorrMapSecEdgeFluc() const
void setLumiScaleType(tpc::LumiScaleType v)
void setLumiScaleMode(tpc::LumiScaleMode v)
const o2::gpu::TPCFastTransform * getCorrMapMShape() const
const o2::gpu::TPCFastTransform * getCorrMap() const
void setCorrMapMShape(std::unique_ptr< o2::gpu::TPCFastTransform > &&m)
bool isCorrMapMShapeDummy() const
return returns if the correction map for the M-shape correction is a dummy spline object
const o2::gpu::TPCFastTransform * getCorrMapRef() const
tpc::LumiScaleMode getLumiScaleMode() const
static TPCFastTransformPOD * create(aligned_unique_buffer_ptr< TPCFastTransformPOD > &destVector, const TPCFastTransform &src)
Create POD transform from old flat-buffer one. Provided vector will serve as a buffer.
static size_t estimateSize(const TPCFastTransform &src)
void cloneFromObject(const TPCFastTransform &obj, char *newFlatBufferPtr)
Construction interface.
TPCFastSpaceChargeCorrection & getCorrection()
Gives a reference for external initialization of TPC corrections.
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)
static void requestCCDBInputs(std::vector< o2::framework::InputSpec > &inputs, const o2::tpc::CorrectionMapsGloOpts &gloOpts)
const auto & getSectorEdgeFlucInfo() const
void enableSecEdgeFlucCorrection(const bool enable=true)
static void setNThreads(const int nThreads)
set the number of threads used for some of the calculations
void getCorrections(const DataT x, const DataT y, const DataT z, const Side side, DataT &corrX, DataT &corrY, DataT &corrZ) const
NumericalFields< DataT > getElectricFieldsInterpolator(const Side side) const
void calcEField(const Side side)
void setPotential(int iz, int ir, int iphi, Side side, float val)
setting the potential directly for given vertex
void calcGlobalCorrections(const Fields &formulaStruct, const int type=3)
void poissonSolver(const Side side, const DataT stoppingConvergence=1e-6, const int symmetry=0)
std::array< double, TPCFastTransformGeo::getNumberOfSectors()> SectorScales
std::unique_ptr< TPCFastSpaceChargeCorrection > createFromGlobalCorrection(std::function< void(int roc, double gx, double gy, double gz, double &dgx, double &dgy, double &dgz)> correctionGlobal, const int nKnotsY=10, const int nKnotsZ=20)
creates TPCFastSpaceChargeCorrection object from a continious space charge correction in global coord...
void setNthreads(int n)
_______________ Settings ________________________
static TPCFastSpaceChargeCorrectionHelper * instance()
Singleton.
void addCorrections(o2::gpu::TPCFastSpaceChargeCorrection &mainCorrection, double scale, const std::vector< std::pair< const o2::gpu::TPCFastSpaceChargeCorrection *, double > > &additionalCorrections)
static TPCFastTransformHelperO2 * instance()
Singleton.
int updateCalibration(TPCFastTransform &fastTransform, int64_t TimeStamp, float vDriftFactor=1.f, float vDriftRef=0.f, float driftTimeOffset=0.f)
Updates the transformation with the new time stamp.
BoundaryPotentialIFC getBoundaryPotential(const double timestamp) const
void setFromTree(TTree &tpcMShapeTree)
set this object from input tree
void endOfStream(EndOfStreamContext &eos) final
void buildMap(ProcessingContext &pc, int64_t timestamp)
TPCScalerSpec(std::shared_ptr< o2::base::GRPGeomRequest > req, const o2::tpc::CorrectionMapsGloOpts &sclOpts, bool enableIDCs, bool enableMShape)
void finaliseCCDB(o2::framework::ConcreteDataMatcher &matcher, void *obj) final
void run(ProcessingContext &pc) final
void init(framework::InitContext &ic) final
float getMeanScaler(double timestamp, o2::tpc::Side side) const
void setIonDriftTimeMS(float ionDriftTimeMS)
Definition TPCScaler.h:58
int getRun() const
Definition TPCScaler.h:106
void useWeights(bool useWeights)
enable usage of weights
Definition TPCScaler.h:142
void setFromTree(TTree &tpcScalerTree)
set this object from input tree
void setScalerWeights(const TPCScalerWeights &weights)
setting the weights for the scalers
Definition TPCScaler.h:136
static void requestCCDBInputs(std::vector< o2::framework::InputSpec > &inputs, bool laser=true, bool itstpcTgl=true)
void extractCCDBInputs(o2::framework::ProcessingContext &pc, bool laser=true, bool itstpcTgl=true)
const VDriftCorrFact & getVDriftObject() const
bool accountCCDBInputs(const o2::framework::ConcreteDataMatcher &matcher, void *obj)
bool isUpdated() const
GLint GLenum GLint x
Definition glcorearb.h:403
GLint y
Definition glcorearb.h:270
typedef void(APIENTRYP PFNGLCULLFACEPROC)(GLenum mode)
GLdouble GLdouble GLdouble z
Definition glcorearb.h:843
constexpr o2::header::DataOrigin gDataOriginCTP
Definition DataHeader.h:564
constexpr o2::header::DataOrigin gDataOriginTPC
Definition DataHeader.h:576
constexpr double LHCOrbitMUS
Defining ITS Vertex explicitly as messageable.
Definition Cartesian.h:288
std::vector< ConfigParamSpec > ccdbParamSpec(std::string const &path, int runDependent, std::vector< CCDBMetadata > metadata={}, int qrate=0)
std::vector< ConfigParamSpec > Options
std::vector< T, fair::mq::pmr::polymorphic_allocator< T > > vector
@ DerivativeMap
map(lumi) = mean_map + lumiScale * (derivativeMap) where derivativeMap = (mean_map_A - mean_map_B)
@ Linear
map(lumi) = (mean_map - referenceMap) * lumiScale + referenceMap
@ NoCorrection
no corrections at all
@ StaticMapOnly
use only static map instead of main map
@ DerivativeMapMC
same DerivativeMap, but for MC
const std::unordered_map< CDBType, const std::string > CDBTypeMap
Storage name in CCDB for each calibration and parameter type.
Definition CDBTypes.h:98
@ TPCScaler
use TPC scaler for scaling
Side
TPC readout sidE.
Definition Defs.h:35
@ A
Definition Defs.h:35
@ C
Definition Defs.h:36
o2::framework::DataProcessorSpec getTPCScalerSpec(bool enableIDCs, bool enableMShape, const o2::tpc::CorrectionMapsGloOpts &sclOpts)
@ CalScaler
Scaler from IDCs or combined estimator.
@ CalScalerWeights
Weights for scalers.
@ CalMShape
calibration object for M-shape distortions
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
bool enableSecEdgeFlucCorrection
enable correction of sector edge fluctuations
LumiScaleType lumiType
what estimator to used for corrections scaling: 0: no scaling, 1: CTP, 2: IDC
bool checkCTPIDCconsistency
check the selected CTP or IDC scaling source being consistent with mean scaler of the map
bool requestCTPLumi
request CTP Lumi regardless of what is used for corrections scaling
LumiScaleMode lumiMode
what corrections method to use: 0: classical scaling, 1: Using of the derivative map,...
float mFirstTimeStampMS
first timestamp
Definition TPCScaler.h:35