Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions PWGCF/TwoParticleCorrelations/Tasks/etaDihadron.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ struct EtaDihadron {

// make the filters and cuts.
Filter collisionFilter = (nabs(aod::collision::posZ) < cfgCutVtxZ);
Filter trackFilter = (nabs(aod::track::eta) < cfgCutEta) && (aod::track::pt > cfgCutPtMin) && (aod::track::pt < cfgCutPtMax) && ((requireGlobalTrackInFilter()) || (aod::track::isGlobalTrackSDD == (uint8_t) true)) && (aod::track::tpcChi2NCl < cfgCutChi2prTPCcls) && (nabs(aod::track::dcaZ) < cfgCutDCAz);
Filter trackFilter = (nabs(aod::track::eta) < cfgCutEta) && (aod::track::pt > cfgCutPtMin) && (aod::track::pt < cfgCutPtMax) && ((requireGlobalTrackInFilter()) || (aod::track::isGlobalTrackSDD == (uint8_t)true)) && (aod::track::tpcChi2NCl < cfgCutChi2prTPCcls) && (nabs(aod::track::dcaZ) < cfgCutDCAz);
using FilteredCollisions = soa::Filtered<soa::Join<aod::Collisions, aod::EvSel, aod::CentFT0Cs, aod::CentFT0CVariant1s, aod::CentFT0Ms, aod::CentFV0As, aod::Mults>>;
using FilteredTracks = soa::Filtered<soa::Join<aod::Tracks, aod::TrackSelection, aod::TracksExtra, aod::TracksDCA>>;
using FilteredTracksWithMCLabels = soa::Filtered<soa::Join<aod::Tracks, aod::TrackSelection, aod::TracksExtra, aod::TracksDCA, aod::McTrackLabels>>;
Expand Down Expand Up @@ -282,10 +282,10 @@ struct EtaDihadron {
registry.add("Trig_hist", "", {HistType::kTHnSparseF, {{axisSample, axisVertex, axisEtaTrigger}}});
Copy link

Copilot AI Jan 28, 2026

Choose a reason for hiding this comment

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

The histogram definition now uses axisEtaTrigger and tracks eta values, which is inconsistent with a similar implementation in PWGCF/TwoParticleCorrelations/Tasks/diHadronCor.cxx (lines 282, 285-288) where Trig_hist and solo track histograms use axisPtTrigger and track pT values. If this divergence is intentional for eta-specific analysis, consider documenting the rationale. Otherwise, these implementations should remain consistent across the codebase.

Copilot uses AI. Check for mistakes.
}
if (cfgSoloPtTrack && doprocessSame) {
registry.add("Nch_final_pt", "pT", {HistType::kTH1D, {axisEtaTrigger}});
registry.add("Solo_tracks_trigger", "pT", {HistType::kTH1D, {axisEtaTrigger}});
registry.add("Nch_final_eta", "eta", {HistType::kTH1D, {axisEtaTrigger}});
registry.add("Solo_tracks_trigger", "eta", {HistType::kTH1D, {axisEtaTrigger}});
if (!cfgSingleSoloPtTrack) {
registry.add("Solo_tracks_assoc", "pT", {HistType::kTH1D, {axisEtaAssoc}});
registry.add("Solo_tracks_assoc", "eta", {HistType::kTH1D, {axisEtaAssoc}});
Comment on lines +285 to +288
Copy link

Copilot AI Jan 28, 2026

Choose a reason for hiding this comment

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

The histogram names have been changed from "Nch_final_pt", "Solo_tracks_trigger", and "Solo_tracks_assoc" to use "eta" instead of "pt", and they are now filled with eta values. However, the configuration variable cfgSoloPtTrack (line 103) and the function findBiasedTracks (line 838-875) still refer to pT bins. This creates semantic confusion - the feature is configured and documented as being about pT bins, but the histograms now record eta values. Consider either: (1) keeping the original pT-based histogram fills to maintain consistency with the feature's purpose, or (2) if eta tracking is intentional, update the configuration variable names and function names to reflect this change in behavior.

Copilot uses AI. Check for mistakes.
}
}

Expand All @@ -308,7 +308,7 @@ struct EtaDihadron {
registry.add("MCTrue/MCPhi", "MCPhi", {HistType::kTH1D, {axisPhi}});
registry.add("MCTrue/MCEta", "MCEta", {HistType::kTH1D, {axisEta}});
registry.add("MCTrue/MCpT", "MCpT", {HistType::kTH1D, {axisPt}});
registry.add("MCTrue/MCTrig_hist", "", {HistType::kTHnSparseF, {{axisSample, axisVertex, axisPt}}});
registry.add("MCTrue/MCTrig_hist", "", {HistType::kTHnSparseF, {{axisSample, axisVertex, axisEtaTrigger}}});
registry.add("MCTrue/MCdeltaEta_deltaPhi_same", "", {HistType::kTH2D, {axisDeltaPhi, axisDeltaEta}}); // check to see the delta eta and delta phi distribution
registry.add("MCTrue/MCdeltaEta_deltaPhi_mixed", "", {HistType::kTH2D, {axisDeltaPhi, axisDeltaEta}});
}
Expand Down Expand Up @@ -535,7 +535,7 @@ struct EtaDihadron {
if (!getEfficiencyCorrection(triggerWeight, track1.eta(), track1.pt(), posZ))
continue;
if (system == SameEvent) {
registry.fill(HIST("Trig_hist"), fSampleIndex, posZ, track1.pt(), eventWeight * triggerWeight);
registry.fill(HIST("Trig_hist"), fSampleIndex, posZ, track1.eta(), eventWeight * triggerWeight);
}

for (auto const& track2 : tracks2) {
Expand Down Expand Up @@ -630,13 +630,13 @@ struct EtaDihadron {
if (!getEfficiencyCorrection(triggerWeight, track1.eta(), track1.pt(), posZ))
continue;

registry.fill(HIST("Nch_final_pt"), track1.pt());
registry.fill(HIST("Nch_final_eta"), track1.eta());

if (std::find(tracksSkipIndices.begin(), tracksSkipIndices.end(), track1.globalIndex()) != tracksSkipIndices.end()) {
registry.fill(HIST("Solo_tracks_trigger"), track1.pt());
registry.fill(HIST("Solo_tracks_trigger"), track1.eta());
continue; // Skip the track1 if it is alone in pt bin
Copy link

Copilot AI Jan 28, 2026

Choose a reason for hiding this comment

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

The comment says "Skip the track1 if it is alone in pt bin" but the code has been changed to fill histograms with eta values instead of pt values. However, the underlying logic in findBiasedTracks (line 838-875) still identifies tracks that are alone in their pT bins, not eta bins. This creates a semantic inconsistency - the function identifies solo tracks based on pT binning, but the histogram is now filled with eta values. Either the comment should be updated to clarify that tracks are identified as solo based on pT bins but their eta is recorded, or the entire feature should be reconsidered for consistency.

Copilot uses AI. Check for mistakes.
}
registry.fill(HIST("Trig_hist"), fSampleIndex, posZ, track1.pt(), eventWeight * triggerWeight);
registry.fill(HIST("Trig_hist"), fSampleIndex, posZ, track1.eta(), eventWeight * triggerWeight);

for (auto const& track2 : tracks2) {

Expand All @@ -651,7 +651,7 @@ struct EtaDihadron {
continue; // Without pt-differential correlations, skip if the trigger pt is less than the associate pt
if (!cfgSingleSoloPtTrack) { // avoid skipping the second track if we only want one
if (std::find(tracks2SkipIndices.begin(), tracks2SkipIndices.end(), track2.globalIndex()) != tracks2SkipIndices.end()) {
registry.fill(HIST("Solo_tracks_assoc"), track2.pt());
registry.fill(HIST("Solo_tracks_assoc"), track2.eta());
continue; // Skip the track2 if it is alone in pt bin
Copy link

Copilot AI Jan 28, 2026

Choose a reason for hiding this comment

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

The comment says "Skip the track2 if it is alone in pt bin" but the code has been changed to fill histograms with eta values instead of pt values. However, the underlying logic in findBiasedTracks (line 838-875) still identifies tracks that are alone in their pT bins, not eta bins. This creates a semantic inconsistency - the function identifies solo tracks based on pT binning, but the histogram is now filled with eta values. Either the comment should be updated to clarify that tracks are identified as solo based on pT bins but their eta is recorded, or the entire feature should be reconsidered for consistency.

Copilot uses AI. Check for mistakes.
}
}
Expand Down Expand Up @@ -703,7 +703,7 @@ struct EtaDihadron {
continue;

if (system == SameEvent && (doprocessMCSame || doprocessOntheflySame))
registry.fill(HIST("MCTrue/MCTrig_hist"), fSampleIndex, posZ, track1.pt(), eventWeight * triggerWeight);
registry.fill(HIST("MCTrue/MCTrig_hist"), fSampleIndex, posZ, track1.eta(), eventWeight * triggerWeight);

for (auto const& track2 : tracks2) {

Expand Down
Loading