Skip to content

Commit 98f862d

Browse files
Merge pull request #23 from alibuild/alibot-cleanup-9820
Please consider the following formatting changes to AliceO2Group#9820
2 parents 7677b1d + e9177dc commit 98f862d

File tree

3 files changed

+32
-33
lines changed

3 files changed

+32
-33
lines changed

PWGLF/DataModel/LFSigmaTables.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ DECLARE_SOA_COLUMN(LambdaPt, lambdaPt, float);
127127
DECLARE_SOA_COLUMN(LambdaMass, lambdaMass, float);
128128
DECLARE_SOA_COLUMN(AntiLambdaMass, antilambdaMass, float);
129129
DECLARE_SOA_COLUMN(LambdaQt, lambdaQt, float);
130-
DECLARE_SOA_COLUMN(LambdaAlpha, lambdaAlpha, float);
130+
DECLARE_SOA_COLUMN(LambdaAlpha, lambdaAlpha, float);
131131
DECLARE_SOA_COLUMN(LambdaLifeTime, lambdaLifeTime, float);
132132
DECLARE_SOA_COLUMN(LambdaRadius, lambdaRadius, float);
133133
DECLARE_SOA_COLUMN(LambdaCosPA, lambdaCosPA, float);

PWGLF/TableProducer/Strangeness/sigma0builder.cxx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -72,11 +72,11 @@ struct sigma0builder {
7272
Preslice<V0StandardDerivedDatas> perCollisionSTDDerived = o2::aod::v0data::straCollisionId;
7373

7474
// Histogram registry
75-
HistogramRegistry histos{"Histos", {}, OutputObjHandlingPolicy::AnalysisObject};
75+
HistogramRegistry histos{"Histos", {}, OutputObjHandlingPolicy::AnalysisObject};
7676

7777
// Event selection
7878
Configurable<bool> doPPAnalysis{"doPPAnalysis", true, "if in pp, set to true"};
79-
79+
8080
struct : ConfigurableGroup {
8181
Configurable<bool> requireSel8{"requireSel8", true, "require sel8 event selection"};
8282
Configurable<bool> requireTriggerTVX{"requireTriggerTVX", true, "require FT0 vertex (acceptable FT0C-FT0A time difference) at trigger level"};
@@ -745,7 +745,7 @@ struct sigma0builder {
745745
fPhotonPosITSCls, fPhotonNegITSCls, fPhotonPosITSChi2PerNcl, fPhotonNegITSChi2PerNcl,
746746
fPhotonV0Type, GammaBDTScore);
747747

748-
sigmaLambdaExtras(fLambdaPt, fLambdaMass, fAntiLambdaMass, fLambdaQt, fLambdaAlpha, fLambdaLifeTime,
748+
sigmaLambdaExtras(fLambdaPt, fLambdaMass, fAntiLambdaMass, fLambdaQt, fLambdaAlpha, fLambdaLifeTime,
749749
fLambdaRadius, fLambdaCosPA, fLambdaDCADau, fLambdaDCANegPV,
750750
fLambdaDCAPosPV, fLambdaEta, fLambdaY, fLambdaPhi, fLambdaPosPrTPCNSigma,
751751
fLambdaPosPiTPCNSigma, fLambdaNegPrTPCNSigma, fLambdaNegPiTPCNSigma,
@@ -816,7 +816,7 @@ struct sigma0builder {
816816
if (!lambda.has_v0MCCore())
817817
continue;
818818

819-
if (lambda.v0Type() != 1){ // safeguard to avoid TPC-only photons
819+
if (lambda.v0Type() != 1) { // safeguard to avoid TPC-only photons
820820
continue;
821821
}
822822

@@ -902,10 +902,10 @@ struct sigma0builder {
902902
if (doPi0QA) // Pi0 QA study
903903
runPi0QA(gamma, lambda);
904904

905-
if (lambda.v0Type() != 1){ // safeguard to avoid TPC-only photons
905+
if (lambda.v0Type() != 1) { // safeguard to avoid TPC-only photons
906906
continue;
907907
}
908-
908+
909909
// Sigma0 candidate properties
910910
std::array<float, 3> pVecPhotons{gamma.px(), gamma.py(), gamma.pz()};
911911
std::array<float, 3> pVecLambda{lambda.px(), lambda.py(), lambda.pz()};

PWGLF/Tasks/Strangeness/sigmaanalysis.cxx

Lines changed: 25 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ struct sigmaanalysis {
6565

6666
// Interaction rate selection:
6767
Configurable<bool> fGetIR{"fGetIR", false, "Flag to retrieve the IR info."};
68-
Configurable<std::string> irSource{"irSource", "T0VTX", "Estimator of the interaction rate (Recommended: pp --> T0VTX, Pb-Pb --> ZNC hadronic)"};
68+
Configurable<std::string> irSource{"irSource", "T0VTX", "Estimator of the interaction rate (Recommended: pp --> T0VTX, Pb-Pb --> ZNC hadronic)"};
6969
Configurable<float> minIR{"minIR", -1, "Min Interaction Rate (kHz). Leave -1 if no selection desired."};
7070
Configurable<float> maxIR{"maxIR", -1, "Max Interaction Rate (kHz). Leave -1 if no selection desired."};
7171

@@ -215,7 +215,7 @@ struct sigmaanalysis {
215215
histos.get<TH1>(HIST("GeneralQA/hCandidateAnalysisSelection"))->GetXaxis()->SetBinLabel(28, "Lambda/ALambda DCAToPV");
216216
histos.get<TH1>(HIST("GeneralQA/hCandidateAnalysisSelection"))->GetXaxis()->SetBinLabel(29, "Lambda/ALambda Mass");
217217
histos.get<TH1>(HIST("GeneralQA/hCandidateAnalysisSelection"))->GetXaxis()->SetBinLabel(30, "Sigma Y");
218-
218+
219219
// Photon Selection QA histos
220220
histos.add("GeneralQA/hPhotonV0Type", "hPhotonV0Type", kTH1F, {{8, 0.5f, 8.5f}});
221221
histos.add("GeneralQA/hPhotonMass", "hPhotonMass", kTH1F, {axisPhotonMass});
@@ -258,7 +258,7 @@ struct sigmaanalysis {
258258
histos.add("GeneralQA/hLambdaPosChi2PerNc", "hLambdaPosChi2PerNc", kTH1F, {axisChi2PerNcl});
259259
histos.add("GeneralQA/hLambdaNegChi2PerNc", "hLambdaNegChi2PerNc", kTH1F, {axisChi2PerNcl});
260260
histos.add("GeneralQA/hLambdaLifeTime", "hLambdaLifeTime", kTH1F, {axisLifetime});
261-
261+
262262
histos.add("GeneralQA/h2dTPCvsTOFNSigma_LambdaPr", "h2dTPCvsTOFNSigma_LambdaPr", {HistType::kTH2F, {axisTPCNSigma, axisTOFNSigma}});
263263
histos.add("GeneralQA/h2dTPCvsTOFNSigma_LambdaPi", "h2dTPCvsTOFNSigma_LambdaPi", {HistType::kTH2F, {axisTPCNSigma, axisTOFNSigma}});
264264
histos.add("GeneralQA/hLambdaDCANegToPV", "hLambdaDCANegToPV", kTH1F, {axisDCAtoPV});
@@ -284,7 +284,7 @@ struct sigmaanalysis {
284284
histos.add("SigmaMassQA/h2dPhotonDCADauToPV", "h2dPhotonDCADauToPV", {HistType::kTH2F, {axisPt, axisSigmaMass}});
285285
histos.add("SigmaMassQA/h2dPhotonDCADau", "h2dPhotonDCADau", {HistType::kTH2F, {axisPt, axisSigmaMass}});
286286
histos.add("SigmaMassQA/h2dPhotonDauTPCCR", "h2dPhotonDauTPCCR", {HistType::kTH2F, {axisPt, axisSigmaMass}});
287-
histos.add("SigmaMassQA/h2dPhotonTPCNSigmaEl", "h2dPhotonTPCNSigmaEl", {HistType::kTH2F, {axisPt, axisSigmaMass}});
287+
histos.add("SigmaMassQA/h2dPhotonTPCNSigmaEl", "h2dPhotonTPCNSigmaEl", {HistType::kTH2F, {axisPt, axisSigmaMass}});
288288
histos.add("SigmaMassQA/h2dPhotonpT", "h2dPhotonpT", {HistType::kTH2F, {axisPt, axisSigmaMass}}); //
289289
histos.add("SigmaMassQA/h2dPhotonY", "h2dPhotonY", {HistType::kTH2F, {axisPt, axisSigmaMass}});
290290
histos.add("SigmaMassQA/h2dPhotonRadius", "h2dPhotonRadius", {HistType::kTH2F, {axisPt, axisSigmaMass}});
@@ -360,7 +360,7 @@ struct sigmaanalysis {
360360
histos.add("MC/hPtTrueAntiLambda_BeforeSel", "hPtTrueAntiLambda_BeforeSel", kTH1F, {axisPt}); // Signal only
361361
histos.add("MC/hPtTrueGamma_BeforeSel", "hPtTrueGamma_BeforeSel", kTH1F, {axisPt}); // Signal only
362362
histos.add("MC/hPtTrueSigma_BeforeSel", "hPtTrueSigma_BeforeSel", kTH1F, {axisPt}); // Signal only
363-
histos.add("MC/hPtTrueAntiSigma_BeforeSel", "hPtTrueAntiSigma_BeforeSel", kTH1F, {axisPt}); // Signal only
363+
histos.add("MC/hPtTrueAntiSigma_BeforeSel", "hPtTrueAntiSigma_BeforeSel", kTH1F, {axisPt}); // Signal only
364364
histos.add("MC/hPtLambdaCand_BeforeSel", "hPtLambdaCand_BeforeSel", kTH1F, {axisPt}); // Bkg + Signal
365365
histos.add("MC/hPtGammaCand_BeforeSel", "hPtGammaCand_BeforeSel", kTH1F, {axisPt}); // Bkg + Signal
366366
histos.add("MC/hPtSigmaCand_BeforeSel", "hPtGammaCand_BeforeSel", kTH1F, {axisPt}); // Bkg + Signal
@@ -430,18 +430,18 @@ struct sigmaanalysis {
430430
histos.fill(HIST("GeneralQA/hPhotonV0Type"), cand.photonV0Type());
431431
if (cand.photonV0Type() != Photonv0TypeSel && Photonv0TypeSel > -1)
432432
return false;
433-
histos.fill(HIST("SigmaMassQA/h2dPhotonV0Type"), cand.sigmapT(), cand.sigmaMass());
433+
histos.fill(HIST("SigmaMassQA/h2dPhotonV0Type"), cand.sigmapT(), cand.sigmaMass());
434434
histos.fill(HIST("GeneralQA/hPhotonMass"), cand.photonMass());
435435
histos.fill(HIST("GeneralQA/hCandidateAnalysisSelection"), 2.);
436436
if (TMath::Abs(cand.photonMass()) > PhotonMaxMass)
437437
return false;
438-
histos.fill(HIST("SigmaMassQA/h2dPhotonMass"), cand.sigmapT(), cand.sigmaMass());
438+
histos.fill(HIST("SigmaMassQA/h2dPhotonMass"), cand.sigmapT(), cand.sigmaMass());
439439
histos.fill(HIST("GeneralQA/hPhotonNegpT"), cand.photonNegPt());
440440
histos.fill(HIST("GeneralQA/hPhotonPospT"), cand.photonPosPt());
441441
histos.fill(HIST("GeneralQA/hCandidateAnalysisSelection"), 3.);
442442
if ((cand.photonPosPt() < PhotonDauMinPt) || (cand.photonNegPt() < PhotonDauMinPt))
443443
return false;
444-
histos.fill(HIST("SigmaMassQA/h2dPhotonDaupT"), cand.sigmapT(), cand.sigmaMass());
444+
histos.fill(HIST("SigmaMassQA/h2dPhotonDaupT"), cand.sigmapT(), cand.sigmaMass());
445445
histos.fill(HIST("GeneralQA/hPhotonDCANegToPV"), cand.photonDCANegPV());
446446
histos.fill(HIST("GeneralQA/hPhotonDCAPosToPV"), cand.photonDCAPosPV());
447447
histos.fill(HIST("GeneralQA/hCandidateAnalysisSelection"), 4.);
@@ -567,12 +567,12 @@ struct sigmaanalysis {
567567
return false;
568568
if (cand.lambdaNegITSCls() < LambdaMinITSclusters && (!LambdaRejectNegITSafterburner || negIsFromAfterburner))
569569
return false;
570-
histos.fill(HIST("SigmaMassQA/h2dLambdaDauITSCls"), cand.sigmapT(), cand.sigmaMass());
570+
histos.fill(HIST("SigmaMassQA/h2dLambdaDauITSCls"), cand.sigmapT(), cand.sigmaMass());
571571
histos.fill(HIST("GeneralQA/hLambdaLifeTime"), cand.lambdaLifeTime());
572572
histos.fill(HIST("GeneralQA/hCandidateAnalysisSelection"), 25.);
573573
if (cand.lambdaLifeTime() > LambdaMaxLifeTime)
574574
return false;
575-
histos.fill(HIST("SigmaMassQA/h2dLambdaLifeTime"), cand.sigmapT(), cand.sigmaMass());
575+
histos.fill(HIST("SigmaMassQA/h2dLambdaLifeTime"), cand.sigmapT(), cand.sigmaMass());
576576
histos.fill(HIST("GeneralQA/hCandidateAnalysisSelection"), 26.);
577577
// Separating lambda and antilambda selections:
578578
if (isLambdalike) { // Lambda selection
@@ -675,15 +675,15 @@ struct sigmaanalysis {
675675
if (doMCAssociation && !(sigma.isSigma() || sigma.isAntiSigma())) {
676676
continue;
677677
}
678-
if (fGetIR){
679-
double interactionRate = rateFetcher.fetch(ccdb.service, sigma.sigmaTimestamp(), sigma.sigmaRunNumber(), irSource)*1.e-3;
678+
if (fGetIR) {
679+
double interactionRate = rateFetcher.fetch(ccdb.service, sigma.sigmaTimestamp(), sigma.sigmaRunNumber(), irSource) * 1.e-3;
680680
histos.fill(HIST("GeneralQA/hInteractionRate"), interactionRate);
681681
histos.fill(HIST("GeneralQA/hCentralityVsInteractionRate"), sigma.sigmaCentrality(), interactionRate);
682-
if ((maxIR!=-1) && (minIR!=-1) && ((interactionRate<=minIR) || (interactionRate>=maxIR))){
682+
if ((maxIR != -1) && (minIR != -1) && ((interactionRate <= minIR) || (interactionRate >= maxIR))) {
683683
continue;
684684
}
685685
}
686-
686+
687687
// Filling histos before analysis selection
688688
histos.fill(HIST("MC/h2dArmenterosBeforeSel"), sigma.photonAlpha(), sigma.photonQt());
689689
histos.fill(HIST("MC/h2dArmenterosBeforeSel"), sigma.lambdaAlpha(), sigma.lambdaQt());
@@ -698,14 +698,14 @@ struct sigmaanalysis {
698698
if (sigma.lambdaCandPDGCode() == 3122)
699699
histos.fill(HIST("MC/hPtTrueLambda_BeforeSel"), sigma.lambdaPt());
700700
if (sigma.lambdaCandPDGCode() == -3122)
701-
histos.fill(HIST("MC/hPtTrueAntiLambda_BeforeSel"), sigma.lambdaPt());
701+
histos.fill(HIST("MC/hPtTrueAntiLambda_BeforeSel"), sigma.lambdaPt());
702702
if (sigma.isSigma())
703703
histos.fill(HIST("MC/hPtTrueSigma_BeforeSel"), sigma.sigmapT());
704704
if (sigma.isAntiSigma())
705-
histos.fill(HIST("MC/hPtTrueAntiSigma_BeforeSel"), sigma.sigmapT());
705+
histos.fill(HIST("MC/hPtTrueAntiSigma_BeforeSel"), sigma.sigmapT());
706706

707707
if (sigma.lambdaAlpha() > 0) { // Lambda Analysis
708-
if (!processSigmaCandidate(sigma, true))
708+
if (!processSigmaCandidate(sigma, true))
709709
continue;
710710

711711
// For Lambda PID Studies
@@ -729,10 +729,9 @@ struct sigmaanalysis {
729729
histos.fill(HIST("MC/h3dSigma0PtResolution"), sigma.sigmapT(), TMath::Abs((sigma.sigmaMCPt() - sigma.sigmapT()) / sigma.sigmaMCPt()), sigma.sigmaMass()); // pT resolution
730730
histos.fill(HIST("MC/h2dPtVsMassSigma_SignalOnly"), sigma.sigmapT(), sigma.sigmaMass());
731731
histos.fill(HIST("MC/hPtTrueSigma_AfterSel"), sigma.sigmapT());
732-
}
733-
}
734-
else{ // AntiLambda Analysis
735-
if (!processSigmaCandidate(sigma, false))
732+
}
733+
} else { // AntiLambda Analysis
734+
if (!processSigmaCandidate(sigma, false))
736735
continue;
737736

738737
if (sigma.lambdaCandPDGCode() == -3122) {
@@ -753,8 +752,8 @@ struct sigmaanalysis {
753752
histos.fill(HIST("MC/hPtTrueSigma_AfterSel"), sigma.sigmapT());
754753
}
755754
}
756-
757-
// Fill histos after selection, please
755+
756+
// Fill histos after selection, please
758757
histos.fill(HIST("MC/hPtGammaCand_AfterSel"), sigma.photonPt());
759758
histos.fill(HIST("GeneralQA/hPhotonMassSelected"), sigma.photonMass());
760759
histos.fill(HIST("MC/hPtSigmaCand_AfterSel"), sigma.sigmapT());
@@ -789,11 +788,11 @@ struct sigmaanalysis {
789788
void processRealData(V0Sigmas const& sigmas)
790789
{
791790
for (auto& sigma : sigmas) { // selecting Sigma0-like candidates
792-
if (fGetIR){
793-
double interactionRate = rateFetcher.fetch(ccdb.service, sigma.sigmaTimestamp(), sigma.sigmaRunNumber(), irSource)*1.e-3;
791+
if (fGetIR) {
792+
double interactionRate = rateFetcher.fetch(ccdb.service, sigma.sigmaTimestamp(), sigma.sigmaRunNumber(), irSource) * 1.e-3;
794793
histos.fill(HIST("GeneralQA/hInteractionRate"), interactionRate);
795794
histos.fill(HIST("GeneralQA/hCentralityVsInteractionRate"), sigma.sigmaCentrality(), interactionRate);
796-
if ((maxIR!=-1) && (minIR!=-1) && ((interactionRate<=minIR) || (interactionRate>=maxIR))){
795+
if ((maxIR != -1) && (minIR != -1) && ((interactionRate <= minIR) || (interactionRate >= maxIR))) {
797796
continue;
798797
}
799798
}

0 commit comments

Comments
 (0)