Skip to content

[PWGHF] added new file for Xic correlation#16510

Draft
singhra1994 wants to merge 4 commits into
AliceO2Group:masterfrom
singhra1994:master
Draft

[PWGHF] added new file for Xic correlation#16510
singhra1994 wants to merge 4 commits into
AliceO2Group:masterfrom
singhra1994:master

Conversation

@singhra1994
Copy link
Copy Markdown
Collaborator

No description provided.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 2, 2026

O2 linter results: ❌ 2 errors, ⚠️ 0 warnings, 🔕 0 disabled

Please consider the following formatting changes to AliceO2Group#16510
Comment on lines +1498 to +1499
static constexpr std::size_t NDaughtersXic0 = static_cast<std::size_t>(XicDecayDaughtersCount::Xic0DaughtersCount);
static constexpr std::size_t NDaughtersXicPlus = static_cast<std::size_t>(XicDecayDaughtersCount::XicPlusDaughtersCount);
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do you need these aliases?

Comment on lines +16 to +27
#include "PWGHF/Core/DecayChannels.h"
#include "PWGHF/Core/DecayChannelsLegacy.h"
#include "PWGHF/Core/HfHelper.h"
#include "PWGHF/Core/SelectorCuts.h"
#include "PWGHF/DataModel/AliasTables.h"
#include "PWGHF/DataModel/CandidateReconstructionTables.h"
#include "PWGHF/DataModel/CandidateSelectionTables.h"
#include "PWGHF/DataModel/TrackIndexSkimmingTables.h"
#include "PWGHF/HFC/DataModel/CorrelationTables.h"
#include "PWGHF/HFC/Utils/utilsCorrelations.h"
#include "PWGHF/Utils/utilsAnalysis.h"
#include "PWGLF/DataModel/LFStrangenessTables.h"
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you sure you need all these?

Comment on lines +81 to +84
o2physics_add_dpl_workflow(correlator-xic-hadrons
SOURCES correlatorXicHadrons.cxx
PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore
COMPONENT_NAME Analysis)
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Respect the alphabetical ordering and spacing.

Comment on lines +169 to +170
Filter xic0Filter = aod::hf_sel_toxipi::resultSelections == true;
template <bool isXicPlus, typename CollType, typename CandType>
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Filter xic0Filter = aod::hf_sel_toxipi::resultSelections == true;
template <bool isXicPlus, typename CollType, typename CandType>
Filter xic0Filter = aod::hf_sel_toxipi::resultSelections == true;
template <bool isXicPlus, typename CollType, typename CandType>

Comment on lines +268 to +269
if (!collision.sel8()) {
return 0;
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

0 is not bool.

bool isPrompt = false;
bool isNonPrompt = false;
bool isSignal = false;
TRandom3* rnd = new TRandom3(0);
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't use dynamic memory allocation if you don't have to.


BinningType corrBinning{{binsZVtx, binsMultiplicity}, true};

HistogramRegistry registry{"registry", {}, OutputObjHandlingPolicy::AnalysisObject};
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't specify the arguments if you are using the default values.

Suggested change
HistogramRegistry registry{"registry", {}, OutputObjHandlingPolicy::AnalysisObject};
HistogramRegistry registry{"registry"};

Comment on lines +665 to +674
case kXiC0:
return 0.5f; // Xic0
case -kXiC0:
return -0.5f; // Xic0-bar
case kXiCPlus:
return 1.5f; // XicPlus
case -kXiCPlus:
return -1.5f; // XicMinus
default:
return 0.f;
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do the return values mean?

Comment on lines +709 to +712
ROOT::Math::PtEtaPhiMVector vec1(pT1, eta1, phi1, mass1);
ROOT::Math::PtEtaPhiMVector vec2(particle2.pt(), particle2.eta(), particle2.phi(), mass2);
ROOT::Math::PtEtaPhiMVector combined = vec1 + vec2;
return combined.mass();
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why don't you use RecoDecay methods?

Comment on lines +718 to +721
ROOT::Math::PtEtaPhiMVector vec1(pT1, eta1, phi1, 0.);
ROOT::Math::PtEtaPhiMVector vec2(particle2.pt(), particle2.eta(), particle2.phi(), 0.);
ROOT::Math::PtEtaPhiMVector combined = vec1 + vec2;
return combined.pt();
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same

@vkucera vkucera marked this pull request as draft June 2, 2026 16:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pwghf PWG-HF

Development

Successfully merging this pull request may close these issues.

3 participants