Skip to content

Commit 2f87de4

Browse files
author
Sushanta Tripathy
committed
Updating PID strategy
1 parent a77891f commit 2f87de4

1 file changed

Lines changed: 14 additions & 4 deletions

File tree

PWGCF/TwoParticleCorrelations/Tasks/nucleibalance.cxx

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1710,6 +1710,7 @@ struct Lambdastarproxy {
17101710
Configurable<float> lstarCutNsigmaTOFKaon{"lstarCutNsigmaTOFKaon", float{NsigmaTOFDefault}, "|nSigma^{TOF}_{K}| cut"};
17111711
Configurable<float> lstarCutNsigmaTPCDe{"lstarCutNsigmaTPCDe", float{NsigmaTPCDefault}, "|nSigma^{TPC}_{d}| cut"};
17121712
Configurable<float> lstarCutNsigmaTOFDe{"lstarCutNsigmaTOFDe", float{NsigmaTOFDefault}, "|nSigma^{TOF}_{d}| cut"};
1713+
Configurable<int> lstarEnableTOFNsigmaCutDe{"lstarEnableTOFNsigmaCutDe", 0, "Enable deuteron-only TOF nSigma cut in PID strategy 2"};
17131714
// Optional deuteron-only TOF auxiliary selections.
17141715
// Defaults are OFF, so strategy 2 remains TPC nSigma only for deuterons.
17151716
Configurable<int> lstarEnableBetaCutDe{"lstarEnableBetaCutDe", 0, "Enable deuteron-only TOF beta cut using beta() > lstarBetaCutDe"};
@@ -1956,7 +1957,7 @@ struct Lambdastarproxy {
19561957
// This bypasses the extra explicit ITS/TPC/DCA/chi2 cuts below.
19571958
if (lstarOnlyGlobalTrackCuts.value != 0) {
19581959
return true;
1959-
}
1960+
}
19601961

19611962
if constexpr (requires { trk.itsNCls(); }) {
19621963
if (lstarITSNClusters.value > 0 && trk.itsNCls() < lstarITSNClusters.value) {
@@ -2433,8 +2434,8 @@ struct Lambdastarproxy {
24332434
}
24342435

24352436
bool passFinalCandidatePID(float pt, float nsTPC, float nsTOF, bool hasTof,
2436-
float tpcCut, float tofCut, float circularCut,
2437-
float ptRef, bool isDeuteron = false) const
2437+
float tpcCut, float tofCut, float circularCut,
2438+
float ptRef, bool isDeuteron = false) const
24382439
{
24392440
// Strategy 1: analysis-note style circular TPC+TOF cut
24402441
if (lstarPidStrategy.value == PidStrategyCircularTPCAndTOF) {
@@ -2453,7 +2454,16 @@ struct Lambdastarproxy {
24532454
// For deuterons, follow the default idea of the official nuclei task:
24542455
// use TPC nσ as the main hard PID selection.
24552456
if (isDeuteron) {
2456-
return std::abs(nsTPC) < tpcCut;
2457+
if (std::abs(nsTPC) >= tpcCut) {
2458+
return false;
2459+
}
2460+
if (lstarEnableTOFNsigmaCutDe.value != 0) {
2461+
if (!hasTof) {
2462+
return false;
2463+
}
2464+
return std::abs(nsTOF) < tofCut;
2465+
}
2466+
return true;
24572467
}
24582468

24592469
// For kaons/protons, use the Lambda(1520)-like pT-ref circular TPC+TOF logic.

0 commit comments

Comments
 (0)