Skip to content

[PWGLF] Fix condition to check particle pt against ptCut - #17335

Open
njacazio wants to merge 4 commits into
masterfrom
njacazio-patch-4
Open

[PWGLF] Fix condition to check particle pt against ptCut#17335
njacazio wants to merge 4 commits into
masterfrom
njacazio-patch-4

Conversation

@njacazio

@njacazio njacazio commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

No description provided.

@github-actions

github-actions Bot commented Aug 5, 2026

Copy link
Copy Markdown

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

@github-actions github-actions Bot changed the title Fix condition to check particle pt against ptCut [PWGLF] Fix condition to check particle pt against ptCut Aug 5, 2026
@alibuild

alibuild commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/staging for 63a60cb at 2026-08-05 12:13:

## sw/BUILD/O2-latest/log
CMake Error in Detectors/Base/CMakeLists.txt:

Full log here.

@alibuild

alibuild commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/o2 for 63a60cb at 2026-08-05 12:13:

## sw/BUILD/O2-latest/log
CMake Error in Detectors/Base/CMakeLists.txt:

Full log here.

@alibuild

alibuild commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/code-check for 63a60cb at 2026-08-05 12:13:

## sw/BUILD/O2-latest/log
CMake Error in Detectors/Base/CMakeLists.txt:

Full log here.

Initialize multiplicity counters for ZEM1, ZEM2, ZPA, and ZPC estimators to zero when enabled.
@njacazio
njacazio enabled auto-merge (squash) August 5, 2026 10:40
@alibuild

alibuild commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/staging for 35c7651 at 2026-08-05 12:43:

## sw/BUILD/O2-latest/log
CMake Error in Detectors/Base/CMakeLists.txt:

Full log here.

@alibuild

alibuild commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/o2 for 35c7651 at 2026-08-05 12:43:

## sw/BUILD/O2-latest/log
CMake Error in Detectors/Base/CMakeLists.txt:

Full log here.

@alibuild

alibuild commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/code-check for 35c7651 at 2026-08-05 12:43:

## sw/BUILD/O2-latest/log
CMake Error in Detectors/Base/CMakeLists.txt:

Full log here.

Added comments indicating that ZEM1, ZEM2, ZPA, and ZPC estimators are not implemented yet.
romainschotter
romainschotter previously approved these changes Aug 5, 2026
Updated particle selection parameters and added primary selection logic for multiplicity computation.
@njacazio

njacazio commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator Author

Ciao @romainschotter I generalized the primary selection, fixed missing entries in the initializing array and the pT cut for rapidity/eta

@alibuild

alibuild commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/code-check for a00a191 at 2026-08-05 20:31:

## sw/BUILD/O2Physics-code-check-latest/log
--
========== List of issues found ==========
++ echo 'Found 35 errors and 0 warnings.'
Found 35 errors and 0 warnings.
++ [[ 35 -gt 0 ]]
++ cat /sw/BUILD/aab0d9c5ea27f6f9336ad1ef3514512fa3858e1e/O2Physics-code-check/errors.txt
PWGLF/Tasks/QC/mcParticlePrediction.cxx:60:14: error: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:123:1: error: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:123:6: error: variable 'enabledParticlesArray' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:124:1: error: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:124:6: error: variable 'selectPrimariesArray' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:151:26: error: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:183:1: error: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:183:6: error: variable 'enabledEstimatorsArray' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:184:14: error: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:206:59: error: variable 'hestimators' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:207:59: error: variable 'hestimatorsVsITS' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:208:59: error: variable 'hestimatorsVsETA05' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:209:59: error: variable 'hestimatorsVsETA08' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:210:59: error: variable 'hestimatorsVsImpactParameter' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:211:59: error: variable 'hestimatorsRecoEvGenVsReco' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:212:59: error: variable 'hestimatorsRecoEvGenVsReco_BCMC' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:213:59: error: variable 'hestimatorsRecoEvGenVsRecoITS' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:214:59: error: variable 'hestimatorsRecoEvRecoVsITS' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:215:59: error: variable 'hestimatorsRecoEvRecoVsRecoITS' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:216:59: error: variable 'hestimatorsRecoEvRecoVsRecoITS_BCMC' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:217:59: error: variable 'hestimatorsRecoEvRecoVsFT0A' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:218:59: error: variable 'hestimatorsRecoEvRecoVsBCId' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:219:59: error: variable 'hestimatorsRecoEvVsBCId' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:220:59: error: variable 'hvertexPosZ' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:221:93: error: variable 'hpt' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:222:93: error: variable 'hy' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:223:93: error: variable 'heta' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:224:93: error: variable 'hyield' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:226:8: error: constructor does not initialize these fields: pdgDB [cppcoreguidelines-pro-type-member-init,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:256:51: error: do not implicitly decay an array into a pointer; consider using gsl::array_view or an explicit cast instead [cppcoreguidelines-pro-bounds-array-to-pointer-decay,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:259:54: error: do not implicitly decay an array into a pointer; consider using gsl::array_view or an explicit cast instead [cppcoreguidelines-pro-bounds-array-to-pointer-decay,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:502:5: error: uninitialized record type: 'nMult' [cppcoreguidelines-pro-type-member-init,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:817:5: error: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays,-warnings-as-errors]
PWGLF/Tasks/QC/mcParticlePrediction.cxx:829:5: error: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays,-warnings-as-errors]
PWGLF/Utils/inelGt.h:117:11: error: using integer absolute value function 'abs' when argument is of floating point type [clang-diagnostic-absolute-value,-warnings-as-errors]
++ [[ 0 -gt 0 ]]
++ [[ 35 -gt 0 ]]
++ exit 1
--

Full log here.

@romainschotter

Copy link
Copy Markdown
Collaborator

Ciao @romainschotter I generalized the primary selection, fixed missing entries in the initializing array and the pT cut for rapidity/eta

Ciao @njacazio ! Amazing, thanks a lot for all the work!

@vkucera

vkucera commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

@romainschotter Please make sure the errors get fixed.

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