Skip to content

[PWGHF] Add UPC process function and QA hists#13328

Merged
zhangbiao-phy merged 5 commits into
AliceO2Group:masterfrom
Rrantu:master
Oct 10, 2025
Merged

[PWGHF] Add UPC process function and QA hists#13328
zhangbiao-phy merged 5 commits into
AliceO2Group:masterfrom
Rrantu:master

Conversation

@Rrantu

@Rrantu Rrantu commented Oct 10, 2025

Copy link
Copy Markdown
Contributor

Implemented a new function to process UPC events and added corresponding QA histograms.

@github-actions github-actions Bot added the pwghf PWG-HF label Oct 10, 2025
@github-actions github-actions Bot changed the title Add UPC process function and QA hists [PWGHF] Add UPC process function and QA hists Oct 10, 2025
@github-actions

github-actions Bot commented Oct 10, 2025

Copy link
Copy Markdown

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

@zhangbiao-phy

Copy link
Copy Markdown
Collaborator

Hi @Rrantu, many thanks for the implementation! I see there is linter error but not related to your PR. So all looks good!

@zhangbiao-phy zhangbiao-phy enabled auto-merge (squash) October 10, 2025 10:36
}
}

template <bool fillMl, typename CollType, typename CandType, typename BCsType>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

If you call this function only once, with fillMl = true, why do you need this parameter? Or do you foresee in future cases when this function should be called with 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.

Hi @lubynets, indeed, maybe we can consider adding one process function without ML in the future

@zhangbiao-phy zhangbiao-phy merged commit 41d60bb into AliceO2Group:master Oct 10, 2025
13 of 14 checks passed

@vkucera vkucera 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 address my comments.

Comment on lines +931 to +943
GapType determineGapType(float FT0A, float FT0C, float ZNA, float ZNC)
{
constexpr float FT0AThreshold = 100.0;
constexpr float FT0CThreshold = 50.0;
constexpr float ZDCThreshold = 1.0;
if (FT0A < FT0AThreshold && FT0C > FT0CThreshold && ZNA < ZDCThreshold && ZNC > ZDCThreshold) {
return GapType::GapA;
}
if (FT0A > FT0AThreshold && FT0C < FT0CThreshold && ZNA > ZDCThreshold && ZNC < ZDCThreshold) {
return GapType::GapC;
}
return GapType::DoubleGap;
}

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.

Isn't this supposed to be done by the SG selector?

@zhangbiao-phy zhangbiao-phy Oct 10, 2025

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.

Hi @vkucera, yes, similar logic in the trueGap:

int trueGap(CC const& collision, const float fv0, const float ft0a, const float ft0c, const float zdc_cut)

But we can't use the UD collision table. So we define the function in our HF task now

Comment on lines +904 to +906
uint32_t rejectionMask{0}; // 32 bits, in case new ev. selections will be added
float centrality{-1.f};
rejectionMask = hfEvSel.getHfCollisionRejectionMaskWithUpc<true, CentralityEstimator::None, BCsType>(collision, centrality, ccdb, qaRegistry, bcs);

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.

Do not hard-code the types of values that you receive from functions. I removed these cases from HF some time ago. Where did you take this piece from?

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.

Hi @Rrantu, could you open a new PR to fix the comment from @vkucera and @lubynets? Thanks a lot!

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Sorry, I missed that point. I’ll update the code accordingly and submit a new PR.

lubynets added a commit to lubynets/O2Physics that referenced this pull request Oct 10, 2025
add const and const&

add author
ArkaprabhaSaha001 pushed a commit to ArkaprabhaSaha001/O2Physics that referenced this pull request Oct 21, 2025
ThePhDane pushed a commit to ThePhDane/O2Physics that referenced this pull request Nov 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pwghf PWG-HF

Development

Successfully merging this pull request may close these issues.

4 participants