-
Notifications
You must be signed in to change notification settings - Fork 625
[PWGCF] Update flowEventPlane.cxx #14531
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[PWGCF] Update flowEventPlane.cxx #14531
Conversation
yashpatley
commented
Jan 17, 2026
- Added track table to fix previous error of table size mismatch
- Added v0 flow
1. Added track table to fix previous error of table size mismatch 2. Added v0 flow
|
O2 linter results: ❌ 0 errors, |
Removed mass calculation for Lambda and AntiLambda.
victor-gonzalez
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess there are no plans of using stored derived data
Why then recreate and store information that is already available in the Tracks tabel?
|
Dear Victor, |
|
Well, the memory usage will increase quite a lot if the |
|
Dear Victor, please have a look at the new update to this PR. Thanks. Please let me know if there are further suggestions. |
victor-gonzalez
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have a look at may comment in case you want to consider it (it will decrease the CPU consumption)
| if (partType == kPi && checkTrackPid<kPi, kKa, kPr>(vPtCut[kPi], track.pt(), vTpcNsig, vTofNsig, track.hasTOF())) { | ||
| retFlag = true; | ||
| } else if (partType == kKa && checkTrackPid<kKa, kPi, kPr>(vPtCut[kKa], track.pt(), vTpcNsig, vTofNsig, track.hasTOF())) { | ||
| retFlag = true; | ||
| } else if (partType == kPr && checkTrackPid<kPr, kPi, kKa>(vPtCut[kPr], track.pt(), vTpcNsig, vTofNsig, track.hasTOF())) { | ||
| retFlag = true; | ||
| } else { | ||
| return false; | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would suggest this construction
if constexpr (partType == kPi) {
// additional conditions for pions setting the retFlag
}
if constexpr (partType == kKa) {
// additional conditions for kaons setting the retFlag
}
if constexpr (partType == kPr) {
// additional conditions for protons setting the retFlag
}
return retFlag;
In that way the compiler will generate the corresponding copy of the routine and the protons will not always suffer two unsuccessful ifs
That's the magic of the template mechanism