Skip to content

Commit

Permalink
Adding flag selection in the hadron tasks (#5218)
Browse files Browse the repository at this point in the history
Co-authored-by: Luigi <ldellost@aliceml.cern.ch>
  • Loading branch information
DelloStritto and Luigi committed Jan 20, 2021
1 parent 40bd7f9 commit d5f8673
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 4 deletions.
10 changes: 8 additions & 2 deletions Analysis/Tasks/PWGHF/HFD0CandidateSelector.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -324,11 +324,17 @@ struct HFD0CandidateSelector {

for (auto& hfCandProng2 : hfCandProng2s) { //looping over 2 prong candidates

statusD0 = 0;
statusD0bar = 0;

if (!(hfCandProng2.hfflag() & 1 << D0ToPiK)) {
hfSelD0Candidate(statusD0, statusD0bar);
continue;
}

auto trackPos = hfCandProng2.index0_as<aod::BigTracksPID>(); //positive daughter
auto trackNeg = hfCandProng2.index1_as<aod::BigTracksPID>(); //negative daughter

statusD0 = 0;
statusD0bar = 0;
topolD0 = true;
topolD0bar = true;
pidD0 = -1;
Expand Down
3 changes: 1 addition & 2 deletions Analysis/Tasks/PWGHF/HFLcCandidateSelector.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -287,9 +287,8 @@ struct HFLcCandidateSelector {

statusLcpKpi = 0;
statusLcpiKp = 0;
int LcFlag = hfCandProng3.hfflag();

if (!(LcFlag & 1 << 1)) {
if (!(hfCandProng3.hfflag() & 1 << LcToPKPi)) {
hfSelLcCandidate(statusLcpKpi, statusLcpiKp);
continue;
}
Expand Down
6 changes: 6 additions & 0 deletions Analysis/Tasks/PWGHF/taskD0.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@ struct TaskD0 {
{
//Printf("Candidates: %d", candidates.size());
for (auto& candidate : candidates) {
if (!(candidate.hfflag() & 1 << D0ToPiK)) {
continue;
}
if (cutEtaCandMax >= 0. && std::abs(candidate.eta()) > cutEtaCandMax) {
//Printf("Candidate: eta rejection: %g", candidate.eta());
continue;
Expand Down Expand Up @@ -120,6 +123,9 @@ struct TaskD0MC {
// MC rec.
//Printf("MC Candidates: %d", candidates.size());
for (auto& candidate : candidates) {
if (!(candidate.hfflag() & 1 << D0ToPiK)) {
continue;
}
if (cutEtaCandMax >= 0. && std::abs(candidate.eta()) > cutEtaCandMax) {
//Printf("MC Rec.: eta rejection: %g", candidate.eta());
continue;
Expand Down
6 changes: 6 additions & 0 deletions Analysis/Tasks/PWGHF/taskLc.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,9 @@ struct TaskLc {
void process(soa::Filtered<soa::Join<aod::HfCandProng3, aod::HFSelLcCandidate>> const& candidates)
{
for (auto& candidate : candidates) {
if (!(candidate.hfflag() & 1 << LcToPKPi)) {
continue;
}
if (cutEtaCandMax >= 0. && std::abs(candidate.eta()) > cutEtaCandMax) {
//Printf("Candidate: eta rejection: %g", candidate.eta());
continue;
Expand Down Expand Up @@ -120,6 +123,9 @@ struct TaskLcMC {
// MC rec.
//Printf("MC Candidates: %d", candidates.size());
for (auto& candidate : candidates) {
if (!(candidate.hfflag() & 1 << LcToPKPi)) {
continue;
}
if (cutEtaCandMax >= 0. && std::abs(candidate.eta()) > cutEtaCandMax) {
//Printf("MC Rec.: eta rejection: %g", candidate.eta());
continue;
Expand Down

0 comments on commit d5f8673

Please sign in to comment.