Skip to content

Commit 3cb240c

Browse files
authored
Merge pull request #25 from alibuild/alibot-cleanup-12679
[PWGDQ] Please consider the following formatting changes to #12679
2 parents c3ed238 + 4e1b512 commit 3cb240c

File tree

2 files changed

+13
-14
lines changed

2 files changed

+13
-14
lines changed

PWGDQ/Core/VarManager.cxx

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ o2::vertexing::FwdDCAFitterN<3> VarManager::fgFitterThreeProngFwd;
4545
o2::globaltracking::MatchGlobalFwd VarManager::mMatching;
4646
std::map<VarManager::CalibObjects, TObject*> VarManager::fgCalibs;
4747
bool VarManager::fgRunTPCPostCalibration[4] = {false, false, false, false};
48-
int VarManager::fgCalibrationType = 0; // 0 - no calibration, 1 - calibration vs (TPCncls,pIN,eta) typically for pp, 2 - calibration vs (eta,nPV,nLong,tLong) typically for PbPb
48+
int VarManager::fgCalibrationType = 0; // 0 - no calibration, 1 - calibration vs (TPCncls,pIN,eta) typically for pp, 2 - calibration vs (eta,nPV,nLong,tLong) typically for PbPb
4949
bool VarManager::fgUseInterpolatedCalibration = true; // use interpolated calibration histograms (default: true)
5050

5151
//__________________________________________________________________
@@ -213,7 +213,8 @@ float VarManager::calculateCosPA(KFParticle kfp, KFParticle PV)
213213
}
214214

215215
//__________________________________________________________________
216-
double VarManager::ComputePIDcalibration(int species, double nSigmaValue) {
216+
double VarManager::ComputePIDcalibration(int species, double nSigmaValue)
217+
{
217218
// species: 0 - electron, 1 - pion, 2 - kaon, 3 - proton
218219
// Depending on the PID calibration type, we use different types of calibration histograms
219220

@@ -263,8 +264,7 @@ double VarManager::ComputePIDcalibration(int species, double nSigmaValue) {
263264
double mean = calibMeanHist->GetBinContent(binTPCncls, binPin, binEta);
264265
double sigma = calibSigmaHist->GetBinContent(binTPCncls, binPin, binEta);
265266
return (nSigmaValue - mean) / sigma; // Return the calibrated nSigma value
266-
}
267-
else if (fgCalibrationType == 2) {
267+
} else if (fgCalibrationType == 2) {
268268
// get the calibration histograms
269269
CalibObjects calibMean, calibSigma, calibStatus;
270270
switch (species) {
@@ -323,12 +323,12 @@ double VarManager::ComputePIDcalibration(int species, double nSigmaValue) {
323323
case 0:
324324
// good calibration, return the calibrated nSigma value
325325
return (nSigmaValue - mean) / sigma;
326-
break;
326+
break;
327327
case 1:
328328
// calibration not valid, return the original nSigma value
329329
return nSigmaValue;
330-
break;
331-
case 2: // calibration constant has poor stat uncertainty, consider the user option for what to do
330+
break;
331+
case 2: // calibration constant has poor stat uncertainty, consider the user option for what to do
332332
case 3:
333333
// calibration constants have been interpolated
334334
if (fgUseInterpolatedCalibration) {
@@ -337,14 +337,14 @@ double VarManager::ComputePIDcalibration(int species, double nSigmaValue) {
337337
// return the original nSigma value
338338
return nSigmaValue;
339339
}
340-
break;
340+
break;
341341
case 4:
342342
// calibration constants interpolation failed, return the original nSigma value
343343
return nSigmaValue;
344-
break;
344+
break;
345345
default:
346346
return nSigmaValue; // unknown status, return the original nSigma value
347-
break;
347+
break;
348348
};
349349
} else {
350350
// unknown calibration type, return the original nSigma value

PWGDQ/Core/VarManager.h

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1239,8 +1239,8 @@ class VarManager : public TObject
12391239

12401240
static std::map<CalibObjects, TObject*> fgCalibs; // map of calibration histograms
12411241
static bool fgRunTPCPostCalibration[4]; // 0-electron, 1-pion, 2-kaon, 3-proton
1242-
static int fgCalibrationType; // 0 - no calibration, 1 - calibration vs (TPCncls,pIN,eta) typically for pp, 2 - calibration vs (eta,nPV,nLong,tLong) typically for PbPb
1243-
static bool fgUseInterpolatedCalibration; // use interpolated calibration histograms (default: true)
1242+
static int fgCalibrationType; // 0 - no calibration, 1 - calibration vs (TPCncls,pIN,eta) typically for pp, 2 - calibration vs (eta,nPV,nLong,tLong) typically for PbPb
1243+
static bool fgUseInterpolatedCalibration; // use interpolated calibration histograms (default: true)
12441244

12451245
VarManager& operator=(const VarManager& c);
12461246
VarManager(const VarManager& c);
@@ -1380,7 +1380,6 @@ o2::dataformats::GlobalFwdTrack VarManager::PropagateMuon(const T& muon, const C
13801380
return propmuon;
13811381
}
13821382

1383-
13841383
template <uint32_t fillMap, typename T, typename C>
13851384
void VarManager::FillMuonPDca(const T& muon, const C& collision, float* values)
13861385
{
@@ -2480,7 +2479,7 @@ void VarManager::FillTrack(T const& track, float* values)
24802479
values[kTPCnSigmaPr_Corr] = track.tpcNSigmaPr();
24812480
}
24822481
}
2483-
2482+
24842483
if constexpr ((fillMap & TrackPID) > 0 || (fillMap & ReducedTrackBarrelPID) > 0) {
24852484
values[kTOFnSigmaEl] = track.tofNSigmaEl();
24862485
values[kTOFnSigmaPi] = track.tofNSigmaPi();

0 commit comments

Comments
 (0)