Skip to content

[PWGJE] Adding new Angularity Task to PWGJE - #17299

Draft
Rajdeep-nandi wants to merge 4 commits into
AliceO2Group:masterfrom
Rajdeep-nandi:master
Draft

[PWGJE] Adding new Angularity Task to PWGJE#17299
Rajdeep-nandi wants to merge 4 commits into
AliceO2Group:masterfrom
Rajdeep-nandi:master

Conversation

@Rajdeep-nandi

Copy link
Copy Markdown

This Task calculates the Angularity for D0 particles.

@github-actions github-actions Bot added the pwgje label Aug 3, 2026
@github-actions github-actions Bot changed the title Adding new Angularity Task to PWGJE [PWGJE] Adding new Angularity Task to PWGJE Aug 3, 2026
@vkucera
vkucera marked this pull request as draft August 3, 2026 14:59
@vkucera

vkucera commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator

@Rajdeep-nandi Please follow the contribution guidelines and make sure your PR passes the tests before you open it for review.

#include "PWGJE/DataModel/Jet.h"
#include "PWGJE/DataModel/JetReducedData.h"
#include "PWGJE/DataModel/JetReducedDataHF.h"
#include "PWGJE/DataModel/JetSubstructure.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.

you seem to have alot of includes which i am not sure are needed?

@vkucera vkucera Aug 3, 2026

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.

When you look at the output of the code-check, you will be sure. ;-)

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.

Will the code check run if I dont approve? It seems to be waiting for approval

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.

No it won't, as neither build check would. It requires your approval but also a valid PR that can be merged, which is currently not the case.

Rajdeep-nandi added a commit to Rajdeep-nandi/O2Physics that referenced this pull request Aug 4, 2026
Please consider the following formatting changes to AliceO2Group#17299
@github-actions

github-actions Bot commented Aug 4, 2026

Copy link
Copy Markdown

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

… issues, remove unused includes, apply clang-format
@nzardosh
nzardosh marked this pull request as ready for review August 6, 2026 11:30
@nzardosh
nzardosh self-requested a review August 6, 2026 11:30
@alibuild

alibuild commented Aug 6, 2026

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/staging for 5a7ac58 at 2026-08-06 13:39:

## sw/BUILD/O2Physics-latest/log
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:733:25: error: 'kOriginMcPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:735:32: error: 'kOriginMcNonPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:900:27: error: 'kOriginMcPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:902:34: error: 'kOriginMcNonPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:998:25: error: 'kOriginMcPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:1000:32: error: 'kOriginMcNonPrompt' was not declared in this scope
ninja: build stopped: subcommand failed.

Full log here.

@alibuild

alibuild commented Aug 6, 2026

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/o2 for 5a7ac58 at 2026-08-06 13:40:

## sw/BUILD/O2Physics-latest/log
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:733:25: error: 'kOriginMcPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:735:32: error: 'kOriginMcNonPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:900:27: error: 'kOriginMcPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:902:34: error: 'kOriginMcNonPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:998:25: error: 'kOriginMcPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:1000:32: error: 'kOriginMcNonPrompt' was not declared in this scope
ninja: build stopped: subcommand failed.

Full log here.

@alibuild

alibuild commented Aug 6, 2026

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/code-check for 5a7ac58 at 2026-08-06 13:40:

## sw/BUILD/O2Physics-latest/log
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:733:25: error: 'kOriginMcPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:735:32: error: 'kOriginMcNonPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:900:27: error: 'kOriginMcPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:902:34: error: 'kOriginMcNonPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:998:25: error: 'kOriginMcPrompt' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGJE/Tasks/jetHFAngularity.cxx:1000:32: error: 'kOriginMcNonPrompt' was not declared in this scope
ninja: build stopped: subcommand failed.

Full log here.

@vkucera
vkucera marked this pull request as draft August 6, 2026 11:42
Comment on lines +172 to +175
consteval float getValFromBin(int bin)
{
return static_cast<float>(bin) - 0.5f;
}

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.

useless

Comment on lines +397 to +399
static_cast<std::string>(eventSelections));
trackSelection = jetderiveddatautilities::initialiseTrackSelection(
static_cast<std::string>(trackSelections));

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.

Use .value.

Comment on lines +498 to +506
const double px = trk.pt() * std::cos(trk.phi());
const double py = trk.pt() * std::sin(trk.phi());
const double pz = trk.pt() * std::sinh(trk.eta());
const double p = std::sqrt(px * px + py * py + pz * pz);

sumPx += px;
sumPy += py;
sumPz += pz;
sumE += p;

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.

Useless. Use existing tools.

Comment on lines +527 to +533
const double p = std::sqrt(px * px + py * py + pz * pz);
const double e = std::sqrt(p * p + m * m);

sumPx += px;
sumPy += py;
sumPz += pz;
sumE += e;

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.

Useless. Use existing tools.

sumE += e;
}

const double m2 = sumE * sumE - (sumPx * sumPx + sumPy * sumPy + sumPz * sumPz);

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.

Useless. Use existing tools.

Comment on lines +607 to +610
TVector3 d0Vector(d0Candidate.px(), d0Candidate.py(), d0Candidate.pz());

// Longitudinal momentum fraction
const float zParallel = jetVector.Dot(d0Vector) / jetVector.Dot(jetVector);

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.

Useless. Use existing tools.

Comment on lines +882 to +884
const int8_t geoStatus = static_cast<int8_t>(isGeoMatched ? 1 : 0);
const int8_t candStatus = static_cast<int8_t>(isCandMatched ? 1 : 0);
const int8_t cleanStatus = static_cast<int8_t>(isCleanMatched ? 1 : 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.

Why don't you cast the bool directly?

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.

4 participants