Skip to content

Commit ae21ebd

Browse files
fchinufcatalan92
andauthored
PWGHF: Add information on swapped candidates and considered mass hypotesis in Ds tree creator (#7963)
* Add information on swapped candidates and which mass hypotesis is considered in Ds tree creator * Fix comment * Update PWGHF/TableProducer/treeCreatorDsToKKPi.cxx Co-authored-by: Fabio Catalano <fabio.catalano372@gmail.com> --------- Co-authored-by: Fabio Catalano <fabio.catalano372@gmail.com>
1 parent 26c902b commit ae21ebd

1 file changed

Lines changed: 10 additions & 4 deletions

File tree

PWGHF/TableProducer/treeCreatorDsToKKPi.cxx

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,7 @@ DECLARE_SOA_TABLE(HfCandDsLites, "AOD", "HFCANDDSLITE",
133133
hf_cand_3prong::FlagMcMatchRec,
134134
hf_cand_3prong::OriginMcRec,
135135
hf_cand_3prong::FlagMcDecayChanRec,
136+
hf_cand_3prong::IsCandidateSwapped,
136137
full::Sign);
137138

138139
DECLARE_SOA_TABLE(HfCandDsFulls, "AOD", "HFCANDDSFULL",
@@ -205,6 +206,7 @@ DECLARE_SOA_TABLE(HfCandDsFulls, "AOD", "HFCANDDSFULL",
205206
hf_cand_3prong::FlagMcMatchRec,
206207
hf_cand_3prong::OriginMcRec,
207208
hf_cand_3prong::FlagMcDecayChanRec,
209+
hf_cand_3prong::IsCandidateSwapped,
208210
full::Sign);
209211

210212
DECLARE_SOA_TABLE(HfCandDsFullEvs, "AOD", "HFCANDDSFULLEV",
@@ -294,13 +296,15 @@ struct HfTreeCreatorDsToKKPi {
294296
int8_t flagMc = 0;
295297
int8_t originMc = 0;
296298
int8_t channelMc = 0;
299+
int8_t isSwapped = massHypo; // 0 if KKPi, 1 if PiKK
297300
float yCand = 0;
298301
float eCand = 0;
299302
float ctCand = 0;
300303
if constexpr (doMc) {
301304
flagMc = candidate.flagMcMatchRec();
302305
originMc = candidate.originMcRec();
303306
channelMc = candidate.flagMcDecayChanRec();
307+
isSwapped = candidate.isCandidateSwapped();
304308
if (fillDplusMc && candidate.flagMcDecayChanRec() == (decayChannel + offsetDplusDecayChannel)) {
305309
yCand = hfHelper.yDplus(candidate);
306310
eCand = hfHelper.eDplus(candidate);
@@ -358,8 +362,8 @@ struct HfTreeCreatorDsToKKPi {
358362
prong2.tofNSigmaKa(),
359363
prong2.tpcTofNSigmaPi(),
360364
prong2.tpcTofNSigmaKa(),
361-
candidate.isSelDsToKKPi(),
362-
candidate.isSelDsToPiKK(),
365+
massHypo == 0 ? candidate.isSelDsToKKPi() : -1,
366+
massHypo == 1 ? candidate.isSelDsToPiKK() : -1,
363367
invMassDs,
364368
candidate.pt(),
365369
candidate.eta(),
@@ -381,6 +385,7 @@ struct HfTreeCreatorDsToKKPi {
381385
flagMc,
382386
originMc,
383387
channelMc,
388+
isSwapped,
384389
prong0.sign() + prong1.sign() + prong2.sign());
385390
} else {
386391
rowCandidateFull(
@@ -425,8 +430,8 @@ struct HfTreeCreatorDsToKKPi {
425430
prong2.tofNSigmaKa(),
426431
prong2.tpcTofNSigmaPi(),
427432
prong2.tpcTofNSigmaKa(),
428-
candidate.isSelDsToKKPi(),
429-
candidate.isSelDsToPiKK(),
433+
massHypo == 0 ? candidate.isSelDsToKKPi() : -1,
434+
massHypo == 1 ? candidate.isSelDsToPiKK() : -1,
430435
candidate.xSecondaryVertex(),
431436
candidate.ySecondaryVertex(),
432437
candidate.zSecondaryVertex(),
@@ -453,6 +458,7 @@ struct HfTreeCreatorDsToKKPi {
453458
flagMc,
454459
originMc,
455460
channelMc,
461+
isSwapped,
456462
prong0.sign() + prong1.sign() + prong2.sign());
457463
}
458464
}

0 commit comments

Comments
 (0)