Skip to content

[PWGCF] Add q-space K+K- balance function task - #18859

Open
lakshithaf1998 wants to merge 12 commits into
AliceO2Group:masterfrom
lakshithaf1998:qspace-kk-bf
Open

lakshithaf1998 wants to merge 12 commits into
AliceO2Group:masterfrom
lakshithaf1998:qspace-kk-bf

Conversation

@lakshithaf1998

Copy link
Copy Markdown

Adds a new PWGCF/TwoParticleCorrelations task, o2-analysis-cf-q-space-balance-function, for K+K- balance functions in q-space (Q_inv, Q_long, Q_out, Q_side).

  • Reads the existing DptDpt filter tables; works at generator level and at detector level on MC with truth matching.
  • Same-event and mixed-event pair densities per (z_vtx, FT0C multiplicity) class. Mixing uses its own cross-data-frame event pool, with configurable depth.
  • A2 = C2/N and B(Q) in both the C2 (rho2 - rho1 rho1) and n2 versions; statistical errors from 10 event subsamples.
  • Validated locally on MC
  • O2 linter passes; builds and runs on current master (99f6526) without errors.

AI use: this code was developed with AI assistance (Claude); I reviewed, built and tested it myself and take responsibility for it.

Lakshitha Fernando and others added 7 commits November 8, 2026 13:18
…st version

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

Claude-Session: https://claude.ai/code/session_01Tpx2ZQ7HXMcQXLLUbEx35H
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Tpx2ZSUeCZncb9cRCRUxvQ
…ay, none)

Beam and non-hadron mothers are rejected, same criterion as particleOriginAnalysis.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Claude-Session: https://claude.ai/code/session_01Tpx2ZQhMsissFM7LZMPFGi
…urity and Q resolution

Histograms grouped per level (generator at top level, detector under rec/); MC origin split at both levels; split tracks never count as a common mother.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Claude-Session: https://claude.ai/code/session_01Tpx2ZQhMsissFM7LZMPFGi
@github-actions

github-actions Bot commented Nov 22, 2026 •

Copy link
Copy Markdown

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

using HistoPerCharge = std::array<std::shared_ptr<TH1>, NCharges>;
using Histo2DPerCharge = std::array<std::shared_ptr<TH2>, NCharges>;
using Histo2DPerPair = std::array<Histo2DPerCharge, NCharges>;
using HistoPerPair = std::array<HistoPerCharge, NCharges>;

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.

camelCase is suggested

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you point me to the names you mean? These are type aliases, and the O2 linter rule for types asks for UpperCamelCase (HistoPerCharge, Histo2DPerPair, ...). I am happy to rename anything that does not follow the convention.

@wenyaCern wenyaCern left a comment

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.

Please fix the errors reported by the linters

@lakshithaf1998

Copy link
Copy Markdown
Author

Thanks for the review. I ran the O2 linter locally the same way as CI: qSpaceBalanceFunction.cxx and QSpaceKinematics.h now have no errors and no warnings, and MegaLinter passes after adding #include . The remaining O2 linter warning is in PWGCF/TwoParticleCorrelations/Tasks/CMakeLists.txt, from the workflow names of existing tasks (e.g. nuclei-balance, mft-correlations), not from the q-space lines. Please let me know if you see another error I should fix.

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