Skip to content

[PWGHF] Improve tasks for B to JPsi analyses#16500

Open
fchinu wants to merge 4 commits into
AliceO2Group:masterfrom
fchinu:fix_btojpsi
Open

[PWGHF] Improve tasks for B to JPsi analyses#16500
fchinu wants to merge 4 commits into
AliceO2Group:masterfrom
fchinu:fix_btojpsi

Conversation

@fchinu
Copy link
Copy Markdown
Contributor

@fchinu fchinu commented Jun 2, 2026

I have spotted a few bugs that were preventing the signals to be observed, and added a configurable to use J/Psi PDG mass instead of the reconstructed one when computing the B meson mass. (tagging @fgrosa)

  • Fix selection on invariant mass of J/Psi and phi
  • Fix filling of Bs table

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 2, 2026

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

@github-actions github-actions Bot changed the title Improve tasks for B to JPsi analyses [PWGHF] Improve tasks for B to JPsi analyses Jun 2, 2026
@vkucera
Copy link
Copy Markdown
Collaborator

vkucera commented Jun 2, 2026

Hi @fchinu , can you please add brief descriptions of the bugs you're fixing in this PR?

Comment thread PWGHF/Core/HfHelper.h Outdated
Comment on lines +705 to +713
} else if (useJpsiPdgMass && !usePhiPdgMass) {
return RecoDecay::m(std::array{RecoDecay::pVec(pVecMuPos, pVecMuNeg), pVecKaPos, pVecKaNeg},
std::array{o2::constants::physics::MassJPsi, o2::constants::physics::MassKPlus, o2::constants::physics::MassKPlus});
} else if (!useJpsiPdgMass && usePhiPdgMass) {
return RecoDecay::m(std::array{pVecMuPos, pVecMuNeg, RecoDecay::pVec(pVecKaPos, pVecKaNeg)},
std::array{o2::constants::physics::MassMuon, o2::constants::physics::MassMuon, o2::constants::physics::MassPhi});
} else {
return RecoDecay::m(std::array{pVecMuPos, pVecMuNeg, pVecKaPos, pVecKaNeg},
std::array{o2::constants::physics::MassMuon, o2::constants::physics::MassMuon, o2::constants::physics::MassKPlus, o2::constants::physics::MassKPlus});
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.

The else statements seem redundant here.

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.

It seems you only removed the last else while the other redundant ones are still there.

Comment thread PWGHF/Core/HfHelper.h Outdated
Comment on lines +940 to +942
std::array<float, 3> const pVecMu0 = {candBp.pxProng0(), candBp.pyProng0(), candBp.pzProng0()};
std::array<float, 3> const pVecMu1 = {candBp.pxProng1(), candBp.pyProng1(), candBp.pzProng1()};
std::array<float, 3> const pVecKa = {candBp.pxProng2(), candBp.pyProng2(), candBp.pzProng2()};
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.

<float, 3> seems redundant here.

Copy link
Copy Markdown
Collaborator

@vkucera vkucera Jun 3, 2026

Choose a reason for hiding this comment

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

You can actually also remove the = parts, as you did in invMassBplusToJpsiK.

Comment thread PWGHF/Core/HfHelper.h
Comment thread PWGHF/Core/HfHelper.h Outdated
Comment thread PWGHF/D2H/Tasks/taskBplusToJpsiKReduced.cxx Outdated
Comment thread PWGHF/D2H/Tasks/taskBsToJpsiPhiReduced.cxx Outdated
@vkucera
Copy link
Copy Markdown
Collaborator

vkucera commented Jun 2, 2026

It seems you could profit from pVectorProngX columns in the candidate table.

@alibuild
Copy link
Copy Markdown
Collaborator

alibuild commented Jun 2, 2026

Error while checking build/O2Physics/o2 for e7295f8 at 2026-06-03 05:55:

## sw/BUILD/O2Physics-latest/log
2026-06-03T05:36:16.685+0200 [50:140552595017344] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.685+0200 [50:140552595017344] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:36:47.064+0200 [50:140552595017344] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv6:%5B::1%5D:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.682+0200 [48:140388428050048] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.682+0200 [48:140388428050048] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:36:55.730+0200 [48:140388428050048] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.741+0200 [57:139772198473344] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.741+0200 [57:139772198473344] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:36:56.037+0200 [57:139772198473344] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:34.841+0200 [702:140060974345856] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:34.842+0200 [702:140060974345856] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:36:59.390+0200 [702:140060974345856] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.707+0200 [51:139903116406400] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.707+0200 [51:139903116406400] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:37:01.077+0200 [51:139903116406400] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv6:%5B::1%5D:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.862+0200 [71:140079908159104] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.862+0200 [71:140079908159104] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:37:15.044+0200 [71:140079908159104] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:17.058+0200 [67:140391890443904] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:17.058+0200 [67:140391890443904] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:37:16.382+0200 [67:140391890443904] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv6:%5B::1%5D:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:17.056+0200 [70:139667783605888] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:17.056+0200 [70:139667783605888] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:37:16.911+0200 [70:139667783605888] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.730+0200 [64:140705247755904] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.730+0200 [64:140705247755904] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:37:19.579+0200 [64:140705247755904] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv6:%5B::1%5D:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:37:02.665+0200 [852:139771090419328] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:37:02.665+0200 [852:139771090419328] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:37:20.469+0200 [852:139771090419328] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv6:%5B::1%5D:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.922+0200 [65:139805183389312] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.922+0200 [65:139805183389312] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:37:24.242+0200 [65:139805183389312] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv6:%5B::1%5D:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:58.744+0200 [789:140350547271296] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:58.745+0200 [789:140350547271296] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:37:25.116+0200 [789:140350547271296] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv6:%5B::1%5D:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:17.073+0200 [69:140681014435456] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:17.073+0200 [69:140681014435456] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:37:26.199+0200 [69:140681014435456] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv6:%5B::1%5D:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:17.055+0200 [68:140102490807936] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:17.055+0200 [68:140102490807936] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:37:29.774+0200 [68:140102490807936] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv6:%5B::1%5D:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.869+0200 [66:139946246233728] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:36:16.870+0200 [66:139946246233728] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:37:30.743+0200 [66:139946246233728] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:37:17.828+0200 [885:139964250877568] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "ActionCache.GetActionResult()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused]
2026-06-03T05:37:17.828+0200 [885:139964250877568] [executioncontext.cpp:544] [ERROR] Error while querying action cache at "http://localhost:8980": 14: failed to connect to all addresses; last error: UNKNOWN: ipv4:127.0.0.1:8980: Failed to connect to remote host: Connection refused
2026-06-03T05:37:33.751+0200 [885:139964250877568] [buildboxcommon_grpcretrier.cpp:177] [ERROR] Retry limit (0) exceeded for "FindMissingBlobs()", last gRPC error was [14: failed to connect to all addresses; last error: UNKNOWN: ipv6:%5B::1%5D:8980: Failed to connect to remote host: Connection refused]
[0 more errors; see full log]

Full log here.

@fchinu
Copy link
Copy Markdown
Contributor Author

fchinu commented Jun 3, 2026

Hi @vkucera thanks for the comments! I have implemented them, and updated the description following the commit messages.

@vkucera
Copy link
Copy Markdown
Collaborator

vkucera commented Jun 3, 2026

Thanks @fchinu . Please see my further suggestions.

@fchinu
Copy link
Copy Markdown
Contributor Author

fchinu commented Jun 3, 2026

Thanks @fchinu . Please see my further suggestions.

Done, thanks!

@vkucera
Copy link
Copy Markdown
Collaborator

vkucera commented Jun 3, 2026

Thanks @fchinu . Please see my further suggestions.

Done, thanks!

I don't see PWGHF/D2H/Tasks/taskBplusToJpsiKReduced.cxx updated.
Also the redundant else are still there.

@fchinu
Copy link
Copy Markdown
Contributor Author

fchinu commented Jun 3, 2026

Sorry, I changed the ones you pointed me to, now everything should be updated

@vkucera
Copy link
Copy Markdown
Collaborator

vkucera commented Jun 3, 2026

In invMassBsToJpsiPhi, you have this:

if (useJpsiPdgMass && usePhiPdgMass) {
  return RecoDecay::m(...);
} else if (useJpsiPdgMass && !usePhiPdgMass) {
  return RecoDecay::m(...);
} else if (!useJpsiPdgMass && usePhiPdgMass) {
  return RecoDecay::m(...);
}
return RecoDecay::m(...);

All the else are redundant.

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.

3 participants