From 188a2b03e1c0540d851ed83111d5005f98dc0022 Mon Sep 17 00:00:00 2001 From: ddobrigk Date: Wed, 20 May 2026 10:12:42 +0200 Subject: [PATCH 1/2] [Common] legacy centrality QA: add vertex Z cut --- Common/Tasks/centralityQa.cxx | 37 +++++++++++++++++++++++++++++------ 1 file changed, 31 insertions(+), 6 deletions(-) diff --git a/Common/Tasks/centralityQa.cxx b/Common/Tasks/centralityQa.cxx index 51dc8875e08..7be108d9016 100644 --- a/Common/Tasks/centralityQa.cxx +++ b/Common/Tasks/centralityQa.cxx @@ -28,6 +28,7 @@ using namespace o2::framework; struct CentralityQa { Configurable nBins{"nBins", 1050, "number of bins"}; Configurable INELgtZERO{"INELgtZERO", 1, "0 - no, 1 - yes"}; + Configurable vertexZcut{"vertexZcut", 10, "vertex-Z position cut (absolute value in cm)"}; OutputObj hCentRun2V0M{TH1F("hCentRun2V0M", "V0M", nBins, 0, 105.)}; OutputObj hCentRun2V0A{TH1F("hCentRun2V0A", "V0A", nBins, 0, 105.)}; OutputObj hCentRun2SPDTks{TH1F("hCentRun2SPDTks", "SPD Tracklets", nBins, 0, 105.)}; @@ -115,8 +116,12 @@ struct CentralityQa { if (INELgtZERO && col.multNTracksPVeta1() < 1) { return; } - if (!col.sel8()) + if (!col.sel8()){ return; + } + if (std::abs(col.posZ()) > vertexZcut){ + return; + } LOGF(debug, "centFV0A=%.0f", col.centFV0A()); hCentFV0A->Fill(col.centFV0A()); hCentProfileFV0A->Fill(col.centFV0A(), col.multNTracksPVetaHalf()); @@ -128,8 +133,12 @@ struct CentralityQa { if (INELgtZERO && col.multNTracksPVeta1() < 1) { return; } - if (!col.sel8()) + if (!col.sel8()){ return; + } + if (std::abs(col.posZ()) > vertexZcut){ + return; + } LOGF(debug, "centFT0M=%.0f", col.centFT0M()); hCentFT0M->Fill(col.centFT0M()); hCentProfileFT0M->Fill(col.centFT0M(), col.multNTracksPVetaHalf()); @@ -141,8 +150,12 @@ struct CentralityQa { if (INELgtZERO && col.multNTracksPVeta1() < 1) { return; } - if (!col.sel8()) + if (!col.sel8()){ return; + } + if (std::abs(col.posZ()) > vertexZcut){ + return; + } hCentFT0A->Fill(col.centFT0A()); hCentProfileFT0A->Fill(col.centFT0A(), col.multNTracksPVetaHalf()); } @@ -153,8 +166,12 @@ struct CentralityQa { if (INELgtZERO && col.multNTracksPVeta1() < 1) { return; } - if (!col.sel8()) + if (!col.sel8()){ return; + } + if (std::abs(col.posZ()) > vertexZcut){ + return; + } hCentFT0C->Fill(col.centFT0C()); hCentProfileFT0C->Fill(col.centFT0C(), col.multNTracksPVetaHalf()); } @@ -165,8 +182,12 @@ struct CentralityQa { if (INELgtZERO && col.multNTracksPVeta1() < 1) { return; } - if (!col.sel8()) + if (!col.sel8()){ return; + } + if (std::abs(col.posZ()) > vertexZcut){ + return; + } hCentFDDM->Fill(col.centFDDM()); hCentProfileFDDM->Fill(col.centFDDM(), col.multNTracksPVetaHalf()); } @@ -177,8 +198,12 @@ struct CentralityQa { if (INELgtZERO && col.multNTracksPVeta1() < 1) { return; } - if (!col.sel8()) + if (!col.sel8()){ return; + } + if (std::abs(col.posZ()) > vertexZcut){ + return; + } hCentNTPV->Fill(col.centNTPV()); hCentProfileNTPV->Fill(col.centNTPV(), col.multNTracksPVetaHalf()); } From b3754a8ea0b000fab8ea889d611a3ce56eb4de07 Mon Sep 17 00:00:00 2001 From: ALICE Builder Date: Wed, 20 May 2026 10:21:42 +0200 Subject: [PATCH 2/2] Please consider the following formatting changes (#511) --- Common/Tasks/centralityQa.cxx | 36 +++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/Common/Tasks/centralityQa.cxx b/Common/Tasks/centralityQa.cxx index 7be108d9016..ab7bd502377 100644 --- a/Common/Tasks/centralityQa.cxx +++ b/Common/Tasks/centralityQa.cxx @@ -116,11 +116,11 @@ struct CentralityQa { if (INELgtZERO && col.multNTracksPVeta1() < 1) { return; } - if (!col.sel8()){ + if (!col.sel8()) { return; } - if (std::abs(col.posZ()) > vertexZcut){ - return; + if (std::abs(col.posZ()) > vertexZcut) { + return; } LOGF(debug, "centFV0A=%.0f", col.centFV0A()); hCentFV0A->Fill(col.centFV0A()); @@ -133,11 +133,11 @@ struct CentralityQa { if (INELgtZERO && col.multNTracksPVeta1() < 1) { return; } - if (!col.sel8()){ + if (!col.sel8()) { return; } - if (std::abs(col.posZ()) > vertexZcut){ - return; + if (std::abs(col.posZ()) > vertexZcut) { + return; } LOGF(debug, "centFT0M=%.0f", col.centFT0M()); hCentFT0M->Fill(col.centFT0M()); @@ -150,11 +150,11 @@ struct CentralityQa { if (INELgtZERO && col.multNTracksPVeta1() < 1) { return; } - if (!col.sel8()){ + if (!col.sel8()) { return; } - if (std::abs(col.posZ()) > vertexZcut){ - return; + if (std::abs(col.posZ()) > vertexZcut) { + return; } hCentFT0A->Fill(col.centFT0A()); hCentProfileFT0A->Fill(col.centFT0A(), col.multNTracksPVetaHalf()); @@ -166,11 +166,11 @@ struct CentralityQa { if (INELgtZERO && col.multNTracksPVeta1() < 1) { return; } - if (!col.sel8()){ + if (!col.sel8()) { return; } - if (std::abs(col.posZ()) > vertexZcut){ - return; + if (std::abs(col.posZ()) > vertexZcut) { + return; } hCentFT0C->Fill(col.centFT0C()); hCentProfileFT0C->Fill(col.centFT0C(), col.multNTracksPVetaHalf()); @@ -182,11 +182,11 @@ struct CentralityQa { if (INELgtZERO && col.multNTracksPVeta1() < 1) { return; } - if (!col.sel8()){ + if (!col.sel8()) { return; } - if (std::abs(col.posZ()) > vertexZcut){ - return; + if (std::abs(col.posZ()) > vertexZcut) { + return; } hCentFDDM->Fill(col.centFDDM()); hCentProfileFDDM->Fill(col.centFDDM(), col.multNTracksPVetaHalf()); @@ -198,11 +198,11 @@ struct CentralityQa { if (INELgtZERO && col.multNTracksPVeta1() < 1) { return; } - if (!col.sel8()){ + if (!col.sel8()) { return; } - if (std::abs(col.posZ()) > vertexZcut){ - return; + if (std::abs(col.posZ()) > vertexZcut) { + return; } hCentNTPV->Fill(col.centNTPV()); hCentProfileNTPV->Fill(col.centNTPV(), col.multNTracksPVetaHalf());