Skip to content

Conversation

@fgrosa
Copy link
Collaborator

@fgrosa fgrosa commented Dec 6, 2025

@Mingze129 this PR adds the possibility to compute the EP resolution in the charm polarisation task (separate process function)

@github-actions github-actions bot added the pwghf PWG-HF label Dec 6, 2025
@github-actions github-actions bot changed the title Add process function for EP resolution in charm polarisation task [PWGHF] Add process function for EP resolution in charm polarisation task Dec 6, 2025
@github-actions
Copy link

github-actions bot commented Dec 6, 2025

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

@fgrosa fgrosa enabled auto-merge (squash) December 6, 2025 18:11
Copy link
Collaborator

@alibuild alibuild left a comment

Choose a reason for hiding this comment

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

Auto-approving on behalf of @fgrosa.

@fgrosa fgrosa merged commit 90ab5fe into AliceO2Group:master Dec 6, 2025
13 checks passed
Comment on lines +267 to +271
if constexpr (std::is_same_v<T, o2::framework::OutputObj<ZorroSummary>>) {
zorroSummary.setObject(zorro.getZorroSummary());
} else {
LOGP(fatal, "No o2::framework::OutputObj<ZorroSummary> provided to HF event selection object in your task, add it if you want to get the normalisation from Zorro.");
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

What is the point?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

To avoid having the ZorroSummary in the output of tasks that do not need it

Copy link
Collaborator

@vkucera vkucera Dec 7, 2025

Choose a reason for hiding this comment

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

I don't see how this checks for the need of the OutputObj<ZorroSummary> member. From what I see, it just throws a fatal when an object of a wrong type is passed to init. If an unneeded OutputObj<ZorroSummary> member is passed, the condition evaluates to true.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Hi, sorry to jump in, IMHO a cleaner solution would be to overload the init function with another one of the form void init(o2::framework::HistogramRegistry& registry) where the Zorro functionality is removed. I did not do it last time since all the tasks affected by the changes could in principle run on triggered data.

Copy link
Collaborator

Choose a reason for hiding this comment

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

I don't think another function is needed, if the Zorro object is taken as a pointer which is nullptr by default.

Copy link
Collaborator

Choose a reason for hiding this comment

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

But @fgrosa said he wants to avoid unneeded Zorro output in the tasks. I don't see how any of these changes achieve that.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Both passing a pointer or overload the init function would work in my opinion. The fatal is in my opinion needed because if the OutputObj<ZorroSummary> is not passed, but the configurables are set to require a trigger mask, it would break otherwise.

Copy link
Collaborator

Choose a reason for hiding this comment

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

See #14189

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