From bdd763e8c29e383ad0734a9ed1d4545380d5f70b Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Tue, 30 Jul 2024 09:56:46 +0200 Subject: [PATCH 01/24] Add proper lnn mass --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index b60db27433d..c7434f916ce 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -58,6 +58,7 @@ std::shared_ptr hCentFT0M; std::shared_ptr hCentFV0A; std::shared_ptr hNsigma3HSel; std::shared_ptr hdEdx3HSel; +std::shared_ptr hdEdx3HTPCMom; std::shared_ptr hdEdxTot; std::shared_ptr hDecayChannel; std::shared_ptr hIsMatterGen; @@ -114,10 +115,10 @@ struct lnnRecoTask { // Selection criteria Configurable v0cospa{"lnncospa", 0.95, "V0 CosPA"}; - Configurable masswidth{"lnnmasswidth", 0.06, "Mass width (GeV/c^2)"}; + Configurable masswidth{"lnnmasswidth", 0.006, "Mass width (GeV/c^2)"}; Configurable dcav0dau{"lnndcaDau", 1.0, "DCA V0 Daughters"}; Configurable ptMin{"ptMin", 0.5, "Minimum pT of the lnncandidate"}; - Configurable TPCRigidityMin3H{"TPCRigidityMin3H", 0.5, "Minimum rigidity of the triton candidate"}; + Configurable TPCRigidityMin3H{"TPCRigidityMin3H", 1, "Minimum rigidity of the triton candidate"}; Configurable etaMax{"eta", 1., "eta daughter"}; Configurable nSigmaMax3H{"nSigmaMax3H", 5, "triton dEdx cut (n sigma)"}; Configurable nTPCClusMin3H{"nTPCClusMin3H", 80, "triton NTPC clusters cut"}; @@ -153,6 +154,7 @@ struct lnnRecoTask { ConfigurableAxis nSigmaBins{"nSigmaBins", {200, -5.f, 5.f}, "Binning for n sigma"}; ConfigurableAxis zVtxBins{"zVtxBins", {100, -20.f, 20.f}, "Binning for n sigma"}; ConfigurableAxis centBins{"centBins", {100, 0.f, 100.f}, "Binning for centrality"}; + ConfigurableAxis TritMomBins {"TritMom", {100, 0.f, 20.f}, "Binning for Triton TPC momentum"}; // std vector of candidates std::vector lnnCandidates; @@ -195,9 +197,11 @@ struct lnnRecoTask { const AxisSpec nSigma3HAxis{nSigmaBins, "n_{#sigma}({}^{3}H)"}; const AxisSpec zVtxAxis{zVtxBins, "z_{vtx} (cm)"}; const AxisSpec centAxis{centBins, "Centrality"}; + const AxisSpec TritMomAxis{TritMomBins, "#it{p}^{TPC}({}^{3}H)"}; hNsigma3HSel = qaRegistry.add("hNsigma3HSel", "; p_{TPC}/z (GeV/#it{c}); n_{#sigma} ({}^{3}H)", HistType::kTH2F, {rigidityAxis, nSigma3HAxis}); hdEdx3HSel = qaRegistry.add("hdEdx3HSel", ";p_{TPC}/z (GeV/#it{c}); dE/dx", HistType::kTH2F, {rigidityAxis, dEdxAxis}); + hdEdx3HTPCMom = qaRegistry.add("hdEdx3HTPCMom", "; #it{p}^{TPC}({}^{3}H); dE/dx", HistType::kTH2F, {TritMomAxis, dEdxAxis}); hdEdxTot = qaRegistry.add("hdEdxTot", ";p_{TPC}/z (GeV/#it{c}); dE/dx", HistType::kTH2F, {rigidityAxis, dEdxAxis}); hEvents = qaRegistry.add("hEvents", ";Events; ", HistType::kTH1D, {{2, -0.5, 1.5}}); @@ -366,7 +370,8 @@ struct lnnRecoTask { } // Definition of lnn mass - float mLNN_HypHI = 2.99; // 2993.7 MeV/c**2 + float mLNN_HypHI = 2.994; // value in GeV, but 2993.7 MeV/c**2 + float massLNNL = std::sqrt(h3lE * h3lE - lnnMom[0] * lnnMom[0] - lnnMom[1] * lnnMom[1] - lnnMom[2] * lnnMom[2]); bool isLNNMass = false; if (massLNNL > mLNN_HypHI - masswidth && massLNNL < mLNN_HypHI + masswidth) { @@ -411,6 +416,10 @@ struct lnnRecoTask { hdEdx3HSel->Fill(chargeFactor * lnnCand.mom3HTPC, h3track.tpcSignal()); hNsigma3HSel->Fill(chargeFactor * lnnCand.mom3HTPC, lnnCand.nSigma3H); lnnCandidates.push_back(lnnCand); + + if (isAnti3H) { + hdEdx3HTPCMom->Fill(lnnCand.mom3HTPC, h3track.tpcSignal()); + } } } @@ -504,6 +513,8 @@ struct lnnRecoTask { void processMC(CollisionsFullMC const& collisions, aod::McCollisions const& mcCollisions, aod::V0s const& V0s, TracksFull const& tracks, aod::BCsWithTimestamps const&, aod::McTrackLabels const& trackLabelsMC, aod::McParticles const& particlesMC) { filledMothers.clear(); + + isGoodCollision.clear(); isGoodCollision.resize(mcCollisions.size(), false); for (const auto& collision : collisions) { @@ -513,7 +524,7 @@ struct lnnRecoTask { hEvents->Fill(0.); - if (std::abs(collision.posZ()) > 10) { + if (std::abs(!collision.sel8() || collision.posZ()) > 10) { continue; } hEvents->Fill(1.); From 7942a2c0361474019ab89821cee1119d661aa5f9 Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Wed, 31 Jul 2024 13:40:40 +0200 Subject: [PATCH 02/24] Fix erros --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 20 +++++--------------- 1 file changed, 5 insertions(+), 15 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index c7434f916ce..be0e51d725a 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -58,7 +58,6 @@ std::shared_ptr hCentFT0M; std::shared_ptr hCentFV0A; std::shared_ptr hNsigma3HSel; std::shared_ptr hdEdx3HSel; -std::shared_ptr hdEdx3HTPCMom; std::shared_ptr hdEdxTot; std::shared_ptr hDecayChannel; std::shared_ptr hIsMatterGen; @@ -115,10 +114,10 @@ struct lnnRecoTask { // Selection criteria Configurable v0cospa{"lnncospa", 0.95, "V0 CosPA"}; - Configurable masswidth{"lnnmasswidth", 0.006, "Mass width (GeV/c^2)"}; + Configurable masswidth{"lnnmasswidth", 0.06, "Mass width (GeV/c^2)"}; Configurable dcav0dau{"lnndcaDau", 1.0, "DCA V0 Daughters"}; Configurable ptMin{"ptMin", 0.5, "Minimum pT of the lnncandidate"}; - Configurable TPCRigidityMin3H{"TPCRigidityMin3H", 1, "Minimum rigidity of the triton candidate"}; + Configurable TPCRigidityMin3H{"TPCRigidityMin3H", 0.5, "Minimum rigidity of the triton candidate"}; Configurable etaMax{"eta", 1., "eta daughter"}; Configurable nSigmaMax3H{"nSigmaMax3H", 5, "triton dEdx cut (n sigma)"}; Configurable nTPCClusMin3H{"nTPCClusMin3H", 80, "triton NTPC clusters cut"}; @@ -154,7 +153,6 @@ struct lnnRecoTask { ConfigurableAxis nSigmaBins{"nSigmaBins", {200, -5.f, 5.f}, "Binning for n sigma"}; ConfigurableAxis zVtxBins{"zVtxBins", {100, -20.f, 20.f}, "Binning for n sigma"}; ConfigurableAxis centBins{"centBins", {100, 0.f, 100.f}, "Binning for centrality"}; - ConfigurableAxis TritMomBins {"TritMom", {100, 0.f, 20.f}, "Binning for Triton TPC momentum"}; // std vector of candidates std::vector lnnCandidates; @@ -197,11 +195,9 @@ struct lnnRecoTask { const AxisSpec nSigma3HAxis{nSigmaBins, "n_{#sigma}({}^{3}H)"}; const AxisSpec zVtxAxis{zVtxBins, "z_{vtx} (cm)"}; const AxisSpec centAxis{centBins, "Centrality"}; - const AxisSpec TritMomAxis{TritMomBins, "#it{p}^{TPC}({}^{3}H)"}; hNsigma3HSel = qaRegistry.add("hNsigma3HSel", "; p_{TPC}/z (GeV/#it{c}); n_{#sigma} ({}^{3}H)", HistType::kTH2F, {rigidityAxis, nSigma3HAxis}); hdEdx3HSel = qaRegistry.add("hdEdx3HSel", ";p_{TPC}/z (GeV/#it{c}); dE/dx", HistType::kTH2F, {rigidityAxis, dEdxAxis}); - hdEdx3HTPCMom = qaRegistry.add("hdEdx3HTPCMom", "; #it{p}^{TPC}({}^{3}H); dE/dx", HistType::kTH2F, {TritMomAxis, dEdxAxis}); hdEdxTot = qaRegistry.add("hdEdxTot", ";p_{TPC}/z (GeV/#it{c}); dE/dx", HistType::kTH2F, {rigidityAxis, dEdxAxis}); hEvents = qaRegistry.add("hEvents", ";Events; ", HistType::kTH1D, {{2, -0.5, 1.5}}); @@ -370,8 +366,7 @@ struct lnnRecoTask { } // Definition of lnn mass - float mLNN_HypHI = 2.994; // value in GeV, but 2993.7 MeV/c**2 - + float mLNN_HypHI = 2.99; // 2993.7 MeV/c**2 float massLNNL = std::sqrt(h3lE * h3lE - lnnMom[0] * lnnMom[0] - lnnMom[1] * lnnMom[1] - lnnMom[2] * lnnMom[2]); bool isLNNMass = false; if (massLNNL > mLNN_HypHI - masswidth && massLNNL < mLNN_HypHI + masswidth) { @@ -416,10 +411,6 @@ struct lnnRecoTask { hdEdx3HSel->Fill(chargeFactor * lnnCand.mom3HTPC, h3track.tpcSignal()); hNsigma3HSel->Fill(chargeFactor * lnnCand.mom3HTPC, lnnCand.nSigma3H); lnnCandidates.push_back(lnnCand); - - if (isAnti3H) { - hdEdx3HTPCMom->Fill(lnnCand.mom3HTPC, h3track.tpcSignal()); - } } } @@ -513,8 +504,7 @@ struct lnnRecoTask { void processMC(CollisionsFullMC const& collisions, aod::McCollisions const& mcCollisions, aod::V0s const& V0s, TracksFull const& tracks, aod::BCsWithTimestamps const&, aod::McTrackLabels const& trackLabelsMC, aod::McParticles const& particlesMC) { filledMothers.clear(); - - isGoodCollision.clear(); + IsGoodCollision.clear() isGoodCollision.resize(mcCollisions.size(), false); for (const auto& collision : collisions) { @@ -524,7 +514,7 @@ struct lnnRecoTask { hEvents->Fill(0.); - if (std::abs(!collision.sel8() || collision.posZ()) > 10) { + if (std::abs(collision.posZ()) > 10) { continue; } hEvents->Fill(1.); From 98d4d0bad3eacf2047f05677dabd88b520eddc6a Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Wed, 31 Jul 2024 14:38:11 +0200 Subject: [PATCH 03/24] Fix isGoodCollision.clear() error --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index be0e51d725a..5d77d291d94 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -504,7 +504,7 @@ struct lnnRecoTask { void processMC(CollisionsFullMC const& collisions, aod::McCollisions const& mcCollisions, aod::V0s const& V0s, TracksFull const& tracks, aod::BCsWithTimestamps const&, aod::McTrackLabels const& trackLabelsMC, aod::McParticles const& particlesMC) { filledMothers.clear(); - IsGoodCollision.clear() + isGoodCollision.clear() isGoodCollision.resize(mcCollisions.size(), false); for (const auto& collision : collisions) { From 17ed7762ffdcd641e2688c77412022a1937dfa49 Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Wed, 31 Jul 2024 16:41:42 +0200 Subject: [PATCH 04/24] Fix erros and include RMSMean configurable --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 23 ++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index 5d77d291d94..1d7befac9c5 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -58,6 +58,7 @@ std::shared_ptr hCentFT0M; std::shared_ptr hCentFV0A; std::shared_ptr hNsigma3HSel; std::shared_ptr hdEdx3HSel; +std::shared_ptr hdEdx3HTPCMom; std::shared_ptr hdEdxTot; std::shared_ptr hDecayChannel; std::shared_ptr hIsMatterGen; @@ -114,14 +115,15 @@ struct lnnRecoTask { // Selection criteria Configurable v0cospa{"lnncospa", 0.95, "V0 CosPA"}; - Configurable masswidth{"lnnmasswidth", 0.06, "Mass width (GeV/c^2)"}; + Configurable masswidth{"lnnmasswidth", 0.006, "Mass width (GeV/c^2)"}; Configurable dcav0dau{"lnndcaDau", 1.0, "DCA V0 Daughters"}; Configurable ptMin{"ptMin", 0.5, "Minimum pT of the lnncandidate"}; - Configurable TPCRigidityMin3H{"TPCRigidityMin3H", 0.5, "Minimum rigidity of the triton candidate"}; + Configurable TPCRigidityMin3H{"TPCRigidityMin3H", 1, "Minimum rigidity of the triton candidate"}; Configurable etaMax{"eta", 1., "eta daughter"}; Configurable nSigmaMax3H{"nSigmaMax3H", 5, "triton dEdx cut (n sigma)"}; Configurable nTPCClusMin3H{"nTPCClusMin3H", 80, "triton NTPC clusters cut"}; Configurable mcSignalOnly{"mcSignalOnly", true, "If true, save only signal in MC"}; + Configurable RMSMean{"RMS/Mean", 0.07, "RMS/Mean"}; // Define o2 fitter, 2-prong, active memory (no need to redefine per event) o2::vertexing::DCAFitterN<2> fitter; @@ -153,6 +155,7 @@ struct lnnRecoTask { ConfigurableAxis nSigmaBins{"nSigmaBins", {200, -5.f, 5.f}, "Binning for n sigma"}; ConfigurableAxis zVtxBins{"zVtxBins", {100, -20.f, 20.f}, "Binning for n sigma"}; ConfigurableAxis centBins{"centBins", {100, 0.f, 100.f}, "Binning for centrality"}; + ConfigurableAxis TritMomBins {"TritMom", {100, 0.f, 20.f}, "Binning for Triton TPC momentum"}; // std vector of candidates std::vector lnnCandidates; @@ -195,9 +198,11 @@ struct lnnRecoTask { const AxisSpec nSigma3HAxis{nSigmaBins, "n_{#sigma}({}^{3}H)"}; const AxisSpec zVtxAxis{zVtxBins, "z_{vtx} (cm)"}; const AxisSpec centAxis{centBins, "Centrality"}; + const AxisSpec TritMomAxis{TritMomBins, "#it{p}^{TPC}({}^{3}H)"}; hNsigma3HSel = qaRegistry.add("hNsigma3HSel", "; p_{TPC}/z (GeV/#it{c}); n_{#sigma} ({}^{3}H)", HistType::kTH2F, {rigidityAxis, nSigma3HAxis}); hdEdx3HSel = qaRegistry.add("hdEdx3HSel", ";p_{TPC}/z (GeV/#it{c}); dE/dx", HistType::kTH2F, {rigidityAxis, dEdxAxis}); + hdEdx3HTPCMom = qaRegistry.add("hdEdx3HTPCMom", "; #it{p}^{TPC}({}^{3}H); dE/dx", HistType::kTH2F, {TritMomAxis, dEdxAxis}); hdEdxTot = qaRegistry.add("hdEdxTot", ";p_{TPC}/z (GeV/#it{c}); dE/dx", HistType::kTH2F, {rigidityAxis, dEdxAxis}); hEvents = qaRegistry.add("hEvents", ";Events; ", HistType::kTH1D, {{2, -0.5, 1.5}}); @@ -366,7 +371,8 @@ struct lnnRecoTask { } // Definition of lnn mass - float mLNN_HypHI = 2.99; // 2993.7 MeV/c**2 + float mLNN_HypHI = 2.994; // value in GeV, but 2993.7 MeV/c**2 + float massLNNL = std::sqrt(h3lE * h3lE - lnnMom[0] * lnnMom[0] - lnnMom[1] * lnnMom[1] - lnnMom[2] * lnnMom[2]); bool isLNNMass = false; if (massLNNL > mLNN_HypHI - masswidth && massLNNL < mLNN_HypHI + masswidth) { @@ -411,6 +417,10 @@ struct lnnRecoTask { hdEdx3HSel->Fill(chargeFactor * lnnCand.mom3HTPC, h3track.tpcSignal()); hNsigma3HSel->Fill(chargeFactor * lnnCand.mom3HTPC, lnnCand.nSigma3H); lnnCandidates.push_back(lnnCand); + + if (isAnti3H) { + hdEdx3HTPCMom->Fill(lnnCand.mom3HTPC, h3track.tpcSignal()); + } } } @@ -468,7 +478,7 @@ struct lnnRecoTask { initCCDB(bc); hEvents->Fill(0.); - if (!collision.sel8() || std::abs(collision.posZ()) > 10) { + if ((!collision.sel8()) || std::abs(collision.posZ()) > 10) { continue; } hEvents->Fill(1.); @@ -504,7 +514,8 @@ struct lnnRecoTask { void processMC(CollisionsFullMC const& collisions, aod::McCollisions const& mcCollisions, aod::V0s const& V0s, TracksFull const& tracks, aod::BCsWithTimestamps const&, aod::McTrackLabels const& trackLabelsMC, aod::McParticles const& particlesMC) { filledMothers.clear(); - isGoodCollision.clear() + + isGoodCollision.clear(); isGoodCollision.resize(mcCollisions.size(), false); for (const auto& collision : collisions) { @@ -514,7 +525,7 @@ struct lnnRecoTask { hEvents->Fill(0.); - if (std::abs(collision.posZ()) > 10) { + if (std::abs(!collision.sel8()) || (collision.posZ()) > 10) { continue; } hEvents->Fill(1.); From 40e41e2db9d17fe5e9f6e9810a45e9bdf462313d Mon Sep 17 00:00:00 2001 From: ALICE Action Bot Date: Wed, 31 Jul 2024 14:42:37 +0000 Subject: [PATCH 05/24] Please consider the following formatting changes --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index 1d7befac9c5..510bbdb09d1 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -155,7 +155,7 @@ struct lnnRecoTask { ConfigurableAxis nSigmaBins{"nSigmaBins", {200, -5.f, 5.f}, "Binning for n sigma"}; ConfigurableAxis zVtxBins{"zVtxBins", {100, -20.f, 20.f}, "Binning for n sigma"}; ConfigurableAxis centBins{"centBins", {100, 0.f, 100.f}, "Binning for centrality"}; - ConfigurableAxis TritMomBins {"TritMom", {100, 0.f, 20.f}, "Binning for Triton TPC momentum"}; + ConfigurableAxis TritMomBins{"TritMom", {100, 0.f, 20.f}, "Binning for Triton TPC momentum"}; // std vector of candidates std::vector lnnCandidates; From 3e4d333bc18b0b73b33d7cd23585d7319b9f3721 Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Thu, 1 Aug 2024 10:25:37 +0200 Subject: [PATCH 06/24] Fix error 3 --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index 1d7befac9c5..edc4967e7c6 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -120,10 +120,10 @@ struct lnnRecoTask { Configurable ptMin{"ptMin", 0.5, "Minimum pT of the lnncandidate"}; Configurable TPCRigidityMin3H{"TPCRigidityMin3H", 1, "Minimum rigidity of the triton candidate"}; Configurable etaMax{"eta", 1., "eta daughter"}; - Configurable nSigmaMax3H{"nSigmaMax3H", 5, "triton dEdx cut (n sigma)"}; + Configurable nSigmaMax3H{"nSigmaMax3H", 0.07, "triton dEdx cut (n sigma)"}; Configurable nTPCClusMin3H{"nTPCClusMin3H", 80, "triton NTPC clusters cut"}; Configurable mcSignalOnly{"mcSignalOnly", true, "If true, save only signal in MC"}; - Configurable RMSMean{"RMS/Mean", 0.07, "RMS/Mean"}; + //Configurable RMSMean{"RMSMean", 0.07, "RMS Mean"}; // Define o2 fitter, 2-prong, active memory (no need to redefine per event) o2::vertexing::DCAFitterN<2> fitter; @@ -163,6 +163,7 @@ struct lnnRecoTask { std::vector filledMothers; // vector to keep track of the collisions passing the event selection in the MC std::vector isGoodCollision; + // vector to armazenade h3Track Preslice perCollision = o2::aod::v0::collisionId; @@ -525,7 +526,7 @@ struct lnnRecoTask { hEvents->Fill(0.); - if (std::abs(!collision.sel8()) || (collision.posZ()) > 10) { + if ((collision.posZ()) > 10) { continue; } hEvents->Fill(1.); From caa2bd683794963d3af9b21d068ccc0174480744 Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Thu, 1 Aug 2024 10:30:05 +0200 Subject: [PATCH 07/24] Correction of NSigma3HMax --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index 13a2c0240f6..e773df317fd 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -120,7 +120,7 @@ struct lnnRecoTask { Configurable ptMin{"ptMin", 0.5, "Minimum pT of the lnncandidate"}; Configurable TPCRigidityMin3H{"TPCRigidityMin3H", 1, "Minimum rigidity of the triton candidate"}; Configurable etaMax{"eta", 1., "eta daughter"}; - Configurable nSigmaMax3H{"nSigmaMax3H", 0.07, "triton dEdx cut (n sigma)"}; + Configurable nSigmaMax3H{"nSigmaMax3H", 5, "triton dEdx cut (n sigma)"}; Configurable nTPCClusMin3H{"nTPCClusMin3H", 80, "triton NTPC clusters cut"}; Configurable mcSignalOnly{"mcSignalOnly", true, "If true, save only signal in MC"}; //Configurable RMSMean{"RMSMean", 0.07, "RMS Mean"}; From fd38c5a4d1d54648238b4720f68cc7055b211408 Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Fri, 2 Aug 2024 17:00:57 +0200 Subject: [PATCH 08/24] correction bug in std::abs(collision.posZ()) > 10 and add is3H selection --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index e773df317fd..096725d57e0 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -419,7 +419,7 @@ struct lnnRecoTask { hNsigma3HSel->Fill(chargeFactor * lnnCand.mom3HTPC, lnnCand.nSigma3H); lnnCandidates.push_back(lnnCand); - if (isAnti3H) { + if (is3H) { hdEdx3HTPCMom->Fill(lnnCand.mom3HTPC, h3track.tpcSignal()); } } @@ -526,7 +526,7 @@ struct lnnRecoTask { hEvents->Fill(0.); - if ((collision.posZ()) > 10) { + if (std::abs(collision.posZ()) > 10) { continue; } hEvents->Fill(1.); From 1e2433f82a983f37b25e9d75026d5bfcceceacdf Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Tue, 13 Aug 2024 17:59:09 +0200 Subject: [PATCH 09/24] Rebinning rigidity values --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index 096725d57e0..4da5bf176ee 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -150,7 +150,7 @@ struct lnnRecoTask { Configurable lnnPdg{"lnnPdg", 1010000030, "PDG Lnn"}; // PDG Lnn // histogram axes - ConfigurableAxis rigidityBins{"rigidityBins", {200, -10.f, 10.f}, "Binning for rigidity #it{p}^{TPC}/#it{z}"}; + ConfigurableAxis rigidityBins{"rigidityBins", {200, -5.f, 5.f}, "Binning for rigidity #it{p}^{TPC}/#it{z}"}; ConfigurableAxis dEdxBins{"dEdxBins", {1000, 0.f, 1000.f}, "Binning for dE/dx"}; ConfigurableAxis nSigmaBins{"nSigmaBins", {200, -5.f, 5.f}, "Binning for n sigma"}; ConfigurableAxis zVtxBins{"zVtxBins", {100, -20.f, 20.f}, "Binning for n sigma"}; From c985f79e073c291811e9df4ca5874039b68e4800 Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Tue, 13 Aug 2024 18:42:40 +0200 Subject: [PATCH 10/24] Fix bugs due to merge conflits --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 5 ----- 1 file changed, 5 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index bc56340fb6e..544d1636e1f 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -123,11 +123,6 @@ struct lnnRecoTask { Configurable nSigmaMax3H{"nSigmaMax3H", 5, "triton dEdx cut (n sigma)"}; Configurable nTPCClusMin3H{"nTPCClusMin3H", 80, "triton NTPC clusters cut"}; Configurable mcSignalOnly{"mcSignalOnly", true, "If true, save only signal in MC"}; -<<<<<<< HEAD - //Configurable RMSMean{"RMSMean", 0.07, "RMS Mean"}; -======= - // Configurable RMSMean{"RMSMean", 0.07, "RMS Mean"}; ->>>>>>> 353b897c509ed1531607265e7066e069285d1393 // Define o2 fitter, 2-prong, active memory (no need to redefine per event) o2::vertexing::DCAFitterN<2> fitter; From d89ae56841ba4f224ad12e52921561910261eb7f Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Wed, 14 Aug 2024 09:49:26 +0200 Subject: [PATCH 11/24] Rebinning dEdx and dEdX3H plots --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index 544d1636e1f..86f0609f662 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -149,12 +149,12 @@ struct lnnRecoTask { Configurable lnnPdg{"lnnPdg", 1010000030, "PDG Lnn"}; // PDG Lnn // histogram axes - ConfigurableAxis rigidityBins{"rigidityBins", {200, -5.f, 5.f}, "Binning for rigidity #it{p}^{TPC}/#it{z}"}; + ConfigurableAxis rigidityBins{"rigidityBins", {200, -6.f, 6.f}, "Binning for rigidity #it{p}^{TPC}/#it{z}"}; ConfigurableAxis dEdxBins{"dEdxBins", {1000, 0.f, 1000.f}, "Binning for dE/dx"}; ConfigurableAxis nSigmaBins{"nSigmaBins", {200, -5.f, 5.f}, "Binning for n sigma"}; ConfigurableAxis zVtxBins{"zVtxBins", {100, -20.f, 20.f}, "Binning for n sigma"}; ConfigurableAxis centBins{"centBins", {100, 0.f, 100.f}, "Binning for centrality"}; - ConfigurableAxis TritMomBins{"TritMom", {100, 0.f, 20.f}, "Binning for Triton TPC momentum"}; + ConfigurableAxis TritMomBins{"TritMom", {100, 0.f, 6.f}, "Binning for Triton TPC momentum"}; // std vector of candidates std::vector lnnCandidates; From 08630956b756c6f13ccbb5f803de1ea08ba20b42 Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Mon, 26 Aug 2024 10:44:19 +0200 Subject: [PATCH 12/24] new selection to NSigmaMax3H and NSigmaMin3H --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index 86f0609f662..cfa7c271afa 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -120,7 +120,8 @@ struct lnnRecoTask { Configurable ptMin{"ptMin", 0.5, "Minimum pT of the lnncandidate"}; Configurable TPCRigidityMin3H{"TPCRigidityMin3H", 1, "Minimum rigidity of the triton candidate"}; Configurable etaMax{"eta", 1., "eta daughter"}; - Configurable nSigmaMax3H{"nSigmaMax3H", 5, "triton dEdx cut (n sigma)"}; + Configurable nSigmaMin3H{"nSigmaMin3H", -2., "triton dEdx cut (n sigma)"}; + Configurable nSigmaMax3H{"nSigmaMax3H", 3.5, "triton dEdx cut (n sigma)"}; Configurable nTPCClusMin3H{"nTPCClusMin3H", 80, "triton NTPC clusters cut"}; Configurable mcSignalOnly{"mcSignalOnly", true, "If true, save only signal in MC"}; @@ -302,8 +303,8 @@ struct lnnRecoTask { auto nSigmaTPCneg = static_cast((negTrack.tpcSignal() - expBetheNeg) / expSigmaNeg); // ITS only tracks do not have TPC information. TPCnSigma: only lower cut to allow for triton reconstruction - bool is3H = posTrack.hasTPC() && nSigmaTPCpos > -1 * nSigmaMax3H; - bool isAnti3H = negTrack.hasTPC() && nSigmaTPCneg > -1 * nSigmaMax3H; + bool is3H = posTrack.hasTPC() && nSigmaMin3H < nSigmaTPCpos > nSigmaMax3H; + bool isAnti3H = negTrack.hasTPC() && nSigmaMin3H < nSigmaTPCneg > nSigmaMax3H; if (!is3H && !isAnti3H) continue; From 559cb787c0cbed050b6bc7514c67e5f65e99fe48 Mon Sep 17 00:00:00 2001 From: ALICE Action Bot Date: Mon, 26 Aug 2024 08:55:27 +0000 Subject: [PATCH 13/24] Please consider the following formatting changes --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index cfa7c271afa..75abb8c56db 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -303,8 +303,8 @@ struct lnnRecoTask { auto nSigmaTPCneg = static_cast((negTrack.tpcSignal() - expBetheNeg) / expSigmaNeg); // ITS only tracks do not have TPC information. TPCnSigma: only lower cut to allow for triton reconstruction - bool is3H = posTrack.hasTPC() && nSigmaMin3H < nSigmaTPCpos > nSigmaMax3H; - bool isAnti3H = negTrack.hasTPC() && nSigmaMin3H < nSigmaTPCneg > nSigmaMax3H; + bool is3H = posTrack.hasTPC() && nSigmaMin3H nSigmaMax3H; + bool isAnti3H = negTrack.hasTPC() && nSigmaMin3H nSigmaMax3H; if (!is3H && !isAnti3H) continue; From a31c6e973177beb4e4e5c54fce7c5d5b1f88177d Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Mon, 26 Aug 2024 11:47:35 +0200 Subject: [PATCH 14/24] fix sintaxe of nSigmaTPC to 3H selection --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index cfa7c271afa..f6834261ae4 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -303,8 +303,8 @@ struct lnnRecoTask { auto nSigmaTPCneg = static_cast((negTrack.tpcSignal() - expBetheNeg) / expSigmaNeg); // ITS only tracks do not have TPC information. TPCnSigma: only lower cut to allow for triton reconstruction - bool is3H = posTrack.hasTPC() && nSigmaMin3H < nSigmaTPCpos > nSigmaMax3H; - bool isAnti3H = negTrack.hasTPC() && nSigmaMin3H < nSigmaTPCneg > nSigmaMax3H; + bool is3H = posTrack.hasTPC() && nSigmaMin3H < nSigmaTPCpos && nSigmaTPCpos < nSigmaMax3H; + bool isAnti3H = negTrack.hasTPC() && nSigmaMin3H < nSigmaTPCpos && nSigmaTPCpos < nSigmaMax3H; if (!is3H && !isAnti3H) continue; From 967e0bce48c2cbc728428d0f24b25276c1ef8cce Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Mon, 26 Aug 2024 13:45:01 +0200 Subject: [PATCH 15/24] fix merge conflict --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 5 ----- 1 file changed, 5 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index 1679da046e3..f6834261ae4 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -303,13 +303,8 @@ struct lnnRecoTask { auto nSigmaTPCneg = static_cast((negTrack.tpcSignal() - expBetheNeg) / expSigmaNeg); // ITS only tracks do not have TPC information. TPCnSigma: only lower cut to allow for triton reconstruction -<<<<<<< HEAD bool is3H = posTrack.hasTPC() && nSigmaMin3H < nSigmaTPCpos && nSigmaTPCpos < nSigmaMax3H; bool isAnti3H = negTrack.hasTPC() && nSigmaMin3H < nSigmaTPCpos && nSigmaTPCpos < nSigmaMax3H; -======= - bool is3H = posTrack.hasTPC() && nSigmaMin3H nSigmaMax3H; - bool isAnti3H = negTrack.hasTPC() && nSigmaMin3H nSigmaMax3H; ->>>>>>> a27d1f563a9adb3c9c19b87932dde943daa0bb6d if (!is3H && !isAnti3H) continue; From 70597c2b6fd40b5457e020d6a74db01459edc71c Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Wed, 11 Sep 2024 17:44:00 +0200 Subject: [PATCH 16/24] Add new track selections to tritons --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 107 ++++++++++++++++----- 1 file changed, 83 insertions(+), 24 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index f6834261ae4..b1b897d9883 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -12,6 +12,7 @@ // Build \Lambda-n-n candidates from V0s and tracks // ============================================================================== #include +#include #include "Framework/runDataProcessing.h" #include "Framework/AnalysisTask.h" @@ -30,26 +31,38 @@ #include "DataFormatsParameters/GRPMagField.h" #include "CCDB/BasicCCDBManager.h" +#include "Common/DataModel/PIDResponse.h" +#include "Common/DataModel/TrackSelectionTables.h" +#include "Common/Core/trackUtilities.h" + + + #include "Common/Core/PID/TPCPIDResponse.h" #include "DataFormatsTPC/BetheBlochAleph.h" #include "DCAFitter/DCAFitterN.h" +#include "Common/Core/PID/PIDTOF.h" +#include "Common/TableProducer/PID/pidTOFBase.h" + #include "PWGLF/DataModel/LFLnnTables.h" using namespace o2; using namespace o2::framework; using namespace o2::framework::expressions; using std::array; -using TracksFull = soa::Join; +using TracksFull = soa::Join; +using TracksFullMC = soa::Join; using CollisionsFull = soa::Join; using CollisionsFullMC = soa::Join; +o2::pid::tof::Beta responseBeta; +o2::pid::tof::Beta responseBetaMC; + namespace { constexpr double betheBlochDefault[1][6]{{-1.e32, -1.e32, -1.e32, -1.e32, -1.e32, -1.e32}}; static const std::vector betheBlochParNames{"p0", "p1", "p2", "p3", "p4", "resolution"}; -static const std::vector particleNames{"3H"}; - +static const std::vector NucleiName{"3H"}; std::shared_ptr hEvents; std::shared_ptr hZvtx; std::shared_ptr hCentFT0A; @@ -87,6 +100,7 @@ struct lnnCandidate { float piDCAXY = -10; float mom3HTPC = -10.f; float momPiTPC = -10.f; + float massTrTOF = 10.f; std::array mom3H; std::array momPi; std::array decVtx; @@ -117,13 +131,24 @@ struct lnnRecoTask { Configurable v0cospa{"lnncospa", 0.95, "V0 CosPA"}; Configurable masswidth{"lnnmasswidth", 0.006, "Mass width (GeV/c^2)"}; Configurable dcav0dau{"lnndcaDau", 1.0, "DCA V0 Daughters"}; + Configurable dcaToPvPion{"dcapvPi", 0., "DCA to PV pion"}; + Configurable dcaXY{"cutDCAXY", 2.0, "DCAxy range for tracks"}; + Configurable Chi2nClusTPC{"Chi2NClusTPC", 4., "Chi2 / nClusTPC for triton track"}; + Configurable Chi2nClusITS{"Chi2NClusITS", 36., "Chi2 / nClusITS for triton track"}; Configurable ptMin{"ptMin", 0.5, "Minimum pT of the lnncandidate"}; - Configurable TPCRigidityMin3H{"TPCRigidityMin3H", 1, "Minimum rigidity of the triton candidate"}; - Configurable etaMax{"eta", 1., "eta daughter"}; - Configurable nSigmaMin3H{"nSigmaMin3H", -2., "triton dEdx cut (n sigma)"}; - Configurable nSigmaMax3H{"nSigmaMax3H", 3.5, "triton dEdx cut (n sigma)"}; + Configurable etaMax{"eta", 0.8, "eta daughter"}; + Configurable yMax{"rapidityPos", 0.5, "track rapidity pos"}; + Configurable yMin{"rapidityNeg", -0.5, "track rapidity neg"}; + Configurable TPCRigidityMin3H{"TPCRigidityMin3H", 0.5, "Minimum rigidity of the triton candidate"}; + Configurable nSigmaCutTPC{"nSigmaCutTPC", 4., "triton dEdx cut (n sigma)"}; Configurable nTPCClusMin3H{"nTPCClusMin3H", 80, "triton NTPC clusters cut"}; + Configurable nTPCClusMinPi{"nTPCClusMinPi", -1., "pion NTPC clusters cut"}; + Configurable nClusITS{"nClusITSMin3H", 5.0, "triton NITS clusters cut"}; + Configurable nClusTPCRows{"nClusTPCRows", 70., "Number of crossed TPC Rows"}; Configurable mcSignalOnly{"mcSignalOnly", true, "If true, save only signal in MC"}; + Configurable isTPCRefit{"TPCRefit", true, "if true, select the tracks"}; + Configurable isITSRefit{"ITSRefit", true, "if true, select the tracks"}; + //Configurable RMSMean{"RMSMean", 0.07, "RMS Mean"}; // Define o2 fitter, 2-prong, active memory (no need to redefine per event) o2::vertexing::DCAFitterN<2> fitter; @@ -133,7 +158,7 @@ struct lnnRecoTask { float piMass = o2::constants::physics::MassPionCharged; // bethe bloch parameters - Configurable> cfgBetheBlochParams{"cfgBetheBlochParams", {betheBlochDefault[0], 1, 6, particleNames, betheBlochParNames}, "TPC Bethe-Bloch parameterisation for 3H"}; + Configurable> cfgBetheBlochParams{"cfgBetheBlochParams", {betheBlochDefault[0], 1, 6, NucleiName, betheBlochParNames}, "TPC Bethe-Bloch parameterisation for 3H"}; Configurable cfgMaterialCorrection{"cfgMaterialCorrection", static_cast(o2::base::Propagator::MatCorrType::USEMatCorrNONE), "Type of material correction"}; // CCDB options @@ -150,12 +175,12 @@ struct lnnRecoTask { Configurable lnnPdg{"lnnPdg", 1010000030, "PDG Lnn"}; // PDG Lnn // histogram axes - ConfigurableAxis rigidityBins{"rigidityBins", {200, -6.f, 6.f}, "Binning for rigidity #it{p}^{TPC}/#it{z}"}; - ConfigurableAxis dEdxBins{"dEdxBins", {1000, 0.f, 1000.f}, "Binning for dE/dx"}; + ConfigurableAxis rigidityBins{"rigidityBins", {200, -10.f, 10.f}, "Binning for rigidity #it{p}^{TPC}/#it{z}"}; + ConfigurableAxis dEdxBins{"dEdxBins", {5000, 0.f, 1000.f}, "Binning for dE/dx"}; ConfigurableAxis nSigmaBins{"nSigmaBins", {200, -5.f, 5.f}, "Binning for n sigma"}; ConfigurableAxis zVtxBins{"zVtxBins", {100, -20.f, 20.f}, "Binning for n sigma"}; ConfigurableAxis centBins{"centBins", {100, 0.f, 100.f}, "Binning for centrality"}; - ConfigurableAxis TritMomBins{"TritMom", {100, 0.f, 6.f}, "Binning for Triton TPC momentum"}; + ConfigurableAxis TritMomBins{"TritMom", {100, 0.f, 10.f}, "Binning for Triton TPC momentum"}; // std vector of candidates std::vector lnnCandidates; @@ -279,15 +304,30 @@ struct lnnRecoTask { if (mBBparams3H[5] < 0) { LOG(fatal) << "Bethe-Bloch parameters for 3H not set, please check your CCDB and configuration"; } + + TLorentzVector LorentzV_Triton{}; + TLorentzVector LorentzV_AntiTriton{}; + for (auto& v0 : V0s) { auto posTrack = v0.posTrack_as(); auto negTrack = v0.negTrack_as(); + LorentzV_Triton.SetPtEtaPhiM(posTrack.pt(), posTrack.eta(), posTrack.phi(), constants::physics::MassTriton); + LorentzV_AntiTriton.SetPtEtaPhiM(negTrack.pt(), negTrack.eta(), negTrack.phi(), constants::physics::MassTriton); + if (std::abs(posTrack.eta()) > etaMax || std::abs(negTrack.eta()) > etaMax) { continue; } + + if (std::abs(LorentzV_Triton.Rapidity()) > yMax) { + continue; + } + if (std::abs(LorentzV_AntiTriton.Rapidity()) > yMax) { + continue; + } + float posRigidity = posTrack.tpcInnerParam(); float negRigidity = negTrack.tpcInnerParam(); @@ -303,8 +343,8 @@ struct lnnRecoTask { auto nSigmaTPCneg = static_cast((negTrack.tpcSignal() - expBetheNeg) / expSigmaNeg); // ITS only tracks do not have TPC information. TPCnSigma: only lower cut to allow for triton reconstruction - bool is3H = posTrack.hasTPC() && nSigmaMin3H < nSigmaTPCpos && nSigmaTPCpos < nSigmaMax3H; - bool isAnti3H = negTrack.hasTPC() && nSigmaMin3H < nSigmaTPCpos && nSigmaTPCpos < nSigmaMax3H; + bool is3H = posTrack.hasTPC() && nSigmaTPCpos > -1 * nSigmaCutTPC; + bool isAnti3H = negTrack.hasTPC() && nSigmaTPCneg > -1 * nSigmaCutTPC; if (!is3H && !isAnti3H) continue; @@ -312,19 +352,27 @@ struct lnnRecoTask { // Describing lnn as matter candidate lnnCandidate lnnCand; lnnCand.isMatter = is3H && isAnti3H ? std::abs(nSigmaTPCpos) < std::abs(nSigmaTPCneg) : is3H; - auto& h3track = lnnCand.isMatter ? posTrack : negTrack; + auto& h3track = lnnCand.isMatter ? posTrack : negTrack; auto& h3Rigidity = lnnCand.isMatter ? posRigidity : negRigidity; - if (h3track.tpcNClsFound() < nTPCClusMin3H || h3Rigidity < TPCRigidityMin3H) { + + if (h3Rigidity < TPCRigidityMin3H || + h3track.tpcNClsFound() < nTPCClusMin3H || + h3track.tpcChi2NCl() > Chi2nClusTPC || + h3track.itsChi2NCl() > Chi2nClusITS || + h3track.itsNCls() < nClusITS || + h3track.tpcNClsCrossedRows() < nClusTPCRows || + h3track.tpcNClsCrossedRows() < 0.8 * h3track.tpcNClsFindable() || + !h3track.passedTPCRefit() || + !h3track.passedITSRefit()) { continue; } lnnCand.nSigma3H = lnnCand.isMatter ? nSigmaTPCpos : nSigmaTPCneg; - lnnCand.nTPCClusters3H = lnnCand.isMatter ? posTrack.tpcNClsFound() : negTrack.tpcNClsFound(); - lnnCand.tpcSignal3H = lnnCand.isMatter ? posTrack.tpcSignal() : negTrack.tpcSignal(); - lnnCand.clusterSizeITS3H = lnnCand.isMatter ? posTrack.itsClusterSizes() : negTrack.itsClusterSizes(); - lnnCand.nTPCClustersPi = !lnnCand.isMatter ? posTrack.tpcNClsFound() : negTrack.tpcNClsFound(); - lnnCand.tpcSignalPi = !lnnCand.isMatter ? posTrack.tpcSignal() : negTrack.tpcSignal(); - lnnCand.clusterSizeITSPi = !lnnCand.isMatter ? posTrack.itsClusterSizes() : negTrack.itsClusterSizes(); + lnnCand.nTPCClusters3H = lnnCand.isMatter ? h3track.tpcNClsFound() : negTrack.tpcNClsFound(); + lnnCand.clusterSizeITS3H = lnnCand.isMatter ? h3track.itsClusterSizes() : negTrack.itsClusterSizes(); + lnnCand.nTPCClustersPi = !lnnCand.isMatter ? h3track.tpcNClsFound() : negTrack.tpcNClsFound(); + lnnCand.tpcSignalPi = !lnnCand.isMatter ? h3track.tpcSignal() : negTrack.tpcSignal(); + lnnCand.clusterSizeITSPi = !lnnCand.isMatter ? h3track.itsClusterSizes() : negTrack.itsClusterSizes(); lnnCand.mom3HTPC = lnnCand.isMatter ? posRigidity : negRigidity; lnnCand.momPiTPC = !lnnCand.isMatter ? posRigidity : negRigidity; @@ -400,6 +448,13 @@ struct lnnRecoTask { lnnCand.decVtx[i] = lnnCand.decVtx[i] - primVtx[i]; } + if (h3track.hasTOF()) { + float beta = responseBeta.GetBeta(h3track); + beta = std::min(1.f - 1.e-6f, std::max(1.e-4f, beta)); /// sometimes beta > 1 or < 0, to be checked + float TPCinnerParam3H = h3track.tpcInnerParam(); + lnnCand.massTrTOF = TPCinnerParam3H * std::sqrt(1.f / (beta * beta) - 1.f); + } + // if survived all selections, propagate decay daughters to PV gpu::gpustd::array dcaInfo; @@ -417,11 +472,12 @@ struct lnnRecoTask { int chargeFactor = -1 + 2 * lnnCand.isMatter; hdEdx3HSel->Fill(chargeFactor * lnnCand.mom3HTPC, h3track.tpcSignal()); hNsigma3HSel->Fill(chargeFactor * lnnCand.mom3HTPC, lnnCand.nSigma3H); - lnnCandidates.push_back(lnnCand); if (is3H) { hdEdx3HTPCMom->Fill(lnnCand.mom3HTPC, h3track.tpcSignal()); } + + lnnCandidates.push_back(lnnCand); } } @@ -505,6 +561,7 @@ struct lnnRecoTask { lnnCand.dcaV0dau, lnnCand.h3DCAXY, lnnCand.piDCAXY, lnnCand.nSigma3H, lnnCand.nTPCClusters3H, lnnCand.nTPCClustersPi, lnnCand.mom3HTPC, lnnCand.momPiTPC, lnnCand.tpcSignal3H, lnnCand.tpcSignalPi, + lnnCand.massTrTOF, lnnCand.clusterSizeITS3H, lnnCand.clusterSizeITSPi, lnnCand.flags); } } @@ -512,7 +569,7 @@ struct lnnRecoTask { PROCESS_SWITCH(lnnRecoTask, processData, "Data analysis", true); // MC process - void processMC(CollisionsFullMC const& collisions, aod::McCollisions const& mcCollisions, aod::V0s const& V0s, TracksFull const& tracks, aod::BCsWithTimestamps const&, aod::McTrackLabels const& trackLabelsMC, aod::McParticles const& particlesMC) + void processMC(CollisionsFullMC const& collisions, aod::McCollisions const& mcCollisions, aod::V0s const& V0s, TracksFullMC const& tracks, aod::BCsWithTimestamps const&, aod::McTrackLabels const& trackLabelsMC, aod::McParticles const& particlesMC) { filledMothers.clear(); @@ -526,7 +583,7 @@ struct lnnRecoTask { hEvents->Fill(0.); - if ((collision.posZ()) > 10) { + if (std::abs(collision.posZ()) > 10) { continue; } hEvents->Fill(1.); @@ -561,6 +618,7 @@ struct lnnRecoTask { lnnCand.dcaV0dau, lnnCand.h3DCAXY, lnnCand.piDCAXY, lnnCand.nSigma3H, lnnCand.nTPCClusters3H, lnnCand.nTPCClustersPi, lnnCand.mom3HTPC, lnnCand.momPiTPC, lnnCand.tpcSignal3H, lnnCand.tpcSignalPi, + lnnCand.massTrTOF, lnnCand.clusterSizeITS3H, lnnCand.clusterSizeITSPi, lnnCand.flags, chargeFactor * lnnCand.genPt(), lnnCand.genPhi(), lnnCand.genEta(), lnnCand.genPt3H(), lnnCand.gDecVtx[0], lnnCand.gDecVtx[1], lnnCand.gDecVtx[2], lnnCand.isReco, lnnCand.isSignal, lnnCand.survEvSelection); @@ -630,6 +688,7 @@ struct lnnRecoTask { -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, chargeFactor * lnnCand.genPt(), lnnCand.genPhi(), lnnCand.genEta(), lnnCand.genPt3H(), lnnCand.gDecVtx[0], lnnCand.gDecVtx[1], lnnCand.gDecVtx[2], lnnCand.isReco, lnnCand.isSignal, lnnCand.survEvSelection); From 69f4e4e1a8adeff4b4c451a249107fcddc9e826d Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Wed, 11 Sep 2024 17:44:52 +0200 Subject: [PATCH 17/24] add TOF mass to tritons --- PWGLF/DataModel/LFLnnTables.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/PWGLF/DataModel/LFLnnTables.h b/PWGLF/DataModel/LFLnnTables.h index 2ee0fa22839..bb58b12b010 100644 --- a/PWGLF/DataModel/LFLnnTables.h +++ b/PWGLF/DataModel/LFLnnTables.h @@ -58,6 +58,7 @@ DECLARE_SOA_COLUMN(TPCsignalPi, tpcSignalPi, uint16_t); // TPC DECLARE_SOA_COLUMN(Flags, flags, uint8_t); // Flags for PID in tracking (bits [0, 3] for negative daughter, [4,7] for positive daughter) DECLARE_SOA_COLUMN(TPCmom3H, tpcMom3H, float); // TPC momentum of the 3H daughter DECLARE_SOA_COLUMN(TPCmomPi, tpcMomPi, float); // TPC momentum of the Pi daughter +DECLARE_SOA_COLUMN(MassTrTOF, massTrTOF, float); // TOF 3H mass DECLARE_SOA_COLUMN(ITSclusterSizes3H, itsClusterSizes3H, uint32_t); // ITS cluster size of the 3H daughter DECLARE_SOA_COLUMN(ITSclusterSizesPi, itsClusterSizesPi, uint32_t); // ITS cluster size of the Pi daughter DECLARE_SOA_COLUMN(Dca3H, dca3H, float); // DCA between 3H daughter and V0 @@ -80,13 +81,14 @@ DECLARE_SOA_TABLE(DataLnnCands, "AOD", "LNNCANDS", lnnrec::CentralityFT0A, lnnrec::CentralityFT0C, lnnrec::CentralityFT0M, lnnrec::XPrimVtx, lnnrec::YPrimVtx, lnnrec::ZPrimVtx, - lnnrec::IsMatter, + lnnrec::IsMatter, lnnrec::Pt3H, lnnrec::Phi3H, lnnrec::Eta3H, lnnrec::PtPi, lnnrec::PhiPi, lnnrec::EtaPi, lnnrec::XDecVtx, lnnrec::YDecVtx, lnnrec::ZDecVtx, lnnrec::DcaV0Daug, lnnrec::Dca3H, lnnrec::DcaPi, lnnrec::NSigma3H, lnnrec::NTPCclus3H, lnnrec::NTPCclusPi, lnnrec::TPCmom3H, lnnrec::TPCmomPi, lnnrec::TPCsignal3H, lnnrec::TPCsignalPi, + lnnrec::MassTrTOF, lnnrec::ITSclusterSizes3H, lnnrec::ITSclusterSizesPi, lnnrec::Flags); @@ -95,13 +97,14 @@ DECLARE_SOA_TABLE(MCLnnCands, "AOD", "MCLNNCANDS", lnnrec::CentralityFT0A, lnnrec::CentralityFT0C, lnnrec::CentralityFT0M, lnnrec::XPrimVtx, lnnrec::YPrimVtx, lnnrec::ZPrimVtx, - lnnrec::IsMatter, + lnnrec::IsMatter, lnnrec::Pt3H, lnnrec::Phi3H, lnnrec::Eta3H, lnnrec::PtPi, lnnrec::PhiPi, lnnrec::EtaPi, lnnrec::XDecVtx, lnnrec::YDecVtx, lnnrec::ZDecVtx, lnnrec::DcaV0Daug, lnnrec::Dca3H, lnnrec::DcaPi, lnnrec::NSigma3H, lnnrec::NTPCclus3H, lnnrec::NTPCclusPi, lnnrec::TPCmom3H, lnnrec::TPCmomPi, lnnrec::TPCsignal3H, lnnrec::TPCsignalPi, + lnnrec::MassTrTOF, lnnrec::ITSclusterSizes3H, lnnrec::ITSclusterSizesPi, lnnrec::Flags, lnnrec::GenPt, From d51288c0683c8f429908f6364d124bbc449a61bc Mon Sep 17 00:00:00 2001 From: ALICE Action Bot Date: Wed, 11 Sep 2024 15:58:02 +0000 Subject: [PATCH 18/24] Please consider the following formatting changes --- PWGLF/DataModel/LFLnnTables.h | 6 ++-- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 32 ++++++++++------------ 2 files changed, 18 insertions(+), 20 deletions(-) diff --git a/PWGLF/DataModel/LFLnnTables.h b/PWGLF/DataModel/LFLnnTables.h index bb58b12b010..786ce37090f 100644 --- a/PWGLF/DataModel/LFLnnTables.h +++ b/PWGLF/DataModel/LFLnnTables.h @@ -58,7 +58,7 @@ DECLARE_SOA_COLUMN(TPCsignalPi, tpcSignalPi, uint16_t); // TPC DECLARE_SOA_COLUMN(Flags, flags, uint8_t); // Flags for PID in tracking (bits [0, 3] for negative daughter, [4,7] for positive daughter) DECLARE_SOA_COLUMN(TPCmom3H, tpcMom3H, float); // TPC momentum of the 3H daughter DECLARE_SOA_COLUMN(TPCmomPi, tpcMomPi, float); // TPC momentum of the Pi daughter -DECLARE_SOA_COLUMN(MassTrTOF, massTrTOF, float); // TOF 3H mass +DECLARE_SOA_COLUMN(MassTrTOF, massTrTOF, float); // TOF 3H mass DECLARE_SOA_COLUMN(ITSclusterSizes3H, itsClusterSizes3H, uint32_t); // ITS cluster size of the 3H daughter DECLARE_SOA_COLUMN(ITSclusterSizesPi, itsClusterSizesPi, uint32_t); // ITS cluster size of the Pi daughter DECLARE_SOA_COLUMN(Dca3H, dca3H, float); // DCA between 3H daughter and V0 @@ -81,7 +81,7 @@ DECLARE_SOA_TABLE(DataLnnCands, "AOD", "LNNCANDS", lnnrec::CentralityFT0A, lnnrec::CentralityFT0C, lnnrec::CentralityFT0M, lnnrec::XPrimVtx, lnnrec::YPrimVtx, lnnrec::ZPrimVtx, - lnnrec::IsMatter, + lnnrec::IsMatter, lnnrec::Pt3H, lnnrec::Phi3H, lnnrec::Eta3H, lnnrec::PtPi, lnnrec::PhiPi, lnnrec::EtaPi, lnnrec::XDecVtx, lnnrec::YDecVtx, lnnrec::ZDecVtx, @@ -97,7 +97,7 @@ DECLARE_SOA_TABLE(MCLnnCands, "AOD", "MCLNNCANDS", lnnrec::CentralityFT0A, lnnrec::CentralityFT0C, lnnrec::CentralityFT0M, lnnrec::XPrimVtx, lnnrec::YPrimVtx, lnnrec::ZPrimVtx, - lnnrec::IsMatter, + lnnrec::IsMatter, lnnrec::Pt3H, lnnrec::Phi3H, lnnrec::Eta3H, lnnrec::PtPi, lnnrec::PhiPi, lnnrec::EtaPi, lnnrec::XDecVtx, lnnrec::YDecVtx, lnnrec::ZDecVtx, diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index b1b897d9883..7bb1a3b242b 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -35,8 +35,6 @@ #include "Common/DataModel/TrackSelectionTables.h" #include "Common/Core/trackUtilities.h" - - #include "Common/Core/PID/TPCPIDResponse.h" #include "DataFormatsTPC/BetheBlochAleph.h" #include "DCAFitter/DCAFitterN.h" @@ -148,7 +146,7 @@ struct lnnRecoTask { Configurable mcSignalOnly{"mcSignalOnly", true, "If true, save only signal in MC"}; Configurable isTPCRefit{"TPCRefit", true, "if true, select the tracks"}; Configurable isITSRefit{"ITSRefit", true, "if true, select the tracks"}; - //Configurable RMSMean{"RMSMean", 0.07, "RMS Mean"}; + // Configurable RMSMean{"RMSMean", 0.07, "RMS Mean"}; // Define o2 fitter, 2-prong, active memory (no need to redefine per event) o2::vertexing::DCAFitterN<2> fitter; @@ -306,7 +304,7 @@ struct lnnRecoTask { } TLorentzVector LorentzV_Triton{}; - TLorentzVector LorentzV_AntiTriton{}; + TLorentzVector LorentzV_AntiTriton{}; for (auto& v0 : V0s) { @@ -319,7 +317,7 @@ struct lnnRecoTask { if (std::abs(posTrack.eta()) > etaMax || std::abs(negTrack.eta()) > etaMax) { continue; } - + if (std::abs(LorentzV_Triton.Rapidity()) > yMax) { continue; } @@ -327,7 +325,7 @@ struct lnnRecoTask { if (std::abs(LorentzV_AntiTriton.Rapidity()) > yMax) { continue; } - + float posRigidity = posTrack.tpcInnerParam(); float negRigidity = negTrack.tpcInnerParam(); @@ -352,18 +350,18 @@ struct lnnRecoTask { // Describing lnn as matter candidate lnnCandidate lnnCand; lnnCand.isMatter = is3H && isAnti3H ? std::abs(nSigmaTPCpos) < std::abs(nSigmaTPCneg) : is3H; - auto& h3track = lnnCand.isMatter ? posTrack : negTrack; + auto& h3track = lnnCand.isMatter ? posTrack : negTrack; auto& h3Rigidity = lnnCand.isMatter ? posRigidity : negRigidity; - + if (h3Rigidity < TPCRigidityMin3H || - h3track.tpcNClsFound() < nTPCClusMin3H || - h3track.tpcChi2NCl() > Chi2nClusTPC || - h3track.itsChi2NCl() > Chi2nClusITS || - h3track.itsNCls() < nClusITS || - h3track.tpcNClsCrossedRows() < nClusTPCRows || - h3track.tpcNClsCrossedRows() < 0.8 * h3track.tpcNClsFindable() || - !h3track.passedTPCRefit() || - !h3track.passedITSRefit()) { + h3track.tpcNClsFound() < nTPCClusMin3H || + h3track.tpcChi2NCl() > Chi2nClusTPC || + h3track.itsChi2NCl() > Chi2nClusITS || + h3track.itsNCls() < nClusITS || + h3track.tpcNClsCrossedRows() < nClusTPCRows || + h3track.tpcNClsCrossedRows() < 0.8 * h3track.tpcNClsFindable() || + !h3track.passedTPCRefit() || + !h3track.passedITSRefit()) { continue; } @@ -453,7 +451,7 @@ struct lnnRecoTask { beta = std::min(1.f - 1.e-6f, std::max(1.e-4f, beta)); /// sometimes beta > 1 or < 0, to be checked float TPCinnerParam3H = h3track.tpcInnerParam(); lnnCand.massTrTOF = TPCinnerParam3H * std::sqrt(1.f / (beta * beta) - 1.f); - } + } // if survived all selections, propagate decay daughters to PV gpu::gpustd::array dcaInfo; From 22f1ec9caa142e2469e838ff9d1a3556fa4a2331 Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Wed, 11 Sep 2024 18:13:32 +0200 Subject: [PATCH 19/24] Fix empty spaces --- PWGLF/DataModel/LFLnnTables.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PWGLF/DataModel/LFLnnTables.h b/PWGLF/DataModel/LFLnnTables.h index bb58b12b010..5a90dd4fd95 100644 --- a/PWGLF/DataModel/LFLnnTables.h +++ b/PWGLF/DataModel/LFLnnTables.h @@ -122,4 +122,4 @@ using DataLnnCand = DataLnnCands::iterator; using MCLnnCand = MCLnnCands::iterator; } // namespace o2::aod -#endif // PWGLF_DATAMODEL_LFLNNTABLES_H_ \ No newline at end of file +#endif // PWGLF_DATAMODEL_LFLNNTABLES_H_ From 078cfe8cfaa3514f6002ef9e23549623fc9d743e Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Wed, 11 Sep 2024 18:15:23 +0200 Subject: [PATCH 20/24] Remove double #include Common/Core/trackUtilities.h --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index b1b897d9883..f8992eeaef9 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -33,9 +33,6 @@ #include "Common/DataModel/PIDResponse.h" #include "Common/DataModel/TrackSelectionTables.h" -#include "Common/Core/trackUtilities.h" - - #include "Common/Core/PID/TPCPIDResponse.h" #include "DataFormatsTPC/BetheBlochAleph.h" @@ -327,7 +324,7 @@ struct lnnRecoTask { if (std::abs(LorentzV_AntiTriton.Rapidity()) > yMax) { continue; } - + float posRigidity = posTrack.tpcInnerParam(); float negRigidity = negTrack.tpcInnerParam(); From c4cb28415cd5210e801c79cb3e7a97b7d90931dc Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Thu, 12 Sep 2024 10:58:25 +0200 Subject: [PATCH 21/24] Remove ITSRefit, TPCRefit --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 24 +--------------------- 1 file changed, 1 insertion(+), 23 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index fb1b63dcd29..6df2a4c9576 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -134,17 +134,12 @@ struct lnnRecoTask { Configurable Chi2nClusITS{"Chi2NClusITS", 36., "Chi2 / nClusITS for triton track"}; Configurable ptMin{"ptMin", 0.5, "Minimum pT of the lnncandidate"}; Configurable etaMax{"eta", 0.8, "eta daughter"}; - Configurable yMax{"rapidityPos", 0.5, "track rapidity pos"}; - Configurable yMin{"rapidityNeg", -0.5, "track rapidity neg"}; Configurable TPCRigidityMin3H{"TPCRigidityMin3H", 0.5, "Minimum rigidity of the triton candidate"}; Configurable nSigmaCutTPC{"nSigmaCutTPC", 4., "triton dEdx cut (n sigma)"}; Configurable nTPCClusMin3H{"nTPCClusMin3H", 80, "triton NTPC clusters cut"}; Configurable nTPCClusMinPi{"nTPCClusMinPi", -1., "pion NTPC clusters cut"}; Configurable nClusITS{"nClusITSMin3H", 5.0, "triton NITS clusters cut"}; - Configurable nClusTPCRows{"nClusTPCRows", 70., "Number of crossed TPC Rows"}; Configurable mcSignalOnly{"mcSignalOnly", true, "If true, save only signal in MC"}; - Configurable isTPCRefit{"TPCRefit", true, "if true, select the tracks"}; - Configurable isITSRefit{"ITSRefit", true, "if true, select the tracks"}; // Configurable RMSMean{"RMSMean", 0.07, "RMS Mean"}; // Define o2 fitter, 2-prong, active memory (no need to redefine per event) @@ -302,29 +297,16 @@ struct lnnRecoTask { LOG(fatal) << "Bethe-Bloch parameters for 3H not set, please check your CCDB and configuration"; } - TLorentzVector LorentzV_Triton{}; - TLorentzVector LorentzV_AntiTriton{}; - for (auto& v0 : V0s) { auto posTrack = v0.posTrack_as(); auto negTrack = v0.negTrack_as(); - LorentzV_Triton.SetPtEtaPhiM(posTrack.pt(), posTrack.eta(), posTrack.phi(), constants::physics::MassTriton); - LorentzV_AntiTriton.SetPtEtaPhiM(negTrack.pt(), negTrack.eta(), negTrack.phi(), constants::physics::MassTriton); if (std::abs(posTrack.eta()) > etaMax || std::abs(negTrack.eta()) > etaMax) { continue; } - if (std::abs(LorentzV_Triton.Rapidity()) > yMax) { - continue; - } - - if (std::abs(LorentzV_AntiTriton.Rapidity()) > yMax) { - continue; - } - float posRigidity = posTrack.tpcInnerParam(); float negRigidity = negTrack.tpcInnerParam(); @@ -356,11 +338,7 @@ struct lnnRecoTask { h3track.tpcNClsFound() < nTPCClusMin3H || h3track.tpcChi2NCl() > Chi2nClusTPC || h3track.itsChi2NCl() > Chi2nClusITS || - h3track.itsNCls() < nClusITS || - h3track.tpcNClsCrossedRows() < nClusTPCRows || - h3track.tpcNClsCrossedRows() < 0.8 * h3track.tpcNClsFindable() || - !h3track.passedTPCRefit() || - !h3track.passedITSRefit()) { + h3track.itsNCls() < nClusITS) { continue; } From 3ea943113244e9f2b3f1039ec9dee2f51c1b352b Mon Sep 17 00:00:00 2001 From: ALICE Action Bot Date: Thu, 12 Sep 2024 08:59:10 +0000 Subject: [PATCH 22/24] Please consider the following formatting changes --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 1 - 1 file changed, 1 deletion(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index 6df2a4c9576..f607e4ea872 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -302,7 +302,6 @@ struct lnnRecoTask { auto posTrack = v0.posTrack_as(); auto negTrack = v0.negTrack_as(); - if (std::abs(posTrack.eta()) > etaMax || std::abs(negTrack.eta()) > etaMax) { continue; } From dcce9bd2374f57f4c69f4c95c068ebec4aaffaa9 Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Fri, 13 Sep 2024 14:05:08 +0200 Subject: [PATCH 23/24] Add o2::aod::TrackSelection, o2::aod::TrackSelectionExtension for massTritonTOF --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index 6df2a4c9576..4a89fbf6b0f 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -38,6 +38,8 @@ #include "DataFormatsTPC/BetheBlochAleph.h" #include "DCAFitter/DCAFitterN.h" +#include "Common/DataModel/TrackSelectionTables.h" + #include "Common/Core/PID/PIDTOF.h" #include "Common/TableProducer/PID/pidTOFBase.h" @@ -47,8 +49,8 @@ using namespace o2; using namespace o2::framework; using namespace o2::framework::expressions; using std::array; -using TracksFull = soa::Join; -using TracksFullMC = soa::Join; +using TracksFull = soa::Join; +using TracksFullMC = soa::Join; using CollisionsFull = soa::Join; using CollisionsFullMC = soa::Join; @@ -128,8 +130,6 @@ struct lnnRecoTask { Configurable v0cospa{"lnncospa", 0.95, "V0 CosPA"}; Configurable masswidth{"lnnmasswidth", 0.006, "Mass width (GeV/c^2)"}; Configurable dcav0dau{"lnndcaDau", 1.0, "DCA V0 Daughters"}; - Configurable dcaToPvPion{"dcapvPi", 0., "DCA to PV pion"}; - Configurable dcaXY{"cutDCAXY", 2.0, "DCAxy range for tracks"}; Configurable Chi2nClusTPC{"Chi2NClusTPC", 4., "Chi2 / nClusTPC for triton track"}; Configurable Chi2nClusITS{"Chi2NClusITS", 36., "Chi2 / nClusITS for triton track"}; Configurable ptMin{"ptMin", 0.5, "Minimum pT of the lnncandidate"}; @@ -137,10 +137,8 @@ struct lnnRecoTask { Configurable TPCRigidityMin3H{"TPCRigidityMin3H", 0.5, "Minimum rigidity of the triton candidate"}; Configurable nSigmaCutTPC{"nSigmaCutTPC", 4., "triton dEdx cut (n sigma)"}; Configurable nTPCClusMin3H{"nTPCClusMin3H", 80, "triton NTPC clusters cut"}; - Configurable nTPCClusMinPi{"nTPCClusMinPi", -1., "pion NTPC clusters cut"}; Configurable nClusITS{"nClusITSMin3H", 5.0, "triton NITS clusters cut"}; Configurable mcSignalOnly{"mcSignalOnly", true, "If true, save only signal in MC"}; - // Configurable RMSMean{"RMSMean", 0.07, "RMS Mean"}; // Define o2 fitter, 2-prong, active memory (no need to redefine per event) o2::vertexing::DCAFitterN<2> fitter; @@ -310,9 +308,6 @@ struct lnnRecoTask { float posRigidity = posTrack.tpcInnerParam(); float negRigidity = negTrack.tpcInnerParam(); - hdEdxTot->Fill(posRigidity, posTrack.tpcSignal()); - hdEdxTot->Fill(-negRigidity, negTrack.tpcSignal()); - // Bethe-Bloch calcution for 3H & nSigma calculation double expBethePos{tpc::BetheBlochAleph(static_cast(posRigidity / constants::physics::MassTriton), mBBparams3H[0], mBBparams3H[1], mBBparams3H[2], mBBparams3H[3], mBBparams3H[4])}; double expBetheNeg{tpc::BetheBlochAleph(static_cast(negRigidity / constants::physics::MassTriton), mBBparams3H[0], mBBparams3H[1], mBBparams3H[2], mBBparams3H[3], mBBparams3H[4])}; @@ -444,6 +439,8 @@ struct lnnRecoTask { lnnCand.posTrackID = posTrack.globalIndex(); lnnCand.negTrackID = negTrack.globalIndex(); + hdEdxTot->Fill(posRigidity, posTrack.tpcSignal()); + hdEdxTot->Fill(-negRigidity, negTrack.tpcSignal()); int chargeFactor = -1 + 2 * lnnCand.isMatter; hdEdx3HSel->Fill(chargeFactor * lnnCand.mom3HTPC, h3track.tpcSignal()); hNsigma3HSel->Fill(chargeFactor * lnnCand.mom3HTPC, lnnCand.nSigma3H); From 51f25c823efab60bac1213421d1dadf7b848a59a Mon Sep 17 00:00:00 2001 From: Maria Paula Martins Palhares Date: Fri, 13 Sep 2024 14:11:41 +0200 Subject: [PATCH 24/24] fix merge conflict --- PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx | 1 - 1 file changed, 1 deletion(-) diff --git a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx index 120bdbab6d1..8a74d4f39b0 100644 --- a/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx +++ b/PWGLF/TableProducer/Nuspex/lnnRecoTask.cxx @@ -32,7 +32,6 @@ #include "CCDB/BasicCCDBManager.h" #include "Common/DataModel/PIDResponse.h" -#include "Common/DataModel/TrackSelectionTables.h" #include "Common/Core/PID/TPCPIDResponse.h" #include "DataFormatsTPC/BetheBlochAleph.h"