Skip to content

Commit

Permalink
[PWGCF] FemtoUniverse cascade task -- implemented pair cleaner for ca…
Browse files Browse the repository at this point in the history
…scade-cascade combination (#9449)

Co-authored-by: Shirajum Monira <shirajum.monira@cernch>
  • Loading branch information
Eloviyo and Shirajum Monira authored Jan 22, 2025
1 parent 0cd934c commit e7b802a
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 2 deletions.
19 changes: 19 additions & 0 deletions PWGCF/FemtoUniverse/Core/FemtoUniversePairCleaner.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
/// \author Andi Mathis, TU München, andreas.mathis@ph.tum.de
/// \author Laura Serksnyte, TU München,laura.serksnyte@cern.ch
/// \author Zuzanna Chochulska, WUT Warsaw & CTU Prague, zchochul@cern.ch
/// \author Shirajum Monira, WUT Warsaw, shirajum.monira@cern.ch

#ifndef PWGCF_FEMTOUNIVERSE_CORE_FEMTOUNIVERSEPAIRCLEANER_H_
#define PWGCF_FEMTOUNIVERSE_CORE_FEMTOUNIVERSEPAIRCLEANER_H_
Expand Down Expand Up @@ -112,6 +113,24 @@ class FemtoUniversePairCleaner
return false;
}
return part1.globalIndex() != part2.globalIndex();
} else if constexpr (kPartOneType == o2::aod::femtouniverseparticle::ParticleType::kCascade && kPartTwoType == o2::aod::femtouniverseparticle::ParticleType::kCascade) {
/// Cascade-Cascade combination both part1 and part2 are cascades
if (part1.partType() != o2::aod::femtouniverseparticle::ParticleType::kCascade || part2.partType() != o2::aod::femtouniverseparticle::ParticleType::kCascade) {
LOG(fatal) << "FemtoUniversePairCleaner: passed arguments don't agree with FemtoUniversePairCleaner instantiation! Please provide first and second arguments kCascade candidate.";
return false;
}
// Getting cascade children for part1
const auto& posChild1 = particles.iteratorAt(part1.index() - 3);
const auto& negChild1 = particles.iteratorAt(part1.index() - 2);
const auto& bachelor1 = particles.iteratorAt(part1.index() - 1);
// Getting cascade children for part2
const auto& posChild2 = particles.iteratorAt(part2.index() - 3);
const auto& negChild2 = particles.iteratorAt(part2.index() - 2);
const auto& bachelor2 = particles.iteratorAt(part2.index() - 1);
if (posChild1.globalIndex() == posChild2.globalIndex() || negChild1.globalIndex() == negChild2.globalIndex() || bachelor1.globalIndex() == bachelor2.globalIndex()) {
return false;
}
return part1.globalIndex() != part2.globalIndex();
} else if constexpr (kPartOneType == o2::aod::femtouniverseparticle::ParticleType::kTrack && kPartTwoType == o2::aod::femtouniverseparticle::ParticleType::kD0) {
/// Track-D0 combination part1 is hadron and part2 is D0
if (part2.partType() != o2::aod::femtouniverseparticle::ParticleType::kD0) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ struct femtoUniversePairTaskTrackCascadeExtended { // o2-linter: disable=name/st
FemtoUniverseContainer<femto_universe_container::EventType::same, femto_universe_container::Observable::kstar> sameEventCont;
FemtoUniverseContainer<femto_universe_container::EventType::mixed, femto_universe_container::Observable::kstar> mixedEventCont;
FemtoUniversePairCleaner<aod::femtouniverseparticle::ParticleType::kTrack, aod::femtouniverseparticle::ParticleType::kCascade> pairCleaner;
FemtoUniversePairCleaner<aod::femtouniverseparticle::ParticleType::kCascade, aod::femtouniverseparticle::ParticleType::kCascade> pairCleanerCasc;

HistogramRegistry rXiQA{"xi", {}, OutputObjHandlingPolicy::AnalysisObject, true, true};
HistogramRegistry qaRegistry{"TrackQA", {}, OutputObjHandlingPolicy::AnalysisObject};
Expand Down Expand Up @@ -379,7 +380,7 @@ struct femtoUniversePairTaskTrackCascadeExtended { // o2-linter: disable=name/st
if (!invMCascade(p2.mLambda(), p2.mAntiLambda()))
return;
// track cleaning
if (!pairCleaner.isCleanPair(p1, p2, parts)) {
if (!pairCleanerCasc.isCleanPair(p1, p2, parts)) {
return;
}
const auto& posChild1 = parts.iteratorAt(p1.index() - 3);
Expand Down Expand Up @@ -488,7 +489,7 @@ struct femtoUniversePairTaskTrackCascadeExtended { // o2-linter: disable=name/st
if (!isParticleTPC(posChild2, CascChildTable[confCascType2][0]) || !isParticleTPC(negChild2, CascChildTable[confCascType2][1]) || !isParticleTPC(bachelor2, CascChildTable[confCascType2][2]))
return;
// track cleaning
if (!pairCleaner.isCleanPair(p1, p2, parts)) {
if (!pairCleanerCasc.isCleanPair(p1, p2, parts)) {
continue;
}

Expand Down

0 comments on commit e7b802a

Please sign in to comment.