[PWGLF] Add percentile-based flattenicity classes and corrections - #17723
Merged
Conversation
sprasadphy
requested review from
alibuild,
ercolessi,
lhusova,
mpuccio,
omvazque,
romainschotter and
skundu692
as code owners
September 2, 2026 03:48
|
O2 linter results: ❌ 0 errors, |
romainschotter
approved these changes
Sep 2, 2026
romainschotter
enabled auto-merge (squash)
September 2, 2026 05:20
Collaborator
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This version of PR contains major changes inspired by fixing memory problem in the existing way to storing the values. Following changes have been done.
This PR adds the machinery to define flattenicity classes from measured percentiles and apply the corresponding corrections to K0s, Lambda, AntiLambda, and Xi spectra. The output is additive: 60 new histograms are added, with none removed or renamed.
Percentile-driven classes: The relevant axes are now
ConfigurableAxis, allowing the 1-rho boundaries to be taken directly from measured percentiles. NewprocessFlatDistData/processFlatDistMCprocesses provide the flattenicity distributions needed to determine these boundaries.MC closure: Efficiency and loss histograms now also have
_TrueFlatversions based on generator-level 1-rho, together with class-migration and event-selection-bias matrices. Both measured- and true-class estimates are produced inprocessGenMC, whileflattenicityforLossCorrRecselects which one is used for the corrections.4.Correction inputs: Added the feed-down response matrices and generated mother spectra in the same events/classes, along with DCA-of-V0-to-PV templates, pT resolution, and charged-particle information needed for the multiplicity-dependent corrections.
5.Calibration from CCDB: The hardcoded flattenicity calibration constants are replaced with per-run CCDB objects for channel gains and z-vertex equalisation. Both calibrations are disabled by default, with a unity fallback and warning when an object is missing; the z-vertex correction now acts directly on the lattice cells.
6.Fixes: Generated-particle rapidity now follows the reconstructed rapidity settings, shared histograms cannot be double-counted across processes, and MC denominators correctly follow
applyCentSel. Daughter selection is shared between V0 and cascade paths,processDataRun3Cascadenow defaults tofalse, and unsupportedflattenicityforanalysissettings in MC are rejected.