From 2ec77c2fd6e070782746dbc2efdc98b6be68829f Mon Sep 17 00:00:00 2001 From: romainschotter Date: Mon, 10 Nov 2025 23:37:09 +0100 Subject: [PATCH 1/3] Update strangeness-based TOF in tutorial --- .../Derived/Analysis/configuration_step3.json | 232 ++++++++--------- .../Derived/Analysis/configuration_step4.json | 238 +++++++++--------- .../Analysis/strangeness_derived_step3.cxx | 22 +- .../Analysis/strangeness_derived_step4.cxx | 33 +-- 4 files changed, 256 insertions(+), 269 deletions(-) diff --git a/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step3.json b/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step3.json index d9decaee05c..4a182b0e7b2 100644 --- a/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step3.json +++ b/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step3.json @@ -12,123 +12,123 @@ "strangenesstofpid": { "v0Calibration.qaMassWindow": "0.005", "axisP": { - "values": [ - 0, - 0, - 0.10000000149011612, - 0.20000000298023224, - 0.30000001192092896, - 0.4000000059604645, - 0.5, - 0.6000000238418579, - 0.699999988079071, - 0.800000011920929, - 0.8999999761581421, - 1, - 1.100000023841858, - 1.2000000476837158, - 1.2999999523162842, - 1.399999976158142, - 1.5, - 1.600000023841858, - 1.7000000476837158, - 1.7999999523162842, - 1.899999976158142, - 2, - 2.200000047683716, - 2.4000000953674316, - 2.5999999046325684, - 2.799999952316284, - 3, - 3.200000047683716, - 3.4000000953674316, - 3.5999999046325684, - 3.799999952316284, - 4, - 4.400000095367432, - 4.800000190734863, - 5.199999809265137, - 5.599999904632568, - 6, - 6.5, - 7, - 7.5, - 8, - 9, - 10, - 11, - 12, - 13, - 14, - 15, - 17, - 19, - 21, - 23, - 25, - 30, - 35, - 40, - 50 - ] + "values": [ + 0, + 0, + 0.10000000149011612, + 0.20000000298023224, + 0.30000001192092896, + 0.4000000059604645, + 0.5, + 0.6000000238418579, + 0.699999988079071, + 0.800000011920929, + 0.8999999761581421, + 1, + 1.100000023841858, + 1.2000000476837158, + 1.2999999523162842, + 1.399999976158142, + 1.5, + 1.600000023841858, + 1.7000000476837158, + 1.7999999523162842, + 1.899999976158142, + 2, + 2.200000047683716, + 2.4000000953674316, + 2.5999999046325684, + 2.799999952316284, + 3, + 3.200000047683716, + 3.4000000953674316, + 3.5999999046325684, + 3.799999952316284, + 4, + 4.400000095367432, + 4.800000190734863, + 5.199999809265137, + 5.599999904632568, + 6, + 6.5, + 7, + 7.5, + 8, + 9, + 10, + 11, + 12, + 13, + 14, + 15, + 17, + 19, + 21, + 23, + 25, + 30, + 35, + 40, + 50 + ] }, "axisRatioMethods": { - "values": [ - 400, - 0.8999999761581421, - 1.899999976158142 - ] + "values": [ + 400, + 0.8999999761581421, + 1.899999976158142 + ] }, "v0Calibration.qaCosPA": "0.999", "rejectUndefinedTof": "1", "v0Calibration.qaDCADau": "0.5", "axisDeltaTime": { - "values": [ - 2000, - -1000, - 1000 - ] + "values": [ + 2000, + -1000, + 1000 + ] }, "ccdb.ccdb-url": "http://alice-ccdb.cern.ch", "v0Calibration.qaTPCNSigma": "5", "ccdb.lutPath": "GLO/Param/MatLUT", "axisDeltaTimeVsPrimaryCalculation": { - "values": [ - 500, - -500, - 500 - ] + "values": [ + 500, + -500, + 500 + ] }, "axisEta": { - "values": [ - 20, - -1, - 1 - ] + "values": [ + 20, + -1, + 1 + ] }, "axisTimeLong": { - "values": [ - 3000, - -1500000, - 1500000 - ] + "values": [ + 3000, + -1500000, + 1500000 + ] }, "calculationMethod": "0", "calculateCascades": "-1", "cascadeCalibration.qaV0DCADau": "0.5", "axisNSigma": { - "values": [ - 200, - -10, - 10 - ] + "values": [ + 200, + -10, + 10 + ] }, "axisSmallP": { - "values": [ - 250, - 0, - 2.5 - ] + "values": [ + 250, + 0, + 2.5 + ] }, "manualRunNumber": "544122", "calculateV0TOFPIDs": "-1", @@ -138,38 +138,38 @@ "cascadeCalibration.qaCascDCADau": "0.5", "cascadeCalibration.qaMassWindow": "0.005", "axisBCshift": { - "values": [ - 130, - -3006569.541579235, - 237032.45348549983 - ] + "values": [ + 130, + -3006569.541579235, + 237032.45348549983 + ] }, "doBCshift": "1", - "useCustomRunNumber": "1", + "useCustomRunNumber": "0", "axisPosition": { - "values": [ - 400, - -400, - 400 - ] + "values": [ + 400, + -400, + 400 + ] }, "processStandardData": "0", "axisTime": { - "values": [ - 400, - 10000, - 50000 - ] + "values": [ + 400, + 10000, + 50000 + ] }, "calculateCascTOFPIDs": "-1", "ccdb.mVtxPath": "GLO/Calib/MeanVertex", "calculateV0TOFDebugs": "-1", "axisSnp": { - "values": [ - 220, - -1.100000023841858, - 1.100000023841858 - ] + "values": [ + 220, + -1.100000023841858, + 1.100000023841858 + ] }, "ccdb.grpmagPath": "GLO/Config/GRPMagField", "ccdb.grpPath": "GLO/GRP/GRP", @@ -209,4 +209,4 @@ "internal-dpl-aod-writer": "", "internal-dpl-aod-global-analysis-file-sink": "", "internal-dpl-injected-dummy-sink": "" -} +} \ No newline at end of file diff --git a/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step4.json b/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step4.json index d9decaee05c..d3b7adc15c5 100644 --- a/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step4.json +++ b/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step4.json @@ -12,164 +12,164 @@ "strangenesstofpid": { "v0Calibration.qaMassWindow": "0.005", "axisP": { - "values": [ - 0, - 0, - 0.10000000149011612, - 0.20000000298023224, - 0.30000001192092896, - 0.4000000059604645, - 0.5, - 0.6000000238418579, - 0.699999988079071, - 0.800000011920929, - 0.8999999761581421, - 1, - 1.100000023841858, - 1.2000000476837158, - 1.2999999523162842, - 1.399999976158142, - 1.5, - 1.600000023841858, - 1.7000000476837158, - 1.7999999523162842, - 1.899999976158142, - 2, - 2.200000047683716, - 2.4000000953674316, - 2.5999999046325684, - 2.799999952316284, - 3, - 3.200000047683716, - 3.4000000953674316, - 3.5999999046325684, - 3.799999952316284, - 4, - 4.400000095367432, - 4.800000190734863, - 5.199999809265137, - 5.599999904632568, - 6, - 6.5, - 7, - 7.5, - 8, - 9, - 10, - 11, - 12, - 13, - 14, - 15, - 17, - 19, - 21, - 23, - 25, - 30, - 35, - 40, - 50 - ] + "values": [ + 0, + 0, + 0.10000000149011612, + 0.20000000298023224, + 0.30000001192092896, + 0.4000000059604645, + 0.5, + 0.6000000238418579, + 0.699999988079071, + 0.800000011920929, + 0.8999999761581421, + 1, + 1.100000023841858, + 1.2000000476837158, + 1.2999999523162842, + 1.399999976158142, + 1.5, + 1.600000023841858, + 1.7000000476837158, + 1.7999999523162842, + 1.899999976158142, + 2, + 2.200000047683716, + 2.4000000953674316, + 2.5999999046325684, + 2.799999952316284, + 3, + 3.200000047683716, + 3.4000000953674316, + 3.5999999046325684, + 3.799999952316284, + 4, + 4.400000095367432, + 4.800000190734863, + 5.199999809265137, + 5.599999904632568, + 6, + 6.5, + 7, + 7.5, + 8, + 9, + 10, + 11, + 12, + 13, + 14, + 15, + 17, + 19, + 21, + 23, + 25, + 30, + 35, + 40, + 50 + ] }, "axisRatioMethods": { - "values": [ - 400, - 0.8999999761581421, - 1.899999976158142 - ] + "values": [ + 400, + 0.8999999761581421, + 1.899999976158142 + ] }, "v0Calibration.qaCosPA": "0.999", "rejectUndefinedTof": "1", "v0Calibration.qaDCADau": "0.5", "axisDeltaTime": { - "values": [ - 2000, - -1000, - 1000 - ] + "values": [ + 2000, + -1000, + 1000 + ] }, "ccdb.ccdb-url": "http://alice-ccdb.cern.ch", "v0Calibration.qaTPCNSigma": "5", "ccdb.lutPath": "GLO/Param/MatLUT", "axisDeltaTimeVsPrimaryCalculation": { - "values": [ - 500, - -500, - 500 - ] + "values": [ + 500, + -500, + 500 + ] }, "axisEta": { - "values": [ - 20, - -1, - 1 - ] + "values": [ + 20, + -1, + 1 + ] }, "axisTimeLong": { - "values": [ - 3000, - -1500000, - 1500000 - ] + "values": [ + 3000, + -1500000, + 1500000 + ] }, "calculationMethod": "0", - "calculateCascades": "-1", + "calculateCascades": "1", "cascadeCalibration.qaV0DCADau": "0.5", "axisNSigma": { - "values": [ - 200, - -10, - 10 - ] + "values": [ + 200, + -10, + 10 + ] }, "axisSmallP": { - "values": [ - 250, - 0, - 2.5 - ] + "values": [ + 250, + 0, + 2.5 + ] }, "manualRunNumber": "544122", - "calculateV0TOFPIDs": "-1", + "calculateV0TOFPIDs": "1", "cascadeCalibration.qaCascCosPA": "0.995", "processDerivedData": "1", "calculateV0s": "-1", "cascadeCalibration.qaCascDCADau": "0.5", "cascadeCalibration.qaMassWindow": "0.005", "axisBCshift": { - "values": [ - 130, - -3006569.541579235, - 237032.45348549983 - ] + "values": [ + 130, + -3006569.541579235, + 237032.45348549983 + ] }, "doBCshift": "1", - "useCustomRunNumber": "1", + "useCustomRunNumber": "0", "axisPosition": { - "values": [ - 400, - -400, - 400 - ] + "values": [ + 400, + -400, + 400 + ] }, "processStandardData": "0", "axisTime": { - "values": [ - 400, - 10000, - 50000 - ] + "values": [ + 400, + 10000, + 50000 + ] }, - "calculateCascTOFPIDs": "-1", + "calculateCascTOFPIDs": "1", "ccdb.mVtxPath": "GLO/Calib/MeanVertex", - "calculateV0TOFDebugs": "-1", + "calculateV0TOFDebugs": "1", "axisSnp": { - "values": [ - 220, - -1.100000023841858, - 1.100000023841858 - ] + "values": [ + 220, + -1.100000023841858, + 1.100000023841858 + ] }, "ccdb.grpmagPath": "GLO/Config/GRPMagField", "ccdb.grpPath": "GLO/GRP/GRP", diff --git a/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step3.cxx b/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step3.cxx index 1894aa39146..12d3e405447 100644 --- a/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step3.cxx +++ b/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step3.cxx @@ -15,14 +15,12 @@ /// \author Nepeivoda Roman (roman.nepeivoda@cern.ch) /// \author Chiara De Martin (chiara.de.martin@cern.ch) +#include "Framework/runDataProcessing.h" +#include "Framework/AnalysisTask.h" +#include "Common/DataModel/EventSelection.h" #include "PWGLF/DataModel/LFStrangenessPIDTables.h" #include "PWGLF/DataModel/LFStrangenessTables.h" -#include "Common/DataModel/EventSelection.h" - -#include "Framework/AnalysisTask.h" -#include "Framework/runDataProcessing.h" - using namespace o2; using namespace o2::framework; using namespace o2::framework::expressions; @@ -117,7 +115,7 @@ struct strangeness_derived_tutorial { using dauTracks = soa::Join; void process(soa::Filtered>::iterator const& collision, - soa::Filtered> const& Cascades, + soa::Filtered> const& Cascades, dauTracks const&) { // Fill the event counter @@ -167,7 +165,7 @@ struct strangeness_derived_tutorial { bool xiPassTOFSelection = true; bool omegaPassTOFSelection = true; if (casc.sign() < 0) { - if (posDaughterTrackCasc.hasTOF()) { + if (casc.positiveHasTOF()) { if (std::abs(casc.tofNSigmaXiLaPr()) > NSigmaTOFProton) { xiPassTOFSelection &= false; } @@ -175,7 +173,7 @@ struct strangeness_derived_tutorial { omegaPassTOFSelection &= false; } } - if (negDaughterTrackCasc.hasTOF()) { + if (casc.negativeHasTOF()) { if (std::abs(casc.tofNSigmaXiLaPi()) > NSigmaTOFPion) { xiPassTOFSelection &= false; } @@ -184,7 +182,7 @@ struct strangeness_derived_tutorial { } } } else { - if (posDaughterTrackCasc.hasTOF()) { + if (casc.positiveHasTOF()) { if (std::abs(casc.tofNSigmaXiLaPi()) > NSigmaTOFPion) { xiPassTOFSelection &= false; } @@ -192,7 +190,7 @@ struct strangeness_derived_tutorial { omegaPassTOFSelection &= false; } } - if (negDaughterTrackCasc.hasTOF()) { + if (casc.negativeHasTOF()) { if (std::abs(casc.tofNSigmaXiLaPr()) > NSigmaTOFProton) { xiPassTOFSelection &= false; } @@ -202,7 +200,7 @@ struct strangeness_derived_tutorial { } } - if (bachDaughterTrackCasc.hasTOF()) { + if (casc.bachelorHasTOF()) { if (std::abs(casc.tofNSigmaXiPi()) > NSigmaTOFPion) { xiPassTOFSelection &= false; } @@ -220,7 +218,7 @@ struct strangeness_derived_tutorial { rXi.fill(HIST("hCascDCAV0Daughters"), casc.dcaV0daughters()); rXi.fill(HIST("hCascCosPA"), casc.casccosPA(collision.posX(), collision.posY(), collision.posZ())); } - if (std::abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case + if (std::abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case if (std::abs(casc.mXi() - o2::constants::physics::MassXiMinus) > cascadesetting_competingmassrej) { // competing mass rejection, only in case of Omega rOmega.fill(HIST("hMassOmegaSelected"), casc.mOmega()); if (omegaPassTOFSelection) { diff --git a/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step4.cxx b/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step4.cxx index 714f30f4c84..15c62df40a4 100644 --- a/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step4.cxx +++ b/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step4.cxx @@ -15,14 +15,12 @@ /// \author Nepeivoda Roman (roman.nepeivoda@cern.ch) /// \author Chiara De Martin (chiara.de.martin@cern.ch) +#include "Framework/runDataProcessing.h" +#include "Framework/AnalysisTask.h" +#include "Common/DataModel/EventSelection.h" #include "PWGLF/DataModel/LFStrangenessPIDTables.h" #include "PWGLF/DataModel/LFStrangenessTables.h" -#include "Common/DataModel/EventSelection.h" - -#include "Framework/AnalysisTask.h" -#include "Framework/runDataProcessing.h" - using namespace o2; using namespace o2::framework; using namespace o2::framework::expressions; @@ -135,7 +133,7 @@ struct strangeness_derived_tutorial { using dauTracks = soa::Join; void processRecMC(soa::Filtered>::iterator const& collision, - soa::Filtered> const& Cascades, + soa::Filtered> const& Cascades, dauTracks const&, aod::CascMCCores const& /*cascmccores*/) { @@ -186,7 +184,7 @@ struct strangeness_derived_tutorial { bool xiPassTOFSelection = true; bool omegaPassTOFSelection = true; if (casc.sign() < 0) { - if (posDaughterTrackCasc.hasTOF()) { + if (casc.positiveHasTOF()) { if (std::abs(casc.tofNSigmaXiLaPr()) > NSigmaTOFProton) { xiPassTOFSelection &= false; } @@ -194,7 +192,7 @@ struct strangeness_derived_tutorial { omegaPassTOFSelection &= false; } } - if (negDaughterTrackCasc.hasTOF()) { + if (casc.negativeHasTOF()) { if (std::abs(casc.tofNSigmaXiLaPi()) > NSigmaTOFPion) { xiPassTOFSelection &= false; } @@ -203,7 +201,7 @@ struct strangeness_derived_tutorial { } } } else { - if (posDaughterTrackCasc.hasTOF()) { + if (casc.positiveHasTOF()) { if (std::abs(casc.tofNSigmaXiLaPi()) > NSigmaTOFPion) { xiPassTOFSelection &= false; } @@ -211,7 +209,7 @@ struct strangeness_derived_tutorial { omegaPassTOFSelection &= false; } } - if (negDaughterTrackCasc.hasTOF()) { + if (casc.negativeHasTOF()) { if (std::abs(casc.tofNSigmaXiLaPr()) > NSigmaTOFProton) { xiPassTOFSelection &= false; } @@ -221,16 +219,7 @@ struct strangeness_derived_tutorial { } } - if (bachDaughterTrackCasc.hasTOF()) { - if (std::abs(casc.tofNSigmaXiPi()) > NSigmaTOFPion) { - xiPassTOFSelection &= false; - } - if (std::abs(casc.tofNSigmaOmKa()) > NSigmaTOFKaon) { - omegaPassTOFSelection &= false; - } - } - - if (bachDaughterTrackCasc.hasTOF()) { + if (casc.bachelorHasTOF()) { if (std::abs(casc.tofNSigmaXiPi()) > NSigmaTOFPion) { xiPassTOFSelection &= false; } @@ -249,7 +238,7 @@ struct strangeness_derived_tutorial { rXi.fill(HIST("hCascDCAV0Daughters"), casc.dcaV0daughters()); rXi.fill(HIST("hCascCosPA"), casc.casccosPA(collision.posX(), collision.posY(), collision.posZ())); } - if (std::abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case + if (std::abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case if (std::abs(casc.mXi() - o2::constants::physics::MassXiMinus) > cascadesetting_competingmassrej) { // competing mass rejection, only in case of Omega rOmega.fill(HIST("hMassOmegaSelected"), casc.mOmega()); if (omegaPassTOFSelection) { @@ -279,7 +268,7 @@ struct strangeness_derived_tutorial { } } if (std::abs(cascmccore.pdgCode()) == PDG_t::kOmegaMinus) { - if (std::abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case + if (std::abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case if (std::abs(casc.mXi() - o2::constants::physics::MassXiMinus) > cascadesetting_competingmassrej) { // competing mass rejection, only in case of Omega rOmega.fill(HIST("hMassOmegaTrueRec"), casc.mOmega()); rOmega.fill(HIST("hPtOmegaTrueRec"), casc.pt()); From a1d9b22d893b3397117f7a6cea4e74ada0e2aa13 Mon Sep 17 00:00:00 2001 From: romainschotter Date: Mon, 10 Nov 2025 23:40:26 +0100 Subject: [PATCH 2/3] Remove old PbPb tutorial --- .../Strangeness/PbPb/Analysis/CMakeLists.txt | 41 --- .../Strangeness/PbPb/Analysis/run_skeleton.sh | 24 -- .../Strangeness/PbPb/Analysis/run_step0.sh | 24 -- .../Strangeness/PbPb/Analysis/run_step1.sh | 24 -- .../Strangeness/PbPb/Analysis/run_step2.sh | 24 -- .../Strangeness/PbPb/Analysis/run_step3.sh | 24 -- .../Strangeness/PbPb/Analysis/run_step4.sh | 24 -- .../Analysis/strangeness_pbpb_skeleton.cxx | 67 ---- .../PbPb/Analysis/strangeness_pbpb_step0.cxx | 86 ----- .../PbPb/Analysis/strangeness_pbpb_step1.cxx | 146 -------- .../PbPb/Analysis/strangeness_pbpb_step2.cxx | 182 ---------- .../PbPb/Analysis/strangeness_pbpb_step3.cxx | 243 ------------- .../PbPb/Analysis/strangeness_pbpb_step4.cxx | 324 ------------------ .../PWGLF/Strangeness/PbPb/CMakeLists.txt | 13 - .../PbPb/DerivedDataProduction/Data/run.sh | 42 --- .../PbPb/DerivedDataProduction/MC/runMC.sh | 44 --- 16 files changed, 1332 deletions(-) delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/Analysis/CMakeLists.txt delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_skeleton.sh delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step0.sh delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step1.sh delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step2.sh delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step3.sh delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step4.sh delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_skeleton.cxx delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step0.cxx delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step1.cxx delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step2.cxx delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step3.cxx delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step4.cxx delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/CMakeLists.txt delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/DerivedDataProduction/Data/run.sh delete mode 100644 Tutorials/PWGLF/Strangeness/PbPb/DerivedDataProduction/MC/runMC.sh diff --git a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/CMakeLists.txt b/Tutorials/PWGLF/Strangeness/PbPb/Analysis/CMakeLists.txt deleted file mode 100644 index d050dc59b47..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/CMakeLists.txt +++ /dev/null @@ -1,41 +0,0 @@ -# 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. - -o2physics_add_dpl_workflow(strangeness-pbpb-skeleton - SOURCES strangeness_pbpb_skeleton.cxx - PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore - COMPONENT_NAME AnalysisTutorial) - -o2physics_add_dpl_workflow(strangeness-pbpb-step0 - SOURCES strangeness_pbpb_step0.cxx - PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore - COMPONENT_NAME AnalysisTutorial) - -o2physics_add_dpl_workflow(strangeness-pbpb-step1 - SOURCES strangeness_pbpb_step1.cxx - PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore - COMPONENT_NAME AnalysisTutorial) - -o2physics_add_dpl_workflow(strangeness-pbpb-step2 - SOURCES strangeness_pbpb_step2.cxx - PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore - COMPONENT_NAME AnalysisTutorial) - -o2physics_add_dpl_workflow(strangeness-pbpb-step3 - SOURCES strangeness_pbpb_step3.cxx - PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore - COMPONENT_NAME AnalysisTutorial) - -o2physics_add_dpl_workflow(strangeness-pbpb-step4 - SOURCES strangeness_pbpb_step4.cxx - PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore - COMPONENT_NAME AnalysisTutorial) - diff --git a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_skeleton.sh b/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_skeleton.sh deleted file mode 100644 index 9327402771f..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_skeleton.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/bash -# log file where the terminal output will be saved -STEP="skeleton" -LOGFILE="log-${STEP}.txt" - -#directory of this script -DIR_THIS=$PWD - -OPTION="-b --configuration json://configuration_skeleton.json" - -o2-analysistutorial-lf-strangeness-pbpb-skeleton "${OPTION}" --aod-file @input_data.txt > "$LOGFILE" 2>&1 - -# report status -rc=$? -if [ $rc -eq 0 ]; then - echo "No problems!" - mkdir -p "${DIR_THIS}/results/${STEP}" - mv AnalysisResults.root "${DIR_THIS}/results/${STEP}/AnalysisResults.root" - mv dpl-config.json "${DIR_THIS}/results/${STEP}/${STEP}.json" -else - echo "Error: Exit code ${rc}" - echo "Check the log file ${LOGFILE}" - exit ${rc} -fi \ No newline at end of file diff --git a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step0.sh b/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step0.sh deleted file mode 100644 index bcfeb9ab890..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step0.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/bash -# log file where the terminal output will be saved -STEP="0" -LOGFILE="log-${STEP}.txt" - -#directory of this script -DIR_THIS=$PWD - -OPTION="-b --configuration json://configuration_step0.json" - -o2-analysis-lf-cascadespawner "${OPTION}" | o2-analysistutorial-lf-strangeness-pbpb-step0 "${OPTION}" --aod-file @input_data.txt > "$LOGFILE" 2>&1 - -# report status -rc=$? -if [ $rc -eq 0 ]; then - echo "No problems!" - mkdir -p "${DIR_THIS}/results/step${STEP}" - mv AnalysisResults.root "${DIR_THIS}/results/step${STEP}/AnalysisResults.root" - mv dpl-config.json "${DIR_THIS}/results/step${STEP}/step${STEP}.json" -else - echo "Error: Exit code ${rc}" - echo "Check the log file ${LOGFILE}" - exit ${rc} -fi \ No newline at end of file diff --git a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step1.sh b/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step1.sh deleted file mode 100644 index 826f0ea1421..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step1.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/bash -# log file where the terminal output will be saved -STEP="1" -LOGFILE="log-${STEP}.txt" - -#directory of this script -DIR_THIS=$PWD - -OPTION="-b --configuration json://configuration_step1.json" - -o2-analysis-lf-cascadespawner "${OPTION}" | o2-analysistutorial-lf-strangeness-pbpb-step1 "${OPTION}" --aod-file @input_data.txt > "$LOGFILE" 2>&1 - -# report status -rc=$? -if [ $rc -eq 0 ]; then - echo "No problems!" - mkdir -p "${DIR_THIS}/results/step${STEP}" - mv AnalysisResults.root "${DIR_THIS}/results/step${STEP}/AnalysisResults.root" - mv dpl-config.json "${DIR_THIS}/results/step${STEP}/step${STEP}.json" -else - echo "Error: Exit code ${rc}" - echo "Check the log file ${LOGFILE}" - exit ${rc} -fi \ No newline at end of file diff --git a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step2.sh b/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step2.sh deleted file mode 100644 index aca62bad45e..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step2.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/bash -# log file where the terminal output will be saved -STEP="2" -LOGFILE="log-${STEP}.txt" - -#directory of this script -DIR_THIS=$PWD - -OPTION="-b --configuration json://configuration_step2.json" - -o2-analysis-lf-cascadespawner "${OPTION}" | o2-analysistutorial-lf-strangeness-pbpb-step2 "${OPTION}" --aod-file @input_data.txt > "$LOGFILE" 2>&1 - -# report status -rc=$? -if [ $rc -eq 0 ]; then - echo "No problems!" - mkdir -p "${DIR_THIS}/results/step${STEP}" - mv AnalysisResults.root "${DIR_THIS}/results/step${STEP}/AnalysisResults.root" - mv dpl-config.json "${DIR_THIS}/results/step${STEP}/step${STEP}.json" -else - echo "Error: Exit code ${rc}" - echo "Check the log file ${LOGFILE}" - exit ${rc} -fi \ No newline at end of file diff --git a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step3.sh b/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step3.sh deleted file mode 100644 index 580b3c0c17f..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step3.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/bash -# log file where the terminal output will be saved -STEP="3" -LOGFILE="log-${STEP}.txt" - -#directory of this script -DIR_THIS=$PWD - -OPTION="-b --configuration json://configuration_step3.json" - -o2-analysis-lf-cascadepid "${OPTION}" | o2-analysis-lf-cascadespawner "${OPTION}" | o2-analysistutorial-lf-strangeness-pbpb-step3 "${OPTION}" --aod-file @input_data.txt > "$LOGFILE" 2>&1 - -# report status -rc=$? -if [ $rc -eq 0 ]; then - echo "No problems!" - mkdir -p "${DIR_THIS}/results/step${STEP}" - mv AnalysisResults.root "${DIR_THIS}/results/step${STEP}/AnalysisResults.root" - mv dpl-config.json "${DIR_THIS}/results/step${STEP}/step${STEP}.json" -else - echo "Error: Exit code ${rc}" - echo "Check the log file ${LOGFILE}" - exit ${rc} -fi diff --git a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step4.sh b/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step4.sh deleted file mode 100644 index 08f929b3fa8..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/run_step4.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/bash -# log file where the terminal output will be saved -STEP="4" -LOGFILE="log-${STEP}.txt" - -#directory of this script -DIR_THIS=$PWD - -OPTION="-b --configuration json://configuration_step4.json" - -o2-analysis-lf-cascadepid "${OPTION}" | o2-analysis-lf-cascadespawner "${OPTION}" | o2-analysistutorial-lf-strangeness-pbpb-step4 "${OPTION}" --aod-file @input_data.txt > "$LOGFILE" 2>&1 - -# report status -rc=$? -if [ $rc -eq 0 ]; then - echo "No problems!" - mkdir -p "${DIR_THIS}/results/step${STEP}" - mv AnalysisResults.root "${DIR_THIS}/results/step${STEP}/AnalysisResults.root" - mv dpl-config.json "${DIR_THIS}/results/step${STEP}/step${STEP}.json" -else - echo "Error: Exit code ${rc}" - echo "Check the log file ${LOGFILE}" - exit ${rc} -fi \ No newline at end of file diff --git a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_skeleton.cxx b/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_skeleton.cxx deleted file mode 100644 index 788aaead7ae..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_skeleton.cxx +++ /dev/null @@ -1,67 +0,0 @@ -// 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. -/// -/// \brief Step4 of the Strangeness tutorial -/// \author Romain Schotter -/// based on the original codes from: -/// \author Nepeivoda Roman (roman.nepeivoda@cern.ch) -/// \author Chiara De Martin (chiara.de.martin@cern.ch) - -#include "Framework/runDataProcessing.h" -#include "Framework/AnalysisTask.h" -#include "Common/DataModel/EventSelection.h" -#include "PWGLF/DataModel/LFStrangenessTables.h" -#include "Framework/O2DatabasePDGPlugin.h" - -using namespace o2; -using namespace o2::framework; -using namespace o2::framework::expressions; - -struct strangeness_pbpb_tutorial { - // Histograms are defined with HistogramRegistry - HistogramRegistry rEventSelection{"eventSelection", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - - // Configurable for histograms - Configurable nBins{"nBins", 100, "N bins in all histos"}; - - // Configurable for event selection - Configurable cutzvertex{"cutzvertex", 10.0f, "Accepted z-vertex range (cm)"}; - - // PDG data base - Service pdgDB; - - void init(InitContext const&) - { - // Axes - AxisSpec vertexZAxis = {nBins, -15., 15., "vrtx_{Z} [cm]"}; - - // Histograms - // Event selection - rEventSelection.add("hVertexZRec", "hVertexZRec", {HistType::kTH1F, {vertexZAxis}}); - } - - // Defining filters for events (event selection) - // Processed events will be already fulfilling the event selection requirements - Filter eventFilter = (o2::aod::evsel::sel8 == true); - Filter posZFilter = (nabs(o2::aod::collision::posZ) < cutzvertex); - - void process(soa::Filtered>::iterator const& collision) - { - // Fill the event counter - rEventSelection.fill(HIST("hVertexZRec"), collision.posZ()); - } -}; - -WorkflowSpec defineDataProcessing(ConfigContext const& cfgc) -{ - return WorkflowSpec{ - adaptAnalysisTask(cfgc)}; -} diff --git a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step0.cxx b/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step0.cxx deleted file mode 100644 index b0e595246d7..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step0.cxx +++ /dev/null @@ -1,86 +0,0 @@ -// 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. -/// -/// \brief Step4 of the Strangeness tutorial -/// \author Romain Schotter -/// based on the original codes from: -/// \author Nepeivoda Roman (roman.nepeivoda@cern.ch) -/// \author Chiara De Martin (chiara.de.martin@cern.ch) - -#include "Framework/runDataProcessing.h" -#include "Framework/AnalysisTask.h" -#include "Common/DataModel/EventSelection.h" -#include "PWGLF/DataModel/LFStrangenessTables.h" -#include "Framework/O2DatabasePDGPlugin.h" - -using namespace o2; -using namespace o2::framework; -using namespace o2::framework::expressions; - -// STEP 0 -// Starting point: loop over all cascades and fill invariant mass histogram - -struct strangeness_pbpb_tutorial { - // Histograms are defined with HistogramRegistry - HistogramRegistry rEventSelection{"eventSelection", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - HistogramRegistry rXi{"xi", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - HistogramRegistry rOmega{"omega", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - - // Configurable for histograms - Configurable nBins{"nBins", 100, "N bins in all histos"}; - - // Configurable for event selection - Configurable cutzvertex{"cutzvertex", 10.0f, "Accepted z-vertex range (cm)"}; - - // PDG data base - Service pdgDB; - - void init(InitContext const&) - { - // Axes - AxisSpec XiMassAxis = {100, 1.28f, 1.36f, "#it{M}_{inv} [GeV/#it{c}^{2}]"}; - AxisSpec OmegaMassAxis = {100, 1.63f, 1.7f, "#it{M}_{inv} [GeV/#it{c}^{2}]"}; - AxisSpec vertexZAxis = {nBins, -15., 15., "vrtx_{Z} [cm]"}; - - // Histograms - // Event selection - rEventSelection.add("hVertexZRec", "hVertexZRec", {HistType::kTH1F, {vertexZAxis}}); - - // Xi/Omega reconstruction - rXi.add("hMassXi", "hMassXi", {HistType::kTH1F, {XiMassAxis}}); - - rOmega.add("hMassOmega", "hMassOmega", {HistType::kTH1F, {OmegaMassAxis}}); - } - - // Defining filters for events (event selection) - // Processed events will be already fulfilling the event selection requirements - Filter eventFilter = (o2::aod::evsel::sel8 == true); - Filter posZFilter = (nabs(o2::aod::collision::posZ) < cutzvertex); - - void process(soa::Filtered>::iterator const& collision, - aod::CascCores const& Cascades) - { - // Fill the event counter - rEventSelection.fill(HIST("hVertexZRec"), collision.posZ()); - - // Cascades - for (const auto& casc : Cascades) { - rXi.fill(HIST("hMassXi"), casc.mXi()); - rOmega.fill(HIST("hMassOmega"), casc.mOmega()); - } - } -}; - -WorkflowSpec defineDataProcessing(ConfigContext const& cfgc) -{ - return WorkflowSpec{ - adaptAnalysisTask(cfgc)}; -} diff --git a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step1.cxx b/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step1.cxx deleted file mode 100644 index 836be98b240..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step1.cxx +++ /dev/null @@ -1,146 +0,0 @@ -// 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. -/// -/// \brief Step4 of the Strangeness tutorial -/// \author Romain Schotter -/// based on the original codes from: -/// \author Nepeivoda Roman (roman.nepeivoda@cern.ch) -/// \author Chiara De Martin (chiara.de.martin@cern.ch) - -#include "Framework/runDataProcessing.h" -#include "Framework/AnalysisTask.h" -#include "Common/DataModel/EventSelection.h" -#include "PWGLF/DataModel/LFStrangenessTables.h" -#include "Framework/O2DatabasePDGPlugin.h" - -using namespace o2; -using namespace o2::framework; -using namespace o2::framework::expressions; - -// STEP 0 -// Starting point: loop over all cascades and fill invariant mass histogram -// STEP 1 -// Apply selections on topological variables of Cascades - -struct strangeness_pbpb_tutorial { - // Histograms are defined with HistogramRegistry - HistogramRegistry rEventSelection{"eventSelection", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - HistogramRegistry rXi{"xi", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - HistogramRegistry rOmega{"omega", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - - // Configurable for histograms - Configurable nBins{"nBins", 100, "N bins in all histos"}; - - // Configurable for event selection - Configurable cutzvertex{"cutzvertex", 10.0f, "Accepted z-vertex range (cm)"}; - - // Configurable parameters for cascade selection - Configurable cascadesetting_cospa{"cascadesetting_cospa", 0.98, "Casc CosPA"}; - Configurable cascadesetting_v0cospa{"cascadesetting_v0cospa", 0.97, "V0 CosPA"}; - Configurable cascadesetting_dcacascdau{"cascadesetting_dcacascdau", 1.0, "DCA cascade daughters"}; - Configurable cascadesetting_dcav0dau{"cascadesetting_dcav0dau", 1.0, "DCA v0 daughters"}; - Configurable cascadesetting_dcabachtopv{"cascadesetting_dcabachtopv", 0.06, "DCA bachelor to PV"}; - Configurable cascadesetting_dcapostopv{"cascadesetting_dcapostopv", 0.06, "DCA positive to PV"}; - Configurable cascadesetting_dcanegtopv{"cascadesetting_dcanegtopv", 0.06, "DCA negative to PV"}; - Configurable cascadesetting_mindcav0topv{"cascadesetting_mindcav0topv", 0.01, "minimum V0 DCA to PV"}; - Configurable cascadesetting_cascradius{"cascadesetting_cascradius", 0.5, "cascradius"}; - Configurable cascadesetting_v0radius{"cascadesetting_v0radius", 1.2, "v0radius"}; - Configurable cascadesetting_v0masswindow{"cascadesetting_v0masswindow", 0.01, "v0 mass window"}; - Configurable cascadesetting_competingmassrej{"cascadesetting_competingmassrej", 0.008, "Competing mass rejection"}; - - // PDG data base - Service pdgDB; - - void init(InitContext const&) - { - // Axes - AxisSpec XiMassAxis = {100, 1.28f, 1.36f, "#it{M}_{inv} [GeV/#it{c}^{2}]"}; - AxisSpec OmegaMassAxis = {100, 1.63f, 1.7f, "#it{M}_{inv} [GeV/#it{c}^{2}]"}; - AxisSpec vertexZAxis = {nBins, -15., 15., "vrtx_{Z} [cm]"}; - - // Histograms - // Event selection - rEventSelection.add("hVertexZRec", "hVertexZRec", {HistType::kTH1F, {vertexZAxis}}); - - // Xi/Omega reconstruction - rXi.add("hMassXi", "hMassXi", {HistType::kTH1F, {XiMassAxis}}); - rXi.add("hMassXiSelected", "hMassXiSelected", {HistType::kTH1F, {XiMassAxis}}); - - rOmega.add("hMassOmega", "hMassOmega", {HistType::kTH1F, {OmegaMassAxis}}); - rOmega.add("hMassOmegaSelected", "hMassOmegaSelected", {HistType::kTH1F, {OmegaMassAxis}}); - - // Xi/Omega topological cuts - rXi.add("hCascDCAV0Daughters", "hCascDCAV0Daughters", {HistType::kTH1F, {{55, 0.0f, 2.2f}}}); - rXi.add("hCascCosPA", "hCascCosPA", {HistType::kTH1F, {{100, 0.95f, 1.f}}}); - - rOmega.add("hCascDCAV0Daughters", "hCascDCAV0Daughters", {HistType::kTH1F, {{55, 0.0f, 2.2f}}}); - rOmega.add("hCascCosPA", "hCascCosPA", {HistType::kTH1F, {{100, 0.95f, 1.f}}}); - } - - // Defining filters for events (event selection) - // Processed events will be already fulfilling the event selection requirements - Filter eventFilter = (o2::aod::evsel::sel8 == true); - Filter posZFilter = (nabs(o2::aod::collision::posZ) < cutzvertex); - - // Filters on Cascades - // Cannot filter on dynamic columns - Filter preFilterCascades = (aod::cascdata::dcaV0daughters < cascadesetting_dcav0dau && - nabs(aod::cascdata::dcapostopv) > cascadesetting_dcapostopv && - nabs(aod::cascdata::dcanegtopv) > cascadesetting_dcanegtopv && - nabs(aod::cascdata::dcabachtopv) > cascadesetting_dcabachtopv && - aod::cascdata::dcacascdaughters < cascadesetting_dcacascdau); - - void process(soa::Filtered>::iterator const& collision, - soa::Filtered> const& Cascades) - { - // Fill the event counter - rEventSelection.fill(HIST("hVertexZRec"), collision.posZ()); - - // Cascades - for (const auto& casc : Cascades) { - rXi.fill(HIST("hMassXi"), casc.mXi()); - rOmega.fill(HIST("hMassOmega"), casc.mOmega()); - - // Cut on dynamic columns - if (casc.casccosPA(collision.posX(), collision.posY(), collision.posZ()) < cascadesetting_cospa) - continue; - if (casc.v0cosPA(collision.posX(), collision.posY(), collision.posZ()) < cascadesetting_v0cospa) - continue; - if (TMath::Abs(casc.mLambda() - pdgDB->Mass(3122)) > cascadesetting_v0masswindow) - continue; - if (casc.dcav0topv(collision.posX(), collision.posY(), collision.posZ()) < cascadesetting_mindcav0topv) - continue; - if (casc.cascradius() < cascadesetting_cascradius) - continue; - if (casc.v0radius() < cascadesetting_v0radius) - continue; - - // Fill histograms! (if possible) - rXi.fill(HIST("hMassXiSelected"), casc.mXi()); - - rXi.fill(HIST("hCascDCAV0Daughters"), casc.dcaV0daughters()); - rXi.fill(HIST("hCascCosPA"), casc.casccosPA(collision.posX(), collision.posY(), collision.posZ())); - - if (TMath::Abs(casc.mXi() - pdgDB->Mass(3312)) > cascadesetting_competingmassrej) { // competing mass rejection, only in case of Omega - rOmega.fill(HIST("hMassOmegaSelected"), casc.mOmega()); - - rOmega.fill(HIST("hCascDCAV0Daughters"), casc.dcaV0daughters()); - rOmega.fill(HIST("hCascCosPA"), casc.casccosPA(collision.posX(), collision.posY(), collision.posZ())); - } - } - } -}; - -WorkflowSpec defineDataProcessing(ConfigContext const& cfgc) -{ - return WorkflowSpec{ - adaptAnalysisTask(cfgc)}; -} diff --git a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step2.cxx b/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step2.cxx deleted file mode 100644 index 1558bb78052..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step2.cxx +++ /dev/null @@ -1,182 +0,0 @@ -// 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. -/// -/// \brief Step4 of the Strangeness tutorial -/// \author Romain Schotter -/// based on the original codes from: -/// \author Nepeivoda Roman (roman.nepeivoda@cern.ch) -/// \author Chiara De Martin (chiara.de.martin@cern.ch) - -#include "Framework/runDataProcessing.h" -#include "Framework/AnalysisTask.h" -#include "Common/DataModel/EventSelection.h" -#include "PWGLF/DataModel/LFStrangenessPIDTables.h" -#include "PWGLF/DataModel/LFStrangenessTables.h" -#include "Framework/O2DatabasePDGPlugin.h" - -using namespace o2; -using namespace o2::framework; -using namespace o2::framework::expressions; - -// STEP 0 -// Starting point: loop over all cascades and fill invariant mass histogram -// STEP 1 -// Apply selections on topological variables of Cascades -// STEP 2 -// Apply TPC PID selections on cascade daughter tracks - -struct strangeness_pbpb_tutorial { - // Histograms are defined with HistogramRegistry - HistogramRegistry rEventSelection{"eventSelection", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - HistogramRegistry rXi{"xi", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - HistogramRegistry rOmega{"omega", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - - // Configurable for histograms - Configurable nBins{"nBins", 100, "N bins in all histos"}; - - // Configurable for event selection - Configurable cutzvertex{"cutzvertex", 10.0f, "Accepted z-vertex range (cm)"}; - - // Configurable parameters for cascade selection - Configurable cascadesetting_cospa{"cascadesetting_cospa", 0.98, "Casc CosPA"}; - Configurable cascadesetting_v0cospa{"cascadesetting_v0cospa", 0.97, "V0 CosPA"}; - Configurable cascadesetting_dcacascdau{"cascadesetting_dcacascdau", 1.0, "DCA cascade daughters"}; - Configurable cascadesetting_dcav0dau{"cascadesetting_dcav0dau", 1.0, "DCA v0 daughters"}; - Configurable cascadesetting_dcabachtopv{"cascadesetting_dcabachtopv", 0.06, "DCA bachelor to PV"}; - Configurable cascadesetting_dcapostopv{"cascadesetting_dcapostopv", 0.06, "DCA positive to PV"}; - Configurable cascadesetting_dcanegtopv{"cascadesetting_dcanegtopv", 0.06, "DCA negative to PV"}; - Configurable cascadesetting_mindcav0topv{"cascadesetting_mindcav0topv", 0.01, "minimum V0 DCA to PV"}; - Configurable cascadesetting_cascradius{"cascadesetting_cascradius", 0.5, "cascradius"}; - Configurable cascadesetting_v0radius{"cascadesetting_v0radius", 1.2, "v0radius"}; - Configurable cascadesetting_v0masswindow{"cascadesetting_v0masswindow", 0.01, "v0 mass window"}; - Configurable cascadesetting_competingmassrej{"cascadesetting_competingmassrej", 0.008, "Competing mass rejection"}; - - // Configurable parameters for PID selection - Configurable NSigmaTPCPion{"NSigmaTPCPion", 4, "NSigmaTPCPion"}; - Configurable NSigmaTPCKaon{"NSigmaTPCKaon", 4, "NSigmaTPCKaon"}; - Configurable NSigmaTPCProton{"NSigmaTPCProton", 4, "NSigmaTPCProton"}; - - // PDG data base - Service pdgDB; - - void init(InitContext const&) - { - // Axes - AxisSpec XiMassAxis = {100, 1.28f, 1.36f, "#it{M}_{inv} [GeV/#it{c}^{2}]"}; - AxisSpec OmegaMassAxis = {100, 1.63f, 1.7f, "#it{M}_{inv} [GeV/#it{c}^{2}]"}; - AxisSpec vertexZAxis = {nBins, -15., 15., "vrtx_{Z} [cm]"}; - - // Histograms - // Event selection - rEventSelection.add("hVertexZRec", "hVertexZRec", {HistType::kTH1F, {vertexZAxis}}); - - // Xi/Omega reconstruction - rXi.add("hMassXi", "hMassXi", {HistType::kTH1F, {XiMassAxis}}); - rXi.add("hMassXiSelected", "hMassXiSelected", {HistType::kTH1F, {XiMassAxis}}); - - rOmega.add("hMassOmega", "hMassOmega", {HistType::kTH1F, {OmegaMassAxis}}); - rOmega.add("hMassOmegaSelected", "hMassOmegaSelected", {HistType::kTH1F, {OmegaMassAxis}}); - - // Xi/Omega topological cuts - rXi.add("hCascDCAV0Daughters", "hCascDCAV0Daughters", {HistType::kTH1F, {{55, 0.0f, 2.2f}}}); - rXi.add("hCascCosPA", "hCascCosPA", {HistType::kTH1F, {{100, 0.95f, 1.f}}}); - - rOmega.add("hCascDCAV0Daughters", "hCascDCAV0Daughters", {HistType::kTH1F, {{55, 0.0f, 2.2f}}}); - rOmega.add("hCascCosPA", "hCascCosPA", {HistType::kTH1F, {{100, 0.95f, 1.f}}}); - } - - // Defining filters for events (event selection) - // Processed events will be already fulfilling the event selection requirements - Filter eventFilter = (o2::aod::evsel::sel8 == true); - Filter posZFilter = (nabs(o2::aod::collision::posZ) < cutzvertex); - - // Filters on Cascades - // Cannot filter on dynamic columns - Filter preFilterCascades = (aod::cascdata::dcaV0daughters < cascadesetting_dcav0dau && - nabs(aod::cascdata::dcapostopv) > cascadesetting_dcapostopv && - nabs(aod::cascdata::dcanegtopv) > cascadesetting_dcanegtopv && - nabs(aod::cascdata::dcabachtopv) > cascadesetting_dcabachtopv && - aod::cascdata::dcacascdaughters < cascadesetting_dcacascdau); - - // Defining the type of the daughter tracks - using dauTracks = soa::Join; - - void process(soa::Filtered>::iterator const& collision, - soa::Filtered> const& Cascades, - dauTracks const&) - { - // Fill the event counter - rEventSelection.fill(HIST("hVertexZRec"), collision.posZ()); - - // Cascades - for (const auto& casc : Cascades) { - const auto& bachDaughterTrackCasc = casc.bachTrackExtra_as(); - const auto& posDaughterTrackCasc = casc.posTrackExtra_as(); - const auto& negDaughterTrackCasc = casc.negTrackExtra_as(); - - rXi.fill(HIST("hMassXi"), casc.mXi()); - rOmega.fill(HIST("hMassOmega"), casc.mOmega()); - - // Cut on dynamic columns - if (casc.casccosPA(collision.posX(), collision.posY(), collision.posZ()) < cascadesetting_cospa) - continue; - if (casc.v0cosPA(collision.posX(), collision.posY(), collision.posZ()) < cascadesetting_v0cospa) - continue; - if (TMath::Abs(casc.mLambda() - pdgDB->Mass(3122)) > cascadesetting_v0masswindow) - continue; - if (casc.dcav0topv(collision.posX(), collision.posY(), collision.posZ()) < cascadesetting_mindcav0topv) - continue; - if (casc.cascradius() < cascadesetting_cascradius) - continue; - if (casc.v0radius() < cascadesetting_v0radius) - continue; - - // PID selection - if (casc.sign() < 0) { - if (TMath::Abs(posDaughterTrackCasc.tpcNSigmaPr()) > NSigmaTPCProton) { - continue; - } - if (TMath::Abs(negDaughterTrackCasc.tpcNSigmaPi()) > NSigmaTPCPion) { - continue; - } - } else { - if (TMath::Abs(negDaughterTrackCasc.tpcNSigmaPr()) > NSigmaTPCProton) { - continue; - } - if (TMath::Abs(posDaughterTrackCasc.tpcNSigmaPi()) > NSigmaTPCPion) { - continue; - } - } - - // Fill histograms! (if possible) - if (TMath::Abs(bachDaughterTrackCasc.tpcNSigmaPi()) < NSigmaTPCPion) { // Xi case - rXi.fill(HIST("hMassXiSelected"), casc.mXi()); - - rXi.fill(HIST("hCascDCAV0Daughters"), casc.dcaV0daughters()); - rXi.fill(HIST("hCascCosPA"), casc.casccosPA(collision.posX(), collision.posY(), collision.posZ())); - } - if (TMath::Abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case - if (TMath::Abs(casc.mXi() - pdgDB->Mass(3312)) > cascadesetting_competingmassrej) { // competing mass rejection, only in case of Omega - rOmega.fill(HIST("hMassOmegaSelected"), casc.mOmega()); - - rOmega.fill(HIST("hCascDCAV0Daughters"), casc.dcaV0daughters()); - rOmega.fill(HIST("hCascCosPA"), casc.casccosPA(collision.posX(), collision.posY(), collision.posZ())); - } - } - } - } -}; - -WorkflowSpec defineDataProcessing(ConfigContext const& cfgc) -{ - return WorkflowSpec{ - adaptAnalysisTask(cfgc)}; -} diff --git a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step3.cxx b/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step3.cxx deleted file mode 100644 index f12a4f02560..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step3.cxx +++ /dev/null @@ -1,243 +0,0 @@ -// 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. -/// -/// \brief Step4 of the Strangeness tutorial -/// \author Romain Schotter -/// based on the original codes from: -/// \author Nepeivoda Roman (roman.nepeivoda@cern.ch) -/// \author Chiara De Martin (chiara.de.martin@cern.ch) - -#include "Framework/runDataProcessing.h" -#include "Framework/AnalysisTask.h" -#include "Common/DataModel/EventSelection.h" -#include "PWGLF/DataModel/LFStrangenessPIDTables.h" -#include "PWGLF/DataModel/LFStrangenessTables.h" -#include "Framework/O2DatabasePDGPlugin.h" - -using namespace o2; -using namespace o2::framework; -using namespace o2::framework::expressions; - -// STEP 0 -// Starting point: loop over all cascades and fill invariant mass histogram -// STEP 1 -// Apply selections on topological variables of Cascades -// STEP 2 -// Apply TPC PID selections on cascade daughter tracks -// STEP 3 -// Apply TOF PID selections on cascade daugther tracks (if info is available) - -struct strangeness_pbpb_tutorial { - // Histograms are defined with HistogramRegistry - HistogramRegistry rEventSelection{"eventSelection", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - HistogramRegistry rXi{"xi", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - HistogramRegistry rOmega{"omega", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - - // Configurable for histograms - Configurable nBins{"nBins", 100, "N bins in all histos"}; - - // Configurable for event selection - Configurable cutzvertex{"cutzvertex", 10.0f, "Accepted z-vertex range (cm)"}; - - // Configurable parameters for cascade selection - Configurable cascadesetting_cospa{"cascadesetting_cospa", 0.98, "Casc CosPA"}; - Configurable cascadesetting_v0cospa{"cascadesetting_v0cospa", 0.97, "V0 CosPA"}; - Configurable cascadesetting_dcacascdau{"cascadesetting_dcacascdau", 1.0, "DCA cascade daughters"}; - Configurable cascadesetting_dcav0dau{"cascadesetting_dcav0dau", 1.0, "DCA v0 daughters"}; - Configurable cascadesetting_dcabachtopv{"cascadesetting_dcabachtopv", 0.06, "DCA bachelor to PV"}; - Configurable cascadesetting_dcapostopv{"cascadesetting_dcapostopv", 0.06, "DCA positive to PV"}; - Configurable cascadesetting_dcanegtopv{"cascadesetting_dcanegtopv", 0.06, "DCA negative to PV"}; - Configurable cascadesetting_mindcav0topv{"cascadesetting_mindcav0topv", 0.01, "minimum V0 DCA to PV"}; - Configurable cascadesetting_cascradius{"cascadesetting_cascradius", 0.5, "cascradius"}; - Configurable cascadesetting_v0radius{"cascadesetting_v0radius", 1.2, "v0radius"}; - Configurable cascadesetting_v0masswindow{"cascadesetting_v0masswindow", 0.01, "v0 mass window"}; - Configurable cascadesetting_competingmassrej{"cascadesetting_competingmassrej", 0.008, "Competing mass rejection"}; - - // Configurable parameters for PID selection - Configurable NSigmaTPCPion{"NSigmaTPCPion", 4, "NSigmaTPCPion"}; - Configurable NSigmaTPCKaon{"NSigmaTPCKaon", 4, "NSigmaTPCKaon"}; - Configurable NSigmaTPCProton{"NSigmaTPCProton", 4, "NSigmaTPCProton"}; - - // Configurable parameters for TOF PID selection - Configurable NSigmaTOFPion{"NSigmaTOFPion", 3, "NSigmaTOFPion"}; - Configurable NSigmaTOFKaon{"NSigmaTOFKaon", 3, "NSigmaTOFKaon"}; - Configurable NSigmaTOFProton{"NSigmaTOFProton", 3, "NSigmaTOFProton"}; - - // PDG data base - Service pdgDB; - - void init(InitContext const&) - { - // Axes - AxisSpec XiMassAxis = {100, 1.28f, 1.36f, "#it{M}_{inv} [GeV/#it{c}^{2}]"}; - AxisSpec OmegaMassAxis = {100, 1.63f, 1.7f, "#it{M}_{inv} [GeV/#it{c}^{2}]"}; - AxisSpec vertexZAxis = {nBins, -15., 15., "vrtx_{Z} [cm]"}; - - // Histograms - // Event selection - rEventSelection.add("hVertexZRec", "hVertexZRec", {HistType::kTH1F, {vertexZAxis}}); - - // Xi/Omega reconstruction - rXi.add("hMassXi", "hMassXi", {HistType::kTH1F, {XiMassAxis}}); - rXi.add("hMassXiSelected", "hMassXiSelected", {HistType::kTH1F, {XiMassAxis}}); - rXi.add("hMassXiSelectedWithTOF", "hMassXiSelectedWithTOF", {HistType::kTH1F, {XiMassAxis}}); - - rOmega.add("hMassOmega", "hMassOmega", {HistType::kTH1F, {OmegaMassAxis}}); - rOmega.add("hMassOmegaSelected", "hMassOmegaSelected", {HistType::kTH1F, {OmegaMassAxis}}); - rOmega.add("hMassOmegaSelectedWithTOF", "hMassOmegaSelectedWithTOF", {HistType::kTH1F, {OmegaMassAxis}}); - - // Xi/Omega topological cuts - rXi.add("hCascDCAV0Daughters", "hCascDCAV0Daughters", {HistType::kTH1F, {{55, 0.0f, 2.2f}}}); - rXi.add("hCascCosPA", "hCascCosPA", {HistType::kTH1F, {{100, 0.95f, 1.f}}}); - - rOmega.add("hCascDCAV0Daughters", "hCascDCAV0Daughters", {HistType::kTH1F, {{55, 0.0f, 2.2f}}}); - rOmega.add("hCascCosPA", "hCascCosPA", {HistType::kTH1F, {{100, 0.95f, 1.f}}}); - } - - // Defining filters for events (event selection) - // Processed events will be already fulfilling the event selection requirements - Filter eventFilter = (o2::aod::evsel::sel8 == true); - Filter posZFilter = (nabs(o2::aod::collision::posZ) < cutzvertex); - - // Filters on Cascades - // Cannot filter on dynamic columns - Filter preFilterCascades = (aod::cascdata::dcaV0daughters < cascadesetting_dcav0dau && - nabs(aod::cascdata::dcapostopv) > cascadesetting_dcapostopv && - nabs(aod::cascdata::dcanegtopv) > cascadesetting_dcanegtopv && - nabs(aod::cascdata::dcabachtopv) > cascadesetting_dcabachtopv && - aod::cascdata::dcacascdaughters < cascadesetting_dcacascdau); - - // Defining the type of the daughter tracks - using dauTracks = soa::Join; - - void process(soa::Filtered>::iterator const& collision, - soa::Filtered> const& Cascades, - dauTracks const&) - { - // Fill the event counter - rEventSelection.fill(HIST("hVertexZRec"), collision.posZ()); - - // Cascades - for (const auto& casc : Cascades) { - const auto& bachDaughterTrackCasc = casc.bachTrackExtra_as(); - const auto& posDaughterTrackCasc = casc.posTrackExtra_as(); - const auto& negDaughterTrackCasc = casc.negTrackExtra_as(); - - rXi.fill(HIST("hMassXi"), casc.mXi()); - rOmega.fill(HIST("hMassOmega"), casc.mOmega()); - - // Cut on dynamic columns - if (casc.casccosPA(collision.posX(), collision.posY(), collision.posZ()) < cascadesetting_cospa) - continue; - if (casc.v0cosPA(collision.posX(), collision.posY(), collision.posZ()) < cascadesetting_v0cospa) - continue; - if (TMath::Abs(casc.mLambda() - pdgDB->Mass(3122)) > cascadesetting_v0masswindow) - continue; - if (casc.dcav0topv(collision.posX(), collision.posY(), collision.posZ()) < cascadesetting_mindcav0topv) - continue; - if (casc.cascradius() < cascadesetting_cascradius) - continue; - if (casc.v0radius() < cascadesetting_v0radius) - continue; - - // PID selection - if (casc.sign() < 0) { - if (TMath::Abs(posDaughterTrackCasc.tpcNSigmaPr()) > NSigmaTPCProton) { - continue; - } - if (TMath::Abs(negDaughterTrackCasc.tpcNSigmaPi()) > NSigmaTPCPion) { - continue; - } - } else { - if (TMath::Abs(negDaughterTrackCasc.tpcNSigmaPr()) > NSigmaTPCProton) { - continue; - } - if (TMath::Abs(posDaughterTrackCasc.tpcNSigmaPi()) > NSigmaTPCPion) { - continue; - } - } - - // TOF PID check - bool xiPassTOFSelection = true; - bool omegaPassTOFSelection = true; - if (casc.sign() < 0) { - if (posDaughterTrackCasc.hasTOF()) { - if (TMath::Abs(casc.tofNSigmaXiLaPr()) > NSigmaTOFProton) { - xiPassTOFSelection &= false; - } - if (TMath::Abs(casc.tofNSigmaOmLaPr()) > NSigmaTOFProton) { - omegaPassTOFSelection &= false; - } - } - if (negDaughterTrackCasc.hasTOF()) { - if (TMath::Abs(casc.tofNSigmaXiLaPi()) > NSigmaTOFPion) { - xiPassTOFSelection &= false; - } - if (TMath::Abs(casc.tofNSigmaOmLaPi()) > NSigmaTOFPion) { - omegaPassTOFSelection &= false; - } - } - } else { - if (posDaughterTrackCasc.hasTOF()) { - if (TMath::Abs(casc.tofNSigmaXiLaPi()) > NSigmaTOFPion) { - xiPassTOFSelection &= false; - } - if (TMath::Abs(casc.tofNSigmaOmLaPi()) > NSigmaTOFPion) { - omegaPassTOFSelection &= false; - } - } - if (negDaughterTrackCasc.hasTOF()) { - if (TMath::Abs(casc.tofNSigmaXiLaPr()) > NSigmaTOFProton) { - xiPassTOFSelection &= false; - } - if (TMath::Abs(casc.tofNSigmaOmLaPr()) > NSigmaTOFProton) { - omegaPassTOFSelection &= false; - } - } - } - - if (bachDaughterTrackCasc.hasTOF()) { - if (TMath::Abs(casc.tofNSigmaXiPi()) > NSigmaTOFPion) { - xiPassTOFSelection &= false; - } - if (TMath::Abs(casc.tofNSigmaOmKa()) > NSigmaTOFKaon) { - omegaPassTOFSelection &= false; - } - } - - // Fill histograms! (if possible) - if (TMath::Abs(bachDaughterTrackCasc.tpcNSigmaPi()) < NSigmaTPCPion) { // Xi case - rXi.fill(HIST("hMassXiSelected"), casc.mXi()); - if (xiPassTOFSelection) - rXi.fill(HIST("hMassXiSelectedWithTOF"), casc.mXi()); - - rXi.fill(HIST("hCascDCAV0Daughters"), casc.dcaV0daughters()); - rXi.fill(HIST("hCascCosPA"), casc.casccosPA(collision.posX(), collision.posY(), collision.posZ())); - } - if (TMath::Abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case - if (TMath::Abs(casc.mXi() - pdgDB->Mass(3312)) > cascadesetting_competingmassrej) { // competing mass rejection, only in case of Omega - rOmega.fill(HIST("hMassOmegaSelected"), casc.mOmega()); - if (omegaPassTOFSelection) - rOmega.fill(HIST("hMassOmegaSelectedWithTOF"), casc.mOmega()); - - rOmega.fill(HIST("hCascDCAV0Daughters"), casc.dcaV0daughters()); - rOmega.fill(HIST("hCascCosPA"), casc.casccosPA(collision.posX(), collision.posY(), collision.posZ())); - } - } - } - } -}; - -WorkflowSpec defineDataProcessing(ConfigContext const& cfgc) -{ - return WorkflowSpec{ - adaptAnalysisTask(cfgc)}; -} diff --git a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step4.cxx b/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step4.cxx deleted file mode 100644 index d45ef3c26a1..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/Analysis/strangeness_pbpb_step4.cxx +++ /dev/null @@ -1,324 +0,0 @@ -// 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. -/// -/// \brief Step4 of the Strangeness tutorial -/// \author Romain Schotter -/// based on the original codes from: -/// \author Nepeivoda Roman (roman.nepeivoda@cern.ch) -/// \author Chiara De Martin (chiara.de.martin@cern.ch) - -#include "Framework/runDataProcessing.h" -#include "Framework/AnalysisTask.h" -#include "Common/DataModel/EventSelection.h" -#include "PWGLF/DataModel/LFStrangenessPIDTables.h" -#include "PWGLF/DataModel/LFStrangenessTables.h" -#include "Framework/O2DatabasePDGPlugin.h" - -using namespace o2; -using namespace o2::framework; -using namespace o2::framework::expressions; - -// STEP 0 -// Starting point: loop over all cascades and fill invariant mass histogram -// STEP 1 -// Apply selections on topological variables of Cascades -// STEP 2 -// Apply TPC PID selections on cascade daughter tracks -// STEP 3 -// Apply TOF PID selections on cascade daugther tracks (if info is available) -// STEP 4 -// Check the MC information of the cascades - -struct strangeness_pbpb_tutorial { - // Histograms are defined with HistogramRegistry - HistogramRegistry rEventSelection{"eventSelection", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - HistogramRegistry rXi{"xi", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - HistogramRegistry rOmega{"omega", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - HistogramRegistry rGenParticles{"genParticles", {}, OutputObjHandlingPolicy::AnalysisObject, true, true}; - - // Configurable for histograms - Configurable nBins{"nBins", 100, "N bins in all histos"}; - - // Configurable for event selection - Configurable cutzvertex{"cutzvertex", 10.0f, "Accepted z-vertex range (cm)"}; - - // Configurable parameters for cascade selection - Configurable cascadesetting_cospa{"cascadesetting_cospa", 0.98, "Casc CosPA"}; - Configurable cascadesetting_v0cospa{"cascadesetting_v0cospa", 0.97, "V0 CosPA"}; - Configurable cascadesetting_dcacascdau{"cascadesetting_dcacascdau", 1.0, "DCA cascade daughters"}; - Configurable cascadesetting_dcav0dau{"cascadesetting_dcav0dau", 1.0, "DCA v0 daughters"}; - Configurable cascadesetting_dcabachtopv{"cascadesetting_dcabachtopv", 0.06, "DCA bachelor to PV"}; - Configurable cascadesetting_dcapostopv{"cascadesetting_dcapostopv", 0.06, "DCA positive to PV"}; - Configurable cascadesetting_dcanegtopv{"cascadesetting_dcanegtopv", 0.06, "DCA negative to PV"}; - Configurable cascadesetting_mindcav0topv{"cascadesetting_mindcav0topv", 0.01, "minimum V0 DCA to PV"}; - Configurable cascadesetting_cascradius{"cascadesetting_cascradius", 0.5, "cascradius"}; - Configurable cascadesetting_v0radius{"cascadesetting_v0radius", 1.2, "v0radius"}; - Configurable cascadesetting_v0masswindow{"cascadesetting_v0masswindow", 0.01, "v0 mass window"}; - Configurable cascadesetting_competingmassrej{"cascadesetting_competingmassrej", 0.008, "Competing mass rejection"}; - - // Configurable parameters for PID selection - Configurable NSigmaTPCPion{"NSigmaTPCPion", 4, "NSigmaTPCPion"}; - Configurable NSigmaTPCKaon{"NSigmaTPCKaon", 4, "NSigmaTPCKaon"}; - Configurable NSigmaTPCProton{"NSigmaTPCProton", 4, "NSigmaTPCProton"}; - - // Configurable parameters for TOF PID selection - Configurable NSigmaTOFPion{"NSigmaTOFPion", 3, "NSigmaTOFPion"}; - Configurable NSigmaTOFKaon{"NSigmaTOFKaon", 3, "NSigmaTOFKaon"}; - Configurable NSigmaTOFProton{"NSigmaTOFProton", 3, "NSigmaTOFProton"}; - - // PDG data base - Service pdgDB; - - void init(InitContext const&) - { - // Axes - AxisSpec XiMassAxis = {100, 1.28f, 1.36f, "#it{M}_{inv} [GeV/#it{c}^{2}]"}; - AxisSpec OmegaMassAxis = {100, 1.63f, 1.7f, "#it{M}_{inv} [GeV/#it{c}^{2}]"}; - AxisSpec vertexZAxis = {nBins, -15., 15., "vrtx_{Z} [cm]"}; - AxisSpec ptAxis = {100, 0.0f, 10.0f, "#it{p}_{T} (GeV/#it{c})"}; - - // Histograms - // Event selection - rEventSelection.add("hVertexZRec", "hVertexZRec", {HistType::kTH1F, {vertexZAxis}}); - - // Xi/Omega reconstruction - rXi.add("hMassXi", "hMassXi", {HistType::kTH1F, {XiMassAxis}}); - rXi.add("hMassXiSelected", "hMassXiSelected", {HistType::kTH1F, {XiMassAxis}}); - rXi.add("hMassXiSelectedWithTOF", "hMassXiSelectedWithTOF", {HistType::kTH1F, {XiMassAxis}}); - rXi.add("hMassXiTrueRec", "hMassXiTrueRec", {HistType::kTH1F, {XiMassAxis}}); - rXi.add("hPtXiTrueRec", "hPtXiTrueRec", {HistType::kTH1F, {ptAxis}}); - rXi.add("hMassXiTrueRecWithTOF", "hMassXiTrueRecWithTOF", {HistType::kTH1F, {XiMassAxis}}); - rXi.add("hPtXiTrueRecWithTOF", "hPtXiTrueRecWithTOF", {HistType::kTH1F, {ptAxis}}); - - rOmega.add("hMassOmega", "hMassOmega", {HistType::kTH1F, {OmegaMassAxis}}); - rOmega.add("hMassOmegaSelected", "hMassOmegaSelected", {HistType::kTH1F, {OmegaMassAxis}}); - rOmega.add("hMassOmegaSelectedWithTOF", "hMassOmegaSelectedWithTOF", {HistType::kTH1F, {OmegaMassAxis}}); - rOmega.add("hMassOmegaTrueRec", "hMassOmegaTrueRec", {HistType::kTH1F, {OmegaMassAxis}}); - rOmega.add("hPtOmegaTrueRec", "hPtOmegaTrueRec", {HistType::kTH1F, {ptAxis}}); - rOmega.add("hMassOmegaTrueRecWithTOF", "hMassOmegaTrueRecWithTOF", {HistType::kTH1F, {OmegaMassAxis}}); - rOmega.add("hPtOmegaTrueRecWithTOF", "hPtOmegaTrueRecWithTOF", {HistType::kTH1F, {ptAxis}}); - - // Xi/Omega topological cuts - rXi.add("hCascDCAV0Daughters", "hCascDCAV0Daughters", {HistType::kTH1F, {{55, 0.0f, 2.2f}}}); - rXi.add("hCascCosPA", "hCascCosPA", {HistType::kTH1F, {{100, 0.95f, 1.f}}}); - - rOmega.add("hCascDCAV0Daughters", "hCascDCAV0Daughters", {HistType::kTH1F, {{55, 0.0f, 2.2f}}}); - rOmega.add("hCascCosPA", "hCascCosPA", {HistType::kTH1F, {{100, 0.95f, 1.f}}}); - - // Generated level histograms - rEventSelection.add("hVertexZGen", "hVertexZGen", {HistType::kTH1F, {vertexZAxis}}); - rGenParticles.add("hPtXiGen", "hPtXiGen", {HistType::kTH1F, {{ptAxis}}}); - rGenParticles.add("hPtOmegaGen", "hPtOmegaGen", {HistType::kTH1F, {{ptAxis}}}); - } - - // Defining filters for events (event selection) - // Processed events will be already fulfilling the event selection requirements - Filter eventFilter = (o2::aod::evsel::sel8 == true); - Filter posZFilter = (nabs(o2::aod::collision::posZ) < cutzvertex); - Filter posZFilterMC = (nabs(o2::aod::mccollision::posZ) < cutzvertex); - - // Filters on Cascades - // Cannot filter on dynamic columns - Filter preFilterCascades = (aod::cascdata::dcaV0daughters < cascadesetting_dcav0dau && - nabs(aod::cascdata::dcapostopv) > cascadesetting_dcapostopv && - nabs(aod::cascdata::dcanegtopv) > cascadesetting_dcanegtopv && - nabs(aod::cascdata::dcabachtopv) > cascadesetting_dcabachtopv && - aod::cascdata::dcacascdaughters < cascadesetting_dcacascdau); - - // Defining the type of the daughter tracks - using dauTracks = soa::Join; - - void processRecMC(soa::Filtered>::iterator const& collision, - soa::Filtered> const& Cascades, - dauTracks const&, - aod::CascMCCores const& /*cascmccores*/) - { - // Fill the event counter - rEventSelection.fill(HIST("hVertexZRec"), collision.posZ()); - - // Cascades - for (const auto& casc : Cascades) { - const auto& bachDaughterTrackCasc = casc.bachTrackExtra_as(); - const auto& posDaughterTrackCasc = casc.posTrackExtra_as(); - const auto& negDaughterTrackCasc = casc.negTrackExtra_as(); - - rXi.fill(HIST("hMassXi"), casc.mXi()); - rOmega.fill(HIST("hMassOmega"), casc.mOmega()); - - // Cut on dynamic columns - if (casc.casccosPA(collision.posX(), collision.posY(), collision.posZ()) < cascadesetting_cospa) - continue; - if (casc.v0cosPA(collision.posX(), collision.posY(), collision.posZ()) < cascadesetting_v0cospa) - continue; - if (TMath::Abs(casc.mLambda() - pdgDB->Mass(3122)) > cascadesetting_v0masswindow) - continue; - if (casc.dcav0topv(collision.posX(), collision.posY(), collision.posZ()) < cascadesetting_mindcav0topv) - continue; - if (casc.cascradius() < cascadesetting_cascradius) - continue; - if (casc.v0radius() < cascadesetting_v0radius) - continue; - - // PID selection - if (casc.sign() < 0) { - if (TMath::Abs(posDaughterTrackCasc.tpcNSigmaPr()) > NSigmaTPCProton) { - continue; - } - if (TMath::Abs(negDaughterTrackCasc.tpcNSigmaPi()) > NSigmaTPCPion) { - continue; - } - } else { - if (TMath::Abs(negDaughterTrackCasc.tpcNSigmaPr()) > NSigmaTPCProton) { - continue; - } - if (TMath::Abs(posDaughterTrackCasc.tpcNSigmaPi()) > NSigmaTPCPion) { - continue; - } - } - - // TOF PID check - bool xiPassTOFSelection = true; - bool omegaPassTOFSelection = true; - if (casc.sign() < 0) { - if (posDaughterTrackCasc.hasTOF()) { - if (TMath::Abs(casc.tofNSigmaXiLaPr()) > NSigmaTOFProton) { - xiPassTOFSelection &= false; - } - if (TMath::Abs(casc.tofNSigmaOmLaPr()) > NSigmaTOFProton) { - omegaPassTOFSelection &= false; - } - } - if (negDaughterTrackCasc.hasTOF()) { - if (TMath::Abs(casc.tofNSigmaXiLaPi()) > NSigmaTOFPion) { - xiPassTOFSelection &= false; - } - if (TMath::Abs(casc.tofNSigmaOmLaPi()) > NSigmaTOFPion) { - omegaPassTOFSelection &= false; - } - } - } else { - if (posDaughterTrackCasc.hasTOF()) { - if (TMath::Abs(casc.tofNSigmaXiLaPi()) > NSigmaTOFPion) { - xiPassTOFSelection &= false; - } - if (TMath::Abs(casc.tofNSigmaOmLaPi()) > NSigmaTOFPion) { - omegaPassTOFSelection &= false; - } - } - if (negDaughterTrackCasc.hasTOF()) { - if (TMath::Abs(casc.tofNSigmaXiLaPr()) > NSigmaTOFProton) { - xiPassTOFSelection &= false; - } - if (TMath::Abs(casc.tofNSigmaOmLaPr()) > NSigmaTOFProton) { - omegaPassTOFSelection &= false; - } - } - } - - if (bachDaughterTrackCasc.hasTOF()) { - if (TMath::Abs(casc.tofNSigmaXiPi()) > NSigmaTOFPion) { - xiPassTOFSelection &= false; - } - if (TMath::Abs(casc.tofNSigmaOmKa()) > NSigmaTOFKaon) { - omegaPassTOFSelection &= false; - } - } - - if (bachDaughterTrackCasc.hasTOF()) { - if (TMath::Abs(casc.tofNSigmaXiPi()) > NSigmaTOFPion) { - xiPassTOFSelection &= false; - } - if (TMath::Abs(casc.tofNSigmaOmKa()) > NSigmaTOFKaon) { - omegaPassTOFSelection &= false; - } - } - - // Fill histograms! (if possible) - if (TMath::Abs(bachDaughterTrackCasc.tpcNSigmaPi()) < NSigmaTPCPion) { // Xi case - rXi.fill(HIST("hMassXiSelected"), casc.mXi()); - if (xiPassTOFSelection) { - rXi.fill(HIST("hMassXiSelectedWithTOF"), casc.mXi()); - } - - rXi.fill(HIST("hCascDCAV0Daughters"), casc.dcaV0daughters()); - rXi.fill(HIST("hCascCosPA"), casc.casccosPA(collision.posX(), collision.posY(), collision.posZ())); - } - if (TMath::Abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case - if (TMath::Abs(casc.mXi() - pdgDB->Mass(3312)) > cascadesetting_competingmassrej) { // competing mass rejection, only in case of Omega - rOmega.fill(HIST("hMassOmegaSelected"), casc.mOmega()); - if (omegaPassTOFSelection) { - rOmega.fill(HIST("hMassOmegaSelectedWithTOF"), casc.mOmega()); - } - - rOmega.fill(HIST("hCascDCAV0Daughters"), casc.dcaV0daughters()); - rOmega.fill(HIST("hCascCosPA"), casc.casccosPA(collision.posX(), collision.posY(), collision.posZ())); - } - } - - // MC truth info - if (!casc.has_cascMCCore()) { - continue; - } - auto cascmccore = casc.cascMCCore_as(); - - // Checking that the cascade is a true Xi - if (TMath::Abs(cascmccore.pdgCode()) == 3312) { - if (TMath::Abs(bachDaughterTrackCasc.tpcNSigmaPi()) < NSigmaTPCPion) { // Xi case - rXi.fill(HIST("hMassXiTrueRec"), casc.mXi()); - rXi.fill(HIST("hPtXiTrueRec"), casc.pt()); - if (xiPassTOFSelection) { - rXi.fill(HIST("hMassXiTrueRecWithTOF"), casc.mXi()); - rXi.fill(HIST("hPtXiTrueRecWithTOF"), casc.pt()); - } - } - } - if (TMath::Abs(cascmccore.pdgCode()) == 3334) { - if (TMath::Abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case - if (TMath::Abs(casc.mXi() - pdgDB->Mass(3312)) > cascadesetting_competingmassrej) { // competing mass rejection, only in case of Omega - rOmega.fill(HIST("hMassOmegaTrueRec"), casc.mOmega()); - rOmega.fill(HIST("hPtOmegaTrueRec"), casc.pt()); - if (omegaPassTOFSelection) { - rOmega.fill(HIST("hMassOmegaTrueRecWithTOF"), casc.mOmega()); - rOmega.fill(HIST("hPtOmegaTrueRecWithTOF"), casc.pt()); - } - } - } - } - } - } - - void processGenMC(soa::Filtered::iterator const& mcCollision, - const soa::SmallGroups>& collisions, - const soa::SmallGroups>& cascMC) - { - if (collisions.size() < 1) // to process generated collisions that've been reconstructed at least once - return; - rEventSelection.fill(HIST("hVertexZGen"), mcCollision.posZ()); - - for (const auto& cascmc : cascMC) { - if (TMath::Abs(cascmc.pdgCode()) == 3312) { - rGenParticles.fill(HIST("hPtXiGen"), cascmc.ptMC()); - } - if (TMath::Abs(cascmc.pdgCode()) == 3334) { - rGenParticles.fill(HIST("hPtOmegaGen"), cascmc.ptMC()); - } - } - } - - PROCESS_SWITCH(strangeness_pbpb_tutorial, processRecMC, "Process Run 3 mc, reconstructed", true); - PROCESS_SWITCH(strangeness_pbpb_tutorial, processGenMC, "Process Run 3 mc, generated", true); -}; - -WorkflowSpec defineDataProcessing(ConfigContext const& cfgc) -{ - return WorkflowSpec{ - adaptAnalysisTask(cfgc)}; -} diff --git a/Tutorials/PWGLF/Strangeness/PbPb/CMakeLists.txt b/Tutorials/PWGLF/Strangeness/PbPb/CMakeLists.txt deleted file mode 100644 index f593f821726..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/CMakeLists.txt +++ /dev/null @@ -1,13 +0,0 @@ -# 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. - -add_subdirectory(Analysis) -# add_subdirectory(DerivedDataProduction) \ No newline at end of file diff --git a/Tutorials/PWGLF/Strangeness/PbPb/DerivedDataProduction/Data/run.sh b/Tutorials/PWGLF/Strangeness/PbPb/DerivedDataProduction/Data/run.sh deleted file mode 100644 index 632f8375470..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/DerivedDataProduction/Data/run.sh +++ /dev/null @@ -1,42 +0,0 @@ -#!/bin/bash -# log file where the terminal output will be saved -STEP="deriveddata" -LOGFILE="log-${STEP}.txt" - -#directory of this script -DIR_THIS=$PWD - -OPTION="-b --configuration json://configuration.json" - -o2-analysis-pid-tof-base "${OPTION}" | - o2-analysis-event-selection "${OPTION}" | - o2-analysis-lf-lambdakzerobuilder "${OPTION}" | - o2-analysis-lf-cascadebuilder "${OPTION}" | - o2-analysis-multiplicity-table "${OPTION}" | - o2-analysis-centrality-table "${OPTION}" | - o2-analysis-lf-epvector "${OPTION}" | - o2-analysis-centrality-qa "${OPTION}" | - o2-analysis-ud-sgcand-producer "${OPTION}" | - o2-analysis-timestamp "${OPTION}" | - o2-analysis-ft0-corrected-table "${OPTION}" | - o2-analysis-track-propagation "${OPTION}" | - o2-analysis-pid-tpc-base "${OPTION}" | - o2-analysis-pid-tpc "${OPTION}" | - o2-analysis-trackselection "${OPTION}" | - o2-analysis-pid-tof-full "${OPTION}" | - o2-analysis-pid-tof-beta "${OPTION}" | - o2-analysis-lf-strangederivedbuilder "${OPTION}" --aod-file @input_data.txt --aod-writer-json OutputDirector.json >"$LOGFILE" 2>&1 - -# report status -rc=$? -if [ $rc -eq 0 ]; then - echo "No problems!" - mkdir -p "${DIR_THIS}/results/${STEP}" - mv AnalysisResults.root "${DIR_THIS}/results/${STEP}/AnalysisResults.root" - mv AO2D.root "${DIR_THIS}/results/${STEP}/AO2D.root" - mv dpl-config.json "${DIR_THIS}/results/${STEP}/${STEP}.json" -else - echo "Error: Exit code ${rc}" - echo "Check the log file ${LOGFILE}" - exit ${rc} -fi diff --git a/Tutorials/PWGLF/Strangeness/PbPb/DerivedDataProduction/MC/runMC.sh b/Tutorials/PWGLF/Strangeness/PbPb/DerivedDataProduction/MC/runMC.sh deleted file mode 100644 index e9e086e4f4e..00000000000 --- a/Tutorials/PWGLF/Strangeness/PbPb/DerivedDataProduction/MC/runMC.sh +++ /dev/null @@ -1,44 +0,0 @@ -#!/bin/bash -# log file where the terminal output will be saved -STEP="deriveddata" -LOGFILE="log-${STEP}.txt" - -#directory of this script -DIR_THIS=$PWD - -OPTION="-b --configuration json://configurationMC.json" - -o2-analysis-pid-tof-base "${OPTION}" | - o2-analysis-mccollisionextra "${OPTION}" | - o2-analysis-lf-lambdakzerobuilder "${OPTION}" | - o2-analysis-lf-cascadebuilder "${OPTION}" | - o2-analysis-lf-cascademcbuilder "${OPTION}" | - o2-analysis-centrality-table "${OPTION}" | - o2-analysis-lf-lambdakzeromcbuilder "${OPTION}" | - o2-analysis-mccollision-converter "${OPTION}" | - o2-analysis-ud-sgcand-producer "${OPTION}" | - o2-analysis-timestamp "${OPTION}" | - o2-analysis-ft0-corrected-table "${OPTION}" | - o2-analysis-track-propagation "${OPTION}" | - o2-analysis-pid-tpc-base "${OPTION}" | - o2-analysis-pid-tpc "${OPTION}" | - o2-analysis-multiplicity-table "${OPTION}" | - o2-analysis-trackselection "${OPTION}" | - o2-analysis-pid-tof-full "${OPTION}" | - o2-analysis-pid-tof-beta "${OPTION}" | - o2-analysis-event-selection "${OPTION}" | - o2-analysis-lf-strangederivedbuilder "${OPTION}" --aod-file @input_dataMC.txt --aod-writer-json OutputDirectorMC.json >"$LOGFILE" 2>&1 - -# report status -rc=$? -if [ $rc -eq 0 ]; then - echo "No problems!" - mkdir -p "${DIR_THIS}/results/${STEP}" - mv AnalysisResults.root "${DIR_THIS}/results/${STEP}/AnalysisResults.root" - mv AO2D.root "${DIR_THIS}/results/${STEP}/AO2D.root" - mv dpl-config.json "${DIR_THIS}/results/${STEP}/${STEP}.json" -else - echo "Error: Exit code ${rc}" - echo "Check the log file ${LOGFILE}" - exit ${rc} -fi From 4eb014451a38dfb237953dbdec20279b174798b0 Mon Sep 17 00:00:00 2001 From: ALICE Action Bot Date: Mon, 10 Nov 2025 22:42:09 +0000 Subject: [PATCH 3/3] Please consider the following formatting changes --- .../Derived/Analysis/configuration_step3.json | 230 +++++++++--------- .../Derived/Analysis/configuration_step4.json | 228 ++++++++--------- .../Analysis/strangeness_derived_step3.cxx | 10 +- .../Analysis/strangeness_derived_step4.cxx | 12 +- 4 files changed, 242 insertions(+), 238 deletions(-) diff --git a/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step3.json b/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step3.json index 4a182b0e7b2..7a17dfb6429 100644 --- a/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step3.json +++ b/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step3.json @@ -12,123 +12,123 @@ "strangenesstofpid": { "v0Calibration.qaMassWindow": "0.005", "axisP": { - "values": [ - 0, - 0, - 0.10000000149011612, - 0.20000000298023224, - 0.30000001192092896, - 0.4000000059604645, - 0.5, - 0.6000000238418579, - 0.699999988079071, - 0.800000011920929, - 0.8999999761581421, - 1, - 1.100000023841858, - 1.2000000476837158, - 1.2999999523162842, - 1.399999976158142, - 1.5, - 1.600000023841858, - 1.7000000476837158, - 1.7999999523162842, - 1.899999976158142, - 2, - 2.200000047683716, - 2.4000000953674316, - 2.5999999046325684, - 2.799999952316284, - 3, - 3.200000047683716, - 3.4000000953674316, - 3.5999999046325684, - 3.799999952316284, - 4, - 4.400000095367432, - 4.800000190734863, - 5.199999809265137, - 5.599999904632568, - 6, - 6.5, - 7, - 7.5, - 8, - 9, - 10, - 11, - 12, - 13, - 14, - 15, - 17, - 19, - 21, - 23, - 25, - 30, - 35, - 40, - 50 - ] + "values": [ + 0, + 0, + 0.10000000149011612, + 0.20000000298023224, + 0.30000001192092896, + 0.4000000059604645, + 0.5, + 0.6000000238418579, + 0.699999988079071, + 0.800000011920929, + 0.8999999761581421, + 1, + 1.100000023841858, + 1.2000000476837158, + 1.2999999523162842, + 1.399999976158142, + 1.5, + 1.600000023841858, + 1.7000000476837158, + 1.7999999523162842, + 1.899999976158142, + 2, + 2.200000047683716, + 2.4000000953674316, + 2.5999999046325684, + 2.799999952316284, + 3, + 3.200000047683716, + 3.4000000953674316, + 3.5999999046325684, + 3.799999952316284, + 4, + 4.400000095367432, + 4.800000190734863, + 5.199999809265137, + 5.599999904632568, + 6, + 6.5, + 7, + 7.5, + 8, + 9, + 10, + 11, + 12, + 13, + 14, + 15, + 17, + 19, + 21, + 23, + 25, + 30, + 35, + 40, + 50 + ] }, "axisRatioMethods": { - "values": [ - 400, - 0.8999999761581421, - 1.899999976158142 - ] + "values": [ + 400, + 0.8999999761581421, + 1.899999976158142 + ] }, "v0Calibration.qaCosPA": "0.999", "rejectUndefinedTof": "1", "v0Calibration.qaDCADau": "0.5", "axisDeltaTime": { - "values": [ - 2000, - -1000, - 1000 - ] + "values": [ + 2000, + -1000, + 1000 + ] }, "ccdb.ccdb-url": "http://alice-ccdb.cern.ch", "v0Calibration.qaTPCNSigma": "5", "ccdb.lutPath": "GLO/Param/MatLUT", "axisDeltaTimeVsPrimaryCalculation": { - "values": [ - 500, - -500, - 500 - ] + "values": [ + 500, + -500, + 500 + ] }, "axisEta": { - "values": [ - 20, - -1, - 1 - ] + "values": [ + 20, + -1, + 1 + ] }, "axisTimeLong": { - "values": [ - 3000, - -1500000, - 1500000 - ] + "values": [ + 3000, + -1500000, + 1500000 + ] }, "calculationMethod": "0", "calculateCascades": "-1", "cascadeCalibration.qaV0DCADau": "0.5", "axisNSigma": { - "values": [ - 200, - -10, - 10 - ] + "values": [ + 200, + -10, + 10 + ] }, "axisSmallP": { - "values": [ - 250, - 0, - 2.5 - ] + "values": [ + 250, + 0, + 2.5 + ] }, "manualRunNumber": "544122", "calculateV0TOFPIDs": "-1", @@ -138,38 +138,38 @@ "cascadeCalibration.qaCascDCADau": "0.5", "cascadeCalibration.qaMassWindow": "0.005", "axisBCshift": { - "values": [ - 130, - -3006569.541579235, - 237032.45348549983 - ] + "values": [ + 130, + -3006569.541579235, + 237032.45348549983 + ] }, "doBCshift": "1", "useCustomRunNumber": "0", "axisPosition": { - "values": [ - 400, - -400, - 400 - ] + "values": [ + 400, + -400, + 400 + ] }, "processStandardData": "0", "axisTime": { - "values": [ - 400, - 10000, - 50000 - ] + "values": [ + 400, + 10000, + 50000 + ] }, "calculateCascTOFPIDs": "-1", "ccdb.mVtxPath": "GLO/Calib/MeanVertex", "calculateV0TOFDebugs": "-1", "axisSnp": { - "values": [ - 220, - -1.100000023841858, - 1.100000023841858 - ] + "values": [ + 220, + -1.100000023841858, + 1.100000023841858 + ] }, "ccdb.grpmagPath": "GLO/Config/GRPMagField", "ccdb.grpPath": "GLO/GRP/GRP", @@ -209,4 +209,4 @@ "internal-dpl-aod-writer": "", "internal-dpl-aod-global-analysis-file-sink": "", "internal-dpl-injected-dummy-sink": "" -} \ No newline at end of file +} diff --git a/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step4.json b/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step4.json index d3b7adc15c5..e0d4bcfffd5 100644 --- a/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step4.json +++ b/Tutorials/PWGLF/Strangeness/Derived/Analysis/configuration_step4.json @@ -12,123 +12,123 @@ "strangenesstofpid": { "v0Calibration.qaMassWindow": "0.005", "axisP": { - "values": [ - 0, - 0, - 0.10000000149011612, - 0.20000000298023224, - 0.30000001192092896, - 0.4000000059604645, - 0.5, - 0.6000000238418579, - 0.699999988079071, - 0.800000011920929, - 0.8999999761581421, - 1, - 1.100000023841858, - 1.2000000476837158, - 1.2999999523162842, - 1.399999976158142, - 1.5, - 1.600000023841858, - 1.7000000476837158, - 1.7999999523162842, - 1.899999976158142, - 2, - 2.200000047683716, - 2.4000000953674316, - 2.5999999046325684, - 2.799999952316284, - 3, - 3.200000047683716, - 3.4000000953674316, - 3.5999999046325684, - 3.799999952316284, - 4, - 4.400000095367432, - 4.800000190734863, - 5.199999809265137, - 5.599999904632568, - 6, - 6.5, - 7, - 7.5, - 8, - 9, - 10, - 11, - 12, - 13, - 14, - 15, - 17, - 19, - 21, - 23, - 25, - 30, - 35, - 40, - 50 - ] + "values": [ + 0, + 0, + 0.10000000149011612, + 0.20000000298023224, + 0.30000001192092896, + 0.4000000059604645, + 0.5, + 0.6000000238418579, + 0.699999988079071, + 0.800000011920929, + 0.8999999761581421, + 1, + 1.100000023841858, + 1.2000000476837158, + 1.2999999523162842, + 1.399999976158142, + 1.5, + 1.600000023841858, + 1.7000000476837158, + 1.7999999523162842, + 1.899999976158142, + 2, + 2.200000047683716, + 2.4000000953674316, + 2.5999999046325684, + 2.799999952316284, + 3, + 3.200000047683716, + 3.4000000953674316, + 3.5999999046325684, + 3.799999952316284, + 4, + 4.400000095367432, + 4.800000190734863, + 5.199999809265137, + 5.599999904632568, + 6, + 6.5, + 7, + 7.5, + 8, + 9, + 10, + 11, + 12, + 13, + 14, + 15, + 17, + 19, + 21, + 23, + 25, + 30, + 35, + 40, + 50 + ] }, "axisRatioMethods": { - "values": [ - 400, - 0.8999999761581421, - 1.899999976158142 - ] + "values": [ + 400, + 0.8999999761581421, + 1.899999976158142 + ] }, "v0Calibration.qaCosPA": "0.999", "rejectUndefinedTof": "1", "v0Calibration.qaDCADau": "0.5", "axisDeltaTime": { - "values": [ - 2000, - -1000, - 1000 - ] + "values": [ + 2000, + -1000, + 1000 + ] }, "ccdb.ccdb-url": "http://alice-ccdb.cern.ch", "v0Calibration.qaTPCNSigma": "5", "ccdb.lutPath": "GLO/Param/MatLUT", "axisDeltaTimeVsPrimaryCalculation": { - "values": [ - 500, - -500, - 500 - ] + "values": [ + 500, + -500, + 500 + ] }, "axisEta": { - "values": [ - 20, - -1, - 1 - ] + "values": [ + 20, + -1, + 1 + ] }, "axisTimeLong": { - "values": [ - 3000, - -1500000, - 1500000 - ] + "values": [ + 3000, + -1500000, + 1500000 + ] }, "calculationMethod": "0", "calculateCascades": "1", "cascadeCalibration.qaV0DCADau": "0.5", "axisNSigma": { - "values": [ - 200, - -10, - 10 - ] + "values": [ + 200, + -10, + 10 + ] }, "axisSmallP": { - "values": [ - 250, - 0, - 2.5 - ] + "values": [ + 250, + 0, + 2.5 + ] }, "manualRunNumber": "544122", "calculateV0TOFPIDs": "1", @@ -138,38 +138,38 @@ "cascadeCalibration.qaCascDCADau": "0.5", "cascadeCalibration.qaMassWindow": "0.005", "axisBCshift": { - "values": [ - 130, - -3006569.541579235, - 237032.45348549983 - ] + "values": [ + 130, + -3006569.541579235, + 237032.45348549983 + ] }, "doBCshift": "1", "useCustomRunNumber": "0", "axisPosition": { - "values": [ - 400, - -400, - 400 - ] + "values": [ + 400, + -400, + 400 + ] }, "processStandardData": "0", "axisTime": { - "values": [ - 400, - 10000, - 50000 - ] + "values": [ + 400, + 10000, + 50000 + ] }, "calculateCascTOFPIDs": "1", "ccdb.mVtxPath": "GLO/Calib/MeanVertex", "calculateV0TOFDebugs": "1", "axisSnp": { - "values": [ - 220, - -1.100000023841858, - 1.100000023841858 - ] + "values": [ + 220, + -1.100000023841858, + 1.100000023841858 + ] }, "ccdb.grpmagPath": "GLO/Config/GRPMagField", "ccdb.grpPath": "GLO/GRP/GRP", diff --git a/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step3.cxx b/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step3.cxx index 12d3e405447..8885e9ba425 100644 --- a/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step3.cxx +++ b/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step3.cxx @@ -15,12 +15,14 @@ /// \author Nepeivoda Roman (roman.nepeivoda@cern.ch) /// \author Chiara De Martin (chiara.de.martin@cern.ch) -#include "Framework/runDataProcessing.h" -#include "Framework/AnalysisTask.h" -#include "Common/DataModel/EventSelection.h" #include "PWGLF/DataModel/LFStrangenessPIDTables.h" #include "PWGLF/DataModel/LFStrangenessTables.h" +#include "Common/DataModel/EventSelection.h" + +#include "Framework/AnalysisTask.h" +#include "Framework/runDataProcessing.h" + using namespace o2; using namespace o2::framework; using namespace o2::framework::expressions; @@ -218,7 +220,7 @@ struct strangeness_derived_tutorial { rXi.fill(HIST("hCascDCAV0Daughters"), casc.dcaV0daughters()); rXi.fill(HIST("hCascCosPA"), casc.casccosPA(collision.posX(), collision.posY(), collision.posZ())); } - if (std::abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case + if (std::abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case if (std::abs(casc.mXi() - o2::constants::physics::MassXiMinus) > cascadesetting_competingmassrej) { // competing mass rejection, only in case of Omega rOmega.fill(HIST("hMassOmegaSelected"), casc.mOmega()); if (omegaPassTOFSelection) { diff --git a/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step4.cxx b/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step4.cxx index 15c62df40a4..94169733f30 100644 --- a/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step4.cxx +++ b/Tutorials/PWGLF/Strangeness/Derived/Analysis/strangeness_derived_step4.cxx @@ -15,12 +15,14 @@ /// \author Nepeivoda Roman (roman.nepeivoda@cern.ch) /// \author Chiara De Martin (chiara.de.martin@cern.ch) -#include "Framework/runDataProcessing.h" -#include "Framework/AnalysisTask.h" -#include "Common/DataModel/EventSelection.h" #include "PWGLF/DataModel/LFStrangenessPIDTables.h" #include "PWGLF/DataModel/LFStrangenessTables.h" +#include "Common/DataModel/EventSelection.h" + +#include "Framework/AnalysisTask.h" +#include "Framework/runDataProcessing.h" + using namespace o2; using namespace o2::framework; using namespace o2::framework::expressions; @@ -238,7 +240,7 @@ struct strangeness_derived_tutorial { rXi.fill(HIST("hCascDCAV0Daughters"), casc.dcaV0daughters()); rXi.fill(HIST("hCascCosPA"), casc.casccosPA(collision.posX(), collision.posY(), collision.posZ())); } - if (std::abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case + if (std::abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case if (std::abs(casc.mXi() - o2::constants::physics::MassXiMinus) > cascadesetting_competingmassrej) { // competing mass rejection, only in case of Omega rOmega.fill(HIST("hMassOmegaSelected"), casc.mOmega()); if (omegaPassTOFSelection) { @@ -268,7 +270,7 @@ struct strangeness_derived_tutorial { } } if (std::abs(cascmccore.pdgCode()) == PDG_t::kOmegaMinus) { - if (std::abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case + if (std::abs(bachDaughterTrackCasc.tpcNSigmaKa()) < NSigmaTPCKaon) { // Omega case if (std::abs(casc.mXi() - o2::constants::physics::MassXiMinus) > cascadesetting_competingmassrej) { // competing mass rejection, only in case of Omega rOmega.fill(HIST("hMassOmegaTrueRec"), casc.mOmega()); rOmega.fill(HIST("hPtOmegaTrueRec"), casc.pt());