Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 22 additions & 30 deletions PWGHF/TableProducer/trackIndexSkimCreator.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@
NChannelsProtonPid
};
// kaon PID (opposite-sign track in 3-prong decays)
constexpr int channelKaonPid = ChannelsProtonPid::NChannelsProtonPid;

Check warning on line 94 in PWGHF/TableProducer/trackIndexSkimCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/constexpr-constant]

Use UpperCamelCase for names of constexpr constants. Names of special constants may be prefixed with "k".

/// Event selection
struct HfTrackIndexSkimCreatorTagSelCollisions {
Expand Down Expand Up @@ -198,8 +198,8 @@

/// Track selection
struct HfTrackIndexSkimCreatorTagSelTracks {
SliceCache cache;

Check warning on line 201 in PWGHF/TableProducer/trackIndexSkimCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[pwghf/struct-member-order]

HfTrackIndexSkimCreatorTagSelTracks: SliceCache appears too early (before end of Produces<).
Preslice<aod::Tracks> perCol = aod::track::collisionId;

Check warning on line 202 in PWGHF/TableProducer/trackIndexSkimCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[pwghf/struct-member-order]

HfTrackIndexSkimCreatorTagSelTracks: Preslice< appears too early (before end of using).

Produces<aod::HfSelTrack> rowSelectedTrack;
Produces<aod::HfPvRefitTrack> tabPvRefitTrack;
Expand Down Expand Up @@ -543,7 +543,7 @@
hasGoodQuality = false;
}
} else {
UChar_t clustermap = hfTrack.itsClusterMap();

Check warning on line 546 in PWGHF/TableProducer/trackIndexSkimCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root-entity]

Consider replacing ROOT entities with equivalents from standard C++ or from O2.
if (!(hfTrack.tpcNClsFound() >= config.tpcNClsFoundMin.value && // is this the number of TPC clusters? It should not be used
TESTBIT(hfTrack.flags(), o2::aod::track::ITSrefit) &&
(TESTBIT(clustermap, 0) || TESTBIT(clustermap, 1)))) {
Expand Down Expand Up @@ -579,7 +579,7 @@
hasGoodQuality = false;
}
} else { // selections for Run2 converted data
UChar_t clustermap = hfTrack.itsClusterMap();

Check warning on line 582 in PWGHF/TableProducer/trackIndexSkimCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root-entity]

Consider replacing ROOT entities with equivalents from standard C++ or from O2.
if (!(TESTBIT(hfTrack.flags(), o2::aod::track::ITSrefit) && (TESTBIT(clustermap, 0) || TESTBIT(clustermap, 1)))) {
hasGoodQuality = false;
}
Expand Down Expand Up @@ -608,7 +608,7 @@
hasGoodQuality = false;
}
} else { // selections for Run2 converted data
UChar_t clustermap = hfTrack.itsClusterMap();

Check warning on line 611 in PWGHF/TableProducer/trackIndexSkimCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root-entity]

Consider replacing ROOT entities with equivalents from standard C++ or from O2.
if (!(TESTBIT(hfTrack.flags(), o2::aod::track::ITSrefit) && (TESTBIT(clustermap, 0) || TESTBIT(clustermap, 1)))) {
hasGoodQuality = false;
}
Expand Down Expand Up @@ -1920,7 +1920,7 @@
}
recalcPvRefit = true;
int nCandContr = 0;
for (uint64_t myGlobalID : vecCandPvContributorGlobId) {

Check warning on line 1923 in PWGHF/TableProducer/trackIndexSkimCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[const-ref-in-for-loop]

Use constant references for non-modified iterators in range-based for loops.
auto trackIterator = std::find(vecPvContributorGlobId.begin(), vecPvContributorGlobId.end(), myGlobalID); /// track global index
if (trackIterator != vecPvContributorGlobId.end()) {
/// this is a contributor, let's remove it for the PV refit
Expand Down Expand Up @@ -2270,7 +2270,7 @@
}

if (config.debug) {
int Prong2CutStatus[kN2ProngDecays];

Check warning on line 2273 in PWGHF/TableProducer/trackIndexSkimCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
for (int iDecay2P = 0; iDecay2P < kN2ProngDecays; iDecay2P++) {
Prong2CutStatus[iDecay2P] = nCutStatus2ProngBit[iDecay2P];
for (int iCut = 0; iCut < kNCuts2Prong[iDecay2P]; iCut++) {
Expand Down Expand Up @@ -2526,7 +2526,7 @@
}

if (config.debug) {
int Prong3CutStatus[kN3ProngDecays];

Check warning on line 2529 in PWGHF/TableProducer/trackIndexSkimCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
for (int iDecay3P = 0; iDecay3P < kN3ProngDecays; iDecay3P++) {
Prong3CutStatus[iDecay3P] = nCutStatus3ProngBit[iDecay3P];
for (int iCut = 0; iCut < kNCuts3Prong[iDecay3P]; iCut++) {
Expand Down Expand Up @@ -2771,7 +2771,7 @@
}

if (config.debug) {
int Prong3CutStatus[kN3ProngDecays];

Check warning on line 2774 in PWGHF/TableProducer/trackIndexSkimCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
for (int iDecay3P = 0; iDecay3P < kN3ProngDecays; iDecay3P++) {
Prong3CutStatus[iDecay3P] = nCutStatus3ProngBit[iDecay3P];
for (int iCut = 0; iCut < kNCuts3Prong[iDecay3P]; iCut++) {
Expand Down Expand Up @@ -3363,15 +3363,15 @@
registry.add("hDCACascDau", "hDCACascDau", {HistType::kTH1D, {{500, 0.0f, 5.0f, "cm^{2}"}}});
registry.add("hLambdaMass", "hLambdaMass", {HistType::kTH1D, {{400, 0.916f, 1.316f, "Inv. Mass (GeV/c^{2})"}}});

//pT rej
// pT rej
registry.add("hPtCutsXicZeroOmegacZeroToXiPi", "Omegac/Xic to Xi Pi tracks selected by pT;#it{p}_{T} (GeV/#it{c});entries", {HistType::kTH1D, {{500, 0., 50.}}});
registry.add("hPtCutsOmegacZeroToOmegaPi", "Omegac to Omega Pi tracks selected by pT;#it{p}_{T} (GeV/#it{c});entries", {HistType::kTH1D, {{500, 0., 50.}}});
registry.add("hPtCutsOmegacZeroToOmegaKa", "Omegac to Omega Ka tracks selected by pT;#it{p}_{T} (GeV/#it{c});entries", {HistType::kTH1D, {{500, 0., 50.}}});
registry.add("hPtCutsXicPlusToXiPiPi", "Xicplus to Xi Pi Pi tracks selected by pT;#it{p}_{T} (GeV/#it{c});entries", {HistType::kTH1D, {{500, 0., 50.}}});
registry.add("hRejpTStatusXicZeroOmegacZeroToXiPi", "XicZeroOmegacZeroToXiPi rejected by pT status;status;entries", {HistType::kTH1D, {{2, -0.5, 1.5}}}); //pass dcafitter --> 0, pT>pTmin --> 1
registry.add("hRejpTStatusOmegacZeroToOmegaPi", "OmegacZeroToOmegaPi rejected by pT status;status;entries", {HistType::kTH1D, {{2, -0.5, 1.5}}});
registry.add("hRejpTStatusOmegacZeroToOmegaKa", "OmegacZeroToOmegaKa rejected by pT status;status;entries", {HistType::kTH1D, {{2, -0.5, 1.5}}});
registry.add("hRejpTStatusXicPlusToXiPiPi", "XicPlusToXiPiPi rejected by pT status;status;entries", {HistType::kTH1D, {{2, -0.5, 1.5}}});
registry.add("hRejpTStatusXicZeroOmegacZeroToXiPi", "XicZeroOmegacZeroToXiPi rejected by pT status;status;entries", {HistType::kTH1D, {{2, -0.5, 1.5}}}); // pass dcafitter --> 0, pT>pTmin --> 1
registry.add("hRejpTStatusOmegacZeroToOmegaPi", "OmegacZeroToOmegaPi rejected by pT status;status;entries", {HistType::kTH1D, {{2, -0.5, 1.5}}});
registry.add("hRejpTStatusOmegacZeroToOmegaKa", "OmegacZeroToOmegaKa rejected by pT status;status;entries", {HistType::kTH1D, {{2, -0.5, 1.5}}});
registry.add("hRejpTStatusXicPlusToXiPiPi", "XicPlusToXiPiPi rejected by pT status;status;entries", {HistType::kTH1D, {{2, -0.5, 1.5}}});

// mass spectra
registry.add("hMassXicZeroOmegacZeroToXiPi", "2-prong candidates;inv. mass (#Xi #pi) (GeV/#it{c}^{2});entries", {HistType::kTH1D, {{500, 2., 3.}}});
Expand Down Expand Up @@ -3575,13 +3575,11 @@
std::array<std::array<float, 3>, 2> arrMomToXi = {pVecXi, pVecPion1XiHyp};
auto mass2ProngXiHyp = RecoDecay::m(arrMomToXi, arrMass2Prong[hf_cand_casc_lf::DecayType2Prong::XiczeroOmegaczeroToXiPi]);

if ((std::abs(casc.mXi() - massXi) < config.cascadeMassWindow) && (mass2ProngXiHyp >= config.massXiPiMin) && (mass2ProngXiHyp <= config.massXiPiMax))
{
registry.fill(HIST("hRejpTStatusXicZeroOmegacZeroToXiPi"),0);
if (ptXic >= config.ptMinXicZeroOmegacZeroToXiPiLfCasc)
{
if ((std::abs(casc.mXi() - massXi) < config.cascadeMassWindow) && (mass2ProngXiHyp >= config.massXiPiMin) && (mass2ProngXiHyp <= config.massXiPiMax)) {
registry.fill(HIST("hRejpTStatusXicZeroOmegacZeroToXiPi"), 0);
if (ptXic >= config.ptMinXicZeroOmegacZeroToXiPiLfCasc) {
SETBIT(hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::XiczeroOmegaczeroToXiPi);
registry.fill(HIST("hRejpTStatusXicZeroOmegacZeroToXiPi"),1);
registry.fill(HIST("hRejpTStatusXicZeroOmegacZeroToXiPi"), 1);
}
}

Expand Down Expand Up @@ -3625,24 +3623,19 @@
auto mass2ProngOmegaPiHyp = RecoDecay::m(arrMomToOmega, arrMass2Prong[hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaPi]);
auto mass2ProngOmegaKHyp = RecoDecay::m(arrMomToOmega, arrMass2Prong[hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaK]);

if (std::abs(casc.mOmega() - massOmega) < config.cascadeMassWindow)
{
if ((mass2ProngOmegaPiHyp >= config.massOmegaCharmBachelorMin) && (mass2ProngOmegaPiHyp <= config.massOmegaCharmBachelorMax))
{
registry.fill(HIST("hRejpTStatusOmegacZeroToOmegaPi"),0);
if (ptOmegac >= config.ptMinOmegacZeroToOmegaPiLfCasc)
{
if (std::abs(casc.mOmega() - massOmega) < config.cascadeMassWindow) {
if ((mass2ProngOmegaPiHyp >= config.massOmegaCharmBachelorMin) && (mass2ProngOmegaPiHyp <= config.massOmegaCharmBachelorMax)) {
registry.fill(HIST("hRejpTStatusOmegacZeroToOmegaPi"), 0);
if (ptOmegac >= config.ptMinOmegacZeroToOmegaPiLfCasc) {
SETBIT(hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaPi);
registry.fill(HIST("hRejpTStatusOmegacZeroToOmegaPi"),1);
registry.fill(HIST("hRejpTStatusOmegacZeroToOmegaPi"), 1);
}
}
if ((mass2ProngOmegaKHyp >= config.massOmegaCharmBachelorMin) && (mass2ProngOmegaKHyp <= config.massOmegaCharmBachelorMax))
{
registry.fill(HIST("hRejpTStatusOmegacZeroToOmegaKa"),0);
if (ptOmegac >= config.ptMinOmegaczeroToOmegaKaLfCasc)
{
if ((mass2ProngOmegaKHyp >= config.massOmegaCharmBachelorMin) && (mass2ProngOmegaKHyp <= config.massOmegaCharmBachelorMax)) {
registry.fill(HIST("hRejpTStatusOmegacZeroToOmegaKa"), 0);
if (ptOmegac >= config.ptMinOmegaczeroToOmegaKaLfCasc) {
SETBIT(hfFlag, aod::hf_cand_casc_lf::DecayType2Prong::OmegaczeroToOmegaK);
registry.fill(HIST("hRejpTStatusOmegacZeroToOmegaKa"),1);
registry.fill(HIST("hRejpTStatusOmegacZeroToOmegaKa"), 1);
}
}
}
Expand Down Expand Up @@ -3733,12 +3726,11 @@
std::array<std::array<float, 3>, 3> arr3Mom = {pVec1, pVec2, pVec3};
auto mass3Prong = RecoDecay::m(arr3Mom, arrMass3Prong[hf_cand_casc_lf::DecayType3Prong::XicplusToXiPiPi]);

if ((std::abs(casc.mXi() - massXi) < config.cascadeMassWindow) && (mass3Prong >= config.massXiPiPiMin) && (mass3Prong <= config.massXiPiPiMax))
{ registry.fill(HIST("hRejpTStatusXicPlusToXiPiPi"),0);
if (ptXic3Prong >= config.ptMinXicplusLfCasc)
{
if ((std::abs(casc.mXi() - massXi) < config.cascadeMassWindow) && (mass3Prong >= config.massXiPiPiMin) && (mass3Prong <= config.massXiPiPiMax)) {
registry.fill(HIST("hRejpTStatusXicPlusToXiPiPi"), 0);
if (ptXic3Prong >= config.ptMinXicplusLfCasc) {
SETBIT(hfFlag, aod::hf_cand_casc_lf::DecayType3Prong::XicplusToXiPiPi);
registry.fill(HIST("hRejpTStatusXicPlusToXiPiPi"),1);
registry.fill(HIST("hRejpTStatusXicPlusToXiPiPi"), 1);
}
}

Expand Down
Loading