Skip to content

[PWGJE] jetCrossSectionEfficiency: cascade variants + hybrid-MC handling#16546

Merged
nzardosh merged 4 commits into
AliceO2Group:masterfrom
joonsukbae:feature-pwgje-jetXsecEff-cascade
Jun 5, 2026
Merged

[PWGJE] jetCrossSectionEfficiency: cascade variants + hybrid-MC handling#16546
nzardosh merged 4 commits into
AliceO2Group:masterfrom
joonsukbae:feature-pwgje-jetXsecEff-cascade

Conversation

@joonsukbae

Copy link
Copy Markdown
Contributor
  • Rewrite the QC task as two ordering variants exposing the cumulative
    inefficiency through the analysis selection cascade:

    • processCrossSectionEfficiency (default): reco-collision-first
      (cascade = sel-bits via reco-coll EvSel bitmask, then NoSplit + zReco).

    • processCrossSectionEfficiencyBcBitsFirst: alternative ordering with
      sel-bits read from the truth BC (Preslice on JBCs) and reco-coll
      evaluated last; for systematic check.

  • Cascade auto-adapts to {selTVX, selMC, selMCFull, sel8, sel8Full}

  • Unified weighted/unweighted fills via mccollision.weight() (= 1 for MB).

  • Outlier rejection via pTHat (stored ptHard, or weight-derived for legacy
    cases) gated by pTHatMaxMCP; named broken-sentinel constant.

  • applyRCT toggles the RCT step independently; preset label is a
    Configurable.

Co-Authored-By: Claude Opus 4.7

Joonsuk Bae and others added 2 commits June 6, 2026 01:39
- Rewrite the QC task as two ordering variants exposing the cumulative
  inefficiency through the analysis selection cascade:
  - processCrossSectionEfficiency (default): reco-collision-first
    (cascade = sel-bits via reco-coll EvSel bitmask, then NoSplit + zReco).
  - processCrossSectionEfficiencyBcBitsFirst: alternative ordering with
    sel-bits read from the truth BC (Preslice on JBCs) and reco-coll
    evaluated last; for systematic check.
- Cascade auto-adapts to {selTVX, selMC, selMCFull, sel8, sel8Full}; steps
  not in the preset pass through so bin count/order stays constant.
- Skips min-bias gap events via getSubGeneratorId() == mbGap when
  skipMBGapEvents = true (hybrid MB+JJ MC productions).
- Unified weighted/unweighted fills via mccollision.weight() (= 1 for MB).
- Outlier rejection via pTHat (stored ptHard, or weight-derived for legacy
  cases) gated by pTHatMaxMCP; named broken-sentinel constant.
- Restores all upstream-side Configurables (centrality*, trackOccupancy*,
  selectedJetsRadius, checkCentFT0M) for backward compatibility, even
  when unused on the pp MB MC nominal path.
- applyRCT toggles the RCT step independently; preset label is a
  Configurable.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@github-actions

github-actions Bot commented Jun 5, 2026

Copy link
Copy Markdown

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

Please consider the following formatting changes to AliceO2Group#16546
@nzardosh nzardosh enabled auto-merge (squash) June 5, 2026 17:12
@nzardosh nzardosh merged commit 090d868 into AliceO2Group:master Jun 5, 2026
14 checks passed
jjuracka pushed a commit to jjuracka/O2Physics that referenced this pull request Jun 6, 2026
…ing (AliceO2Group#16546)

Co-authored-by: Joonsuk Bae <monkeybae@kiaf-ui.sdfarm.kr>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-authored-by: ALICE Action Bot <alibuild@cern.ch>
Comment on lines +91 to +116
static constexpr float kBrokenPtHardSentinel = 1.0f;

// CollRecoFirst: reco collision required first; BC bits read from the reco-coll EvSels.
static constexpr int kBinCRF_Inel = 1;
static constexpr int kBinCRF_RctPass = 2;
static constexpr int kBinCRF_HasColl = 3;
static constexpr int kBinCRF_Zreco = 4;
static constexpr int kBinCRF_NoSplit = 5;
static constexpr int kBinCRF_TVX = 6;
static constexpr int kBinCRF_TFB = 7;
static constexpr int kBinCRF_ROFB = 8;
static constexpr int kBinCRF_SBP = 9;
static constexpr int kBinCRF_N = 9;

// BcBitsFirst: BC bits read from the MC truth BC; SBP from a Preslice count
// (exactly one MC collision per truth BC) so it works before requiring reco.
static constexpr int kBinBBF_Inel = 1;
static constexpr int kBinBBF_RctPass = 2;
static constexpr int kBinBBF_TVX = 3;
static constexpr int kBinBBF_TFB = 4;
static constexpr int kBinBBF_ROFB = 5;
static constexpr int kBinBBF_TruthSBP = 6;
static constexpr int kBinBBF_HasColl = 7;
static constexpr int kBinBBF_Zreco = 8;
static constexpr int kBinBBF_NoSplit = 9;
static constexpr int kBinBBF_N = 9;

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.

  • Follow naming conventions.
  • Why is this not an enum?

rctChecker.init(static_cast<std::string>(rctSelectionsLabel));
rctMask = rctChecker.value();

const std::string es = eventSelections;

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 do you create a new variable?

Comment on lines +130 to +137
if (es == "selTVX") {
applyTFB = false;
applyROFB = false;
applySBP = false;
} else if (es == "selMC") {
applyTFB = true;
applyROFB = false;
applySBP = false;

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.

There is switch for this.

Comment on lines 23 to -38
@@ -26,16 +32,9 @@
#include <Framework/InitContext.h>
#include <Framework/runDataProcessing.h>

#include <TH1.h>
#include <TH2.h>

#include <algorithm>
#include <cmath>
#include <cstddef>
#include <set>
#include <cstdint>
#include <string>
#include <utility>
#include <vector>

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.

@joonsukbae How did you come up with these changes?
@nzardosh Please pay attention to these changes.

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.

yes @joonsukbae please fix these in your next PR. Since I assume these might be needed for HP I approved them fast

fjonasALICE pushed a commit to fjonasALICE/O2Physics that referenced this pull request Jun 9, 2026
…ing (AliceO2Group#16546)

Co-authored-by: Joonsuk Bae <monkeybae@kiaf-ui.sdfarm.kr>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-authored-by: ALICE Action Bot <alibuild@cern.ch>
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