Skip to content

[PWGLF] Nuspex: deuteron proton correlation, add pileup and PID with quadratic cut#16724

Merged
maciacco merged 11 commits into
AliceO2Group:masterfrom
ercolessi:jets
Jun 18, 2026
Merged

[PWGLF] Nuspex: deuteron proton correlation, add pileup and PID with quadratic cut#16724
maciacco merged 11 commits into
AliceO2Group:masterfrom
ercolessi:jets

Conversation

@ercolessi

Copy link
Copy Markdown
Collaborator

No description provided.

@github-actions

Copy link
Copy Markdown

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

@maciacco maciacco enabled auto-merge (squash) June 18, 2026 09:25
@maciacco maciacco merged commit 9f3e01c into AliceO2Group:master Jun 18, 2026
12 of 13 checks passed
Comment on lines +73 to +75
kPrimary = 0,
kWeakDecay,
kMaterial

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.

Remove the k prefix.

if (isTPCPID) {
if (track.pt() < pTthrpr_TOF) {
if (!doITSPID || isITSPID) {
bool isQuadraticPID = TMath::Sqrt(track.tpcNSigmaPr() * track.tpcNSigmaPr() + track.tofNSigmaPr() * track.tofNSigmaPr()) < nsigmaTPC;

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 introduce warnings or errors. Consider using std::hypot instead.

Comment on lines +456 to +468
if (sign > 0) {
if (track.sign() > 0) {
isProton = true;
} else if (track.sign() < 0) {
isProton = false;
}
} else if (sign < 0) {
if (track.sign() > 0) {
isProton = false;
} else if (track.sign() < 0) {
isProton = true;
}
}

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.

This seems equivalent to isProton = sign * track.sign() > 0.

Comment on lines +485 to 497
if (sign > 0) {
if (track.sign() > 0) {
isProton = true;
} else if (track.sign() < 0) {
isProton = false;
}
} else if (sign < 0) {
if (track.sign() > 0) {
isProton = false;
} else if (track.sign() < 0) {
isProton = true;
}
}

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.

You are duplicating the same block several times.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Development

Successfully merging this pull request may close these issues.

3 participants