Skip to content

[PWGHF] Refactor XiC0 and OmegaC0 QA workflows - #18728

Open
fcatalan92 wants to merge 37 commits into
AliceO2Group:masterfrom
fcatalan92:omegac_qa
Open

fcatalan92 wants to merge 37 commits into
AliceO2Group:masterfrom
fcatalan92:omegac_qa

Conversation

@fcatalan92

Copy link
Copy Markdown
Collaborator

This PR refactors the XiC0 and OmegaC0 QA workflows to use a common candidate data model for the different decay channels, following the pattern of the 2-prong and 3-prong workflows. It also aligns better the DCA and KFParticle reconstruction approaches, with KFParticle-specific quantities stored separately in a table joinable with the base one.

The PR also streamlines candidate building around a shared workflow for the DCA and KFParticle approaches, and updates the MC matching, selectors, ML responses, tree creators and analysis task to use the new schema.

The changes were tested locally for the OmegaC0 workflow.

@jinhyunni Please have a look, I did not test this for the XiC0, so if you can give it a try, it would be great!

@mtorresc15

@github-actions

Copy link
Copy Markdown

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

@github-actions github-actions Bot changed the title Refactor XiC0 and OmegaC0 QA workflows [PWGHF] Refactor XiC0 and OmegaC0 QA workflows Nov 13, 2026
@alibuild

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/o2 for 5d1e814 at 2026-11-13 13:25:

## sw/BUILD/O2-latest/log
2026-11-13T13:24:58.294+0100 [51806:139899076722304] [executioncontext.cpp:739] [ERROR] Failed to download output blob 4a1af663d2073f48fc5a80eb489846c0c864dbba02e1aebca3f41eab8cdd51ae: 13: Blob absent from sink after replication: Object not found
ninja: build stopped: subcommand failed.

Full log here.

@alibuild

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/staging for 5d1e814 at 2026-11-13 13:35:

## sw/BUILD/O2Physics-latest/log
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:333:78: error: 'HfSelToXiPiQa' is not a member of 'o2::aod'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:333:78: error: template argument 2 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:333:91: error: template argument 1 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:333:31: error: '<expression error>' in namespace 'o2::soa' does not name a type
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:334:102: error: 'HfSelToXiPiQa' is not a member of 'o2::aod'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:334:102: error: template argument 3 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:334:115: error: template argument 1 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:334:30: error: '<expression error>' in namespace 'o2::soa' does not name a type
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:335:84: error: 'HfSelToXiPiQa' is not a member of 'o2::aod'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:335:104: error: template argument 2 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:335:125: error: template argument 1 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:335:37: error: '<expression error>' in namespace 'o2::soa' does not name a type
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:336:108: error: 'HfSelToXiPiQa' is not a member of 'o2::aod'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:336:128: error: template argument 3 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:336:149: error: template argument 1 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:336:36: error: '<expression error>' in namespace 'o2::soa' does not name a type
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:337:35: error: 'MyCandTableXic0McDca' does not name a type
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:688:24: error: 'MyCandTableDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:706:24: error: 'MyCandTableDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:724:32: error: 'MyCandTableDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:742:32: error: 'MyCandTableDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:760:37: error: 'MyCandTableDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:787:22: error: 'MyCandTableKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:805:30: error: 'MyCandTableKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:823:30: error: 'MyCandTableKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:841:35: error: 'MyCandTableKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:869:26: error: 'MyCandTableXic0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:895:29: error: 'MyCandTableOmegac0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:921:26: error: 'MyCandTableXic0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:947:34: error: 'MyCandTableXic0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:973:34: error: 'MyCandTableXic0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:999:39: error: 'MyCandTableXic0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:1025:29: error: 'MyCandTableOmegac0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:1062:24: error: 'MyCandTableXic0McKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:1088:32: error: 'MyCandTableXic0McKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:1114:32: error: 'MyCandTableXic0McKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:1140:37: error: 'MyCandTableXic0McKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:352:40: error: 'o2::aod::hf_sel_candidate_to_xi_pi_qa' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:697:41: error: request for member 'size' in 'candidates', which is of non-class type 'const int'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:698:34: error: 'begin' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:698:34: error: 'end' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:715:41: error: request for member 'size' in 'candidates', which is of non-class type 'const int'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:716:34: error: 'begin' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:716:34: error: 'end' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:733:41: error: request for member 'size' in 'candidates', which is of non-class type 'const int'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:734:34: error: 'begin' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:734:34: error: 'end' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:751:41: error: request for member 'size' in 'candidates', which is of non-class type 'const int'
[0 more errors; see full log]

Full log here.

@alibuild

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/code-check for 5d1e814 at 2026-11-13 13:36:

## sw/BUILD/O2Physics-latest/log
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:333:78: error: 'HfSelToXiPiQa' is not a member of 'o2::aod'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:333:78: error: template argument 2 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:333:91: error: template argument 1 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:333:31: error: '<expression error>' in namespace 'o2::soa' does not name a type
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:334:102: error: 'HfSelToXiPiQa' is not a member of 'o2::aod'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:334:102: error: template argument 3 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:334:115: error: template argument 1 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:334:30: error: '<expression error>' in namespace 'o2::soa' does not name a type
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:335:84: error: 'HfSelToXiPiQa' is not a member of 'o2::aod'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:335:104: error: template argument 2 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:335:125: error: template argument 1 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:335:37: error: '<expression error>' in namespace 'o2::soa' does not name a type
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:336:108: error: 'HfSelToXiPiQa' is not a member of 'o2::aod'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:336:128: error: template argument 3 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:336:149: error: template argument 1 is invalid
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:336:36: error: '<expression error>' in namespace 'o2::soa' does not name a type
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:337:35: error: 'MyCandTableXic0McDca' does not name a type
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:688:24: error: 'MyCandTableDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:706:24: error: 'MyCandTableDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:724:32: error: 'MyCandTableDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:742:32: error: 'MyCandTableDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:760:37: error: 'MyCandTableDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:787:22: error: 'MyCandTableKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:805:30: error: 'MyCandTableKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:823:30: error: 'MyCandTableKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:841:35: error: 'MyCandTableKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:869:26: error: 'MyCandTableXic0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:895:29: error: 'MyCandTableOmegac0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:921:26: error: 'MyCandTableXic0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:947:34: error: 'MyCandTableXic0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:973:34: error: 'MyCandTableXic0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:999:39: error: 'MyCandTableXic0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:1025:29: error: 'MyCandTableOmegac0McDca' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:1062:24: error: 'MyCandTableXic0McKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:1088:32: error: 'MyCandTableXic0McKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:1114:32: error: 'MyCandTableXic0McKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:1140:37: error: 'MyCandTableXic0McKf' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:352:40: error: 'o2::aod::hf_sel_candidate_to_xi_pi_qa' has not been declared
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:697:41: error: request for member 'size' in 'candidates', which is of non-class type 'const int'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:698:34: error: 'begin' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:698:34: error: 'end' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:715:41: error: request for member 'size' in 'candidates', which is of non-class type 'const int'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:716:34: error: 'begin' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:716:34: error: 'end' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:733:41: error: request for member 'size' in 'candidates', which is of non-class type 'const int'
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:734:34: error: 'begin' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:734:34: error: 'end' was not declared in this scope
/sw/SOURCES/O2Physics/slc9_x86-64-slc9_x86-64/0/PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:751:41: error: request for member 'size' in 'candidates', which is of non-class type 'const int'
[0 more errors; see full log]

Full log here.

@alibuild

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/code-check for 53cbff8 at 2026-11-13 16:18:

## sw/BUILD/O2Physics-code-check-latest/log
--
========== List of issues found ==========
++ echo 'To reproduce the results below locally, run: '\''aliBuild build O2Physics-code-check -e ALIBUILD_BASE_HASH=upstream/master'\''.'
To reproduce the results below locally, run: 'aliBuild build O2Physics-code-check -e ALIBUILD_BASE_HASH=upstream/master'.
++ echo 'To apply all automatic fixes, add the '\''-e O2PHYSICS_CHECKER_FIX=1'\'' option.'
To apply all automatic fixes, add the '-e O2PHYSICS_CHECKER_FIX=1' option.
++ echo 'See the documentation for more details at: <https://aliceo2group.github.io/analysis-framework/docs/tools/#running-with-o2physics-code-check>.'
See the documentation for more details at: <https://aliceo2group.github.io/analysis-framework/docs/tools/#running-with-o2physics-code-check>.
++ echo 'Found 14 errors and 50 warnings.'
Found 14 errors and 50 warnings.
++ [[ 14 -gt 0 ]]
++ cat /sw/BUILD/884ea248d0f5a92937fce8bd0393ea7ae1e49c52/O2Physics-code-check/errors.txt
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:28:1: error: included header map is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:29:1: error: included header string is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:30:1: error: included header vector is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:26:1: error: included header map is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:27:1: error: included header string is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:28:1: error: included header vector is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/D2H/Tasks/taskOmegac0ToOmegaPiQa.cxx:23:1: error: included header TrackIndexSkimmingTables.h is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/D2H/Tasks/taskOmegac0ToOmegaPiQa.cxx:43:1: error: included header Rtypes.h is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/TableProducer/candidateSelectorToXiPiQa.cxx:47:1: error: included header array is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/TableProducer/candidateSelectorToXiPiQa.cxx:542:57: error: no header providing "o2::aod::hf_cand_casc_lf::DecayType2Prong" is directly included [misc-include-cleaner,-warnings-as-errors]
PWGHF/TableProducer/treeCreatorOmegac0ToOmegaPiQa.cxx:25:1: error: included header TrackIndexSkimmingTables.h is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/TableProducer/treeCreatorOmegac0ToOmegaPiQa.cxx:41:1: error: included header Rtypes.h is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/TableProducer/treeCreatorToXiPiQa.cxx:42:1: error: included header Rtypes.h is not used directly [misc-include-cleaner,-warnings-as-errors]
Tools/ML/model.h:25:10: error: 'onnxruntime_cxx_api.h' file not found [clang-diagnostic-error]
++ [[ 50 -gt 0 ]]
++ cat /sw/BUILD/884ea248d0f5a92937fce8bd0393ea7ae1e49c52/O2Physics-code-check/warnings.txt
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:41:9: warning: function-like macro 'CHECK_AND_FILL_VEC_OMEGAC0' used; consider a 'constexpr' template function [cppcoreguidelines-macro-usage]
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:51:9: warning: function-like macro 'CHECK_AND_FILL_VEC_OMEGAC0_FULL' used; consider a 'constexpr' template function [cppcoreguidelines-macro-usage]
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:53:32: warning: macro argument should be enclosed in parentheses [bugprone-macro-parentheses]
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:59:9: warning: function-like macro 'CHECK_AND_FILL_VEC_OMEGAC0_HFHELPER' used; consider a 'constexpr' template function [cppcoreguidelines-macro-usage]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:39:9: warning: function-like macro 'CHECK_AND_FILL_VEC_XIC0' used; consider a 'constexpr' template function [cppcoreguidelines-macro-usage]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:47:9: warning: function-like macro 'CHECK_AND_FILL_VEC_XIC0_FULL' used; consider a 'constexpr' template function [cppcoreguidelines-macro-usage]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:49:32: warning: macro argument should be enclosed in parentheses [bugprone-macro-parentheses]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:54:9: warning: function-like macro 'CHECK_AND_FILL_VEC_XIC0_HFHELPER' used; consider a 'constexpr' template function [cppcoreguidelines-macro-usage]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:457:7: warning: do not use 'else' after 'return' [readability-else-after-return]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:472:15: warning: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:508:5: warning: uninitialized record type: 'pVecCasc' [cppcoreguidelines-pro-type-member-init]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:508:5: warning: uninitialized record type: 'pVecCharmBach' [cppcoreguidelines-pro-type-member-init]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:524:11: warning: variable 'phi' is not initialized [cppcoreguidelines-init-variables]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:524:16: warning: variable 'theta' is not initialized [cppcoreguidelines-init-variables]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:649:7: warning: do not use 'else' after 'return' [readability-else-after-return]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:687:48: warning: redundant boolean literal in ternary expression result [readability-simplify-boolean-expr]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:696:11: warning: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:700:22: warning: do not implicitly decay an array into a pointer; consider using gsl::array_view or an explicit cast instead [cppcoreguidelines-pro-bounds-array-to-pointer-decay]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:707:11: warning: variable 'massLam' is not initialized [cppcoreguidelines-init-variables]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:707:20: warning: variable 'sigMassLam' is not initialized [cppcoreguidelines-init-variables]
[0 more errors; see full log]

Full log here.

@alibuild

Copy link
Copy Markdown
Collaborator

Error while checking build/O2Physics/code-check for 69c46a2 at 2026-11-13 18:49:

## sw/BUILD/O2Physics-code-check-latest/log
--
========== List of issues found ==========
++ echo 'To reproduce the results below locally, run: '\''aliBuild build O2Physics-code-check -e ALIBUILD_BASE_HASH=upstream/master'\''.'
To reproduce the results below locally, run: 'aliBuild build O2Physics-code-check -e ALIBUILD_BASE_HASH=upstream/master'.
++ echo 'To apply all automatic fixes, add the '\''-e O2PHYSICS_CHECKER_FIX=1'\'' option.'
To apply all automatic fixes, add the '-e O2PHYSICS_CHECKER_FIX=1' option.
++ echo 'See the documentation for more details at: <https://aliceo2group.github.io/analysis-framework/docs/tools/#running-with-o2physics-code-check>.'
See the documentation for more details at: <https://aliceo2group.github.io/analysis-framework/docs/tools/#running-with-o2physics-code-check>.
++ echo 'Found 7 errors and 22 warnings.'
Found 7 errors and 22 warnings.
++ [[ 7 -gt 0 ]]
++ cat /sw/BUILD/011394780f1bdddca64b198d143c7dfe2311ce94/O2Physics-code-check/errors.txt
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:28:1: error: included header map is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:29:1: error: included header string is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:30:1: error: included header vector is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:26:1: error: included header map is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:27:1: error: included header string is not used directly [misc-include-cleaner,-warnings-as-errors]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:28:1: error: included header vector is not used directly [misc-include-cleaner,-warnings-as-errors]
Tools/ML/model.h:25:10: error: 'onnxruntime_cxx_api.h' file not found [clang-diagnostic-error]
++ [[ 22 -gt 0 ]]
++ cat /sw/BUILD/011394780f1bdddca64b198d143c7dfe2311ce94/O2Physics-code-check/warnings.txt
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:41:9: warning: function-like macro 'CHECK_AND_FILL_VEC_OMEGAC0' used; consider a 'constexpr' template function [cppcoreguidelines-macro-usage]
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:51:9: warning: function-like macro 'CHECK_AND_FILL_VEC_OMEGAC0_FULL' used; consider a 'constexpr' template function [cppcoreguidelines-macro-usage]
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:53:32: warning: macro argument should be enclosed in parentheses [bugprone-macro-parentheses]
PWGHF/Core/HfMlResponseOmegacToOmegaPiQa.h:59:9: warning: function-like macro 'CHECK_AND_FILL_VEC_OMEGAC0_HFHELPER' used; consider a 'constexpr' template function [cppcoreguidelines-macro-usage]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:39:9: warning: function-like macro 'CHECK_AND_FILL_VEC_XIC0' used; consider a 'constexpr' template function [cppcoreguidelines-macro-usage]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:47:9: warning: function-like macro 'CHECK_AND_FILL_VEC_XIC0_FULL' used; consider a 'constexpr' template function [cppcoreguidelines-macro-usage]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:49:32: warning: macro argument should be enclosed in parentheses [bugprone-macro-parentheses]
PWGHF/Core/HfMlResponseXic0ToXiPiQa.h:54:9: warning: function-like macro 'CHECK_AND_FILL_VEC_XIC0_HFHELPER' used; consider a 'constexpr' template function [cppcoreguidelines-macro-usage]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:696:11: warning: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:700:22: warning: do not implicitly decay an array into a pointer; consider using gsl::array_view or an explicit cast instead [cppcoreguidelines-pro-bounds-array-to-pointer-decay]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:727:11: warning: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:728:11: warning: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:733:24: warning: do not implicitly decay an array into a pointer; consider using gsl::array_view or an explicit cast instead [cppcoreguidelines-pro-bounds-array-to-pointer-decay]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:757:29: warning: do not implicitly decay an array into a pointer; consider using gsl::array_view or an explicit cast instead [cppcoreguidelines-pro-bounds-array-to-pointer-decay]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:776:11: warning: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:781:31: warning: do not implicitly decay an array into a pointer; consider using gsl::array_view or an explicit cast instead [cppcoreguidelines-pro-bounds-array-to-pointer-decay]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:871:5: warning: do not declare C-style arrays, use 'std::array' instead [modernize-avoid-c-arrays]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:872:34: warning: do not implicitly decay an array into a pointer; consider using gsl::array_view or an explicit cast instead [cppcoreguidelines-pro-bounds-array-to-pointer-decay]
PWGHF/TableProducer/candidateCreatorXic0Omegac0Qa.cxx:1044:2: warning: preprocessor condition is always 'false', consider removing both the condition and its contents [readability-avoid-unconditional-preprocessor-if]
PWGHF/TableProducer/candidateSelectorOmegac0ToOmegaPiQa.cxx:80:52: warning: do not implicitly decay an array into a pointer; consider using gsl::array_view or an explicit cast instead [cppcoreguidelines-pro-bounds-array-to-pointer-decay]
PWGHF/TableProducer/candidateSelectorOmegac0ToOmegaPiQa.cxx:86:56: warning: do not implicitly decay an array into a pointer; consider using gsl::array_view or an explicit cast instead [cppcoreguidelines-pro-bounds-array-to-pointer-decay]
PWGHF/TableProducer/candidateSelectorOmegac0ToOmegaPiQa.cxx:645:14: warning: redundant boolean literal in conditional return statement [readability-simplify-boolean-expr]
++ [[ 7 -gt 0 ]]
++ exit 1
--

Full log here.

@lubynets lubynets left a comment

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.

Hi Fabio, I had a look at the candidateCreatorXic0Omegac0Qa.cxx, in particular at the KF-related part, and left some comments, which I hope you will find useful.

const KFParticle* v0Daughters[2] = {&kfPos, &kfNeg};
KFParticle kfV0;
kfV0.SetConstructMethod(configs.kfConstructMethod);
try {

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.

The KFParticle code does not throw exceptions so the try-catch block is not needed (?)
P.S. I know that it is present in some different place of O2Physics, namely in the XicToXiPiPi creator.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

This try-catch block addresses any runtime error, there is no need for the KFParticle to explicitly throw. It was added time ago to take care of some rare crashes for the DCA fitter. I would keep it since it does not hurt.

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.

Yes, the DCAFitter explicitly throws exceptions while the KFParticle does not. It is written in a very low-level style (for the sake of speed) and in case of semantic error instead of exception it will simply crash, and the try-catch block won't handle it.
Of course, it does not hurt too much, but imo clutters a bit the code and misinforms the user.
P.S. You say "addresses any runtime error", but do you mean the std::runtime_error object or the error which happens during execution time?

Configurable<bool> kfDoDCAFitterPreMinimCascFromLF{"kfDoDCAFitterPreMinimCascFromLF", false, "KF : do DCAFitter pre-optimization before KF fit to include material correction for Xi"};
} LFConfigs;
Configurable<bool> kfTuneForOmega{"kfTuneForOmega", false, "if enabled, take main cascade properties from omega fit instread of Xi fit(=default)"};
Configurable<int> kfConstructMethod{"kfConstructMethod", 2, "2 : Daughter particle masses stay fixed in construction process"};

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.

Alternative value - 0, when daughters' masses do not stay fixed. Maybe it makes sense to provide a reference to the KF code? https://github.com/alisw/KFParticle/blob/a00323cd7b022430abcb3c43f18188b291b0c803/KFParticle/KFParticleBase.cxx#L625
Otherwise not clear for the user, why the method is"2" and what are the alternatives.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Done, probably makes sense to hardcode this parameter to 2 in the code and not letting it configurable

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.

I think it does not hurt too much to have it as a configurable, with the default value 2 (?)
In principle it can be replaced with boolean configurable, allowing the user to choose between true and false instead of 0 and 2, see

Configurable<bool> kfConstructWithEnergyFitMc{"kfConstructWithEnergyFitMc", true, "for details see https://github.com/alisw/KFParticle/blob/a00323cd7b022430abcb3c43f18188b291b0c803/KFParticle/KFParticleBase.cxx#L625"};

auto posTrack = lfTracks.rawIteratorAt(v0AodElement.posTrackId());
auto negTrack = lfTracks.rawIteratorAt(v0AodElement.negTrackId());
auto bachTrack = lfTracks.rawIteratorAt(cascAodElement.bachelorId());
//------------------------------Create cascade track------------------------------

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.

There is a room for code repetition reduction.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Where?

@lubynets lubynets Nov 17, 2026 •

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.

Sorry, I did not highlight the LOC properly :)
I meant to replace these lines with something like:

    if (bachTrack.sign() == 0) {
      return;
    }
    const auto bachTrackSign = bachTrack.sign() < 0 ? -1 : 1;
    o2::track::TrackParCov trackCasc = o2::track::TrackParCov(straHelper.cascade.cascadePosition, straHelper.cascade.cascadeMomentum, covCasc, bachTrackSign, true);

@fcatalan92 fcatalan92 left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Hi @lubynets, thanks for your comments! I addressed most of them and added some replies for the rest.

const KFParticle* v0Daughters[2] = {&kfPos, &kfNeg};
KFParticle kfV0;
kfV0.SetConstructMethod(configs.kfConstructMethod);
try {

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

This try-catch block addresses any runtime error, there is no need for the KFParticle to explicitly throw. It was added time ago to take care of some rare crashes for the DCA fitter. I would keep it since it does not hurt.

Configurable<bool> kfDoDCAFitterPreMinimCascFromLF{"kfDoDCAFitterPreMinimCascFromLF", false, "KF : do DCAFitter pre-optimization before KF fit to include material correction for Xi"};
} LFConfigs;
Configurable<bool> kfTuneForOmega{"kfTuneForOmega", false, "if enabled, take main cascade properties from omega fit instread of Xi fit(=default)"};
Configurable<int> kfConstructMethod{"kfConstructMethod", 2, "2 : Daughter particle masses stay fixed in construction process"};

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Done, probably makes sense to hardcode this parameter to 2 in the code and not letting it configurable

auto posTrack = lfTracks.rawIteratorAt(v0AodElement.posTrackId());
auto negTrack = lfTracks.rawIteratorAt(v0AodElement.negTrackId());
auto bachTrack = lfTracks.rawIteratorAt(cascAodElement.bachelorId());
//------------------------------Create cascade track------------------------------

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Where?

@lubynets

Copy link
Copy Markdown
Contributor

Hi @lubynets, thanks for your comments! I addressed most of them and added some replies for the rest.

Hi @fcatalan92, thanks for the feedback and addressing the comments! I commented something in reply.

hf_cand::ImpactParameterXY<collision::PosX, collision::PosY, collision::PosZ, hf_cand::XSecondaryVertex, hf_cand::YSecondaryVertex, hf_cand::ZSecondaryVertex, hf_cand_2prong::Px, hf_cand_2prong::Py, hf_cand_2prong::Pz>,
hf_cand::Cpa<collision::PosX, collision::PosY, collision::PosZ, hf_cand::XSecondaryVertex, hf_cand::YSecondaryVertex, hf_cand::ZSecondaryVertex, hf_cand_2prong::Px, hf_cand_2prong::Py, hf_cand_2prong::Pz>,
hf_cand::CpaXY<collision::PosX, collision::PosY, hf_cand::XSecondaryVertex, hf_cand::YSecondaryVertex, hf_cand_2prong::Px, hf_cand_2prong::Py>,
// TODO: investigate if these decay lenghts should not be computed w.r.t. the primary vertex

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.

I have a question regarding this point.
In the previous candidateCreatorXic0Omegac0.cxx, it seems that decay length was calculated respect to parent vertex, not from primary vertex.
Should this be investigated further?

@fcatalan92 fcatalan92 Nov 18, 2026 •

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Hi @jinhyunni, in the candidateCreatorXic0Omegac0.cxx both definitions were used: decay lengths were calculated to the parent vertex, while normalised decay lengths were calculated using the primary vertex. So the definitions were not consistent between the variables, and it was misleading.
Usually in HF we define decay lengths from the primary vertex. Also the other option is viable and could be useful providing slightly different information, even if, in principle, these decay lengths should be less precise due to the larger uncertainties on the position of charm-baryon, cascade, and V0 vertices compared to the primary one.
The TODO is a reminder about this change, in particular it is relevant if the decay lengths of the Lambda and Cascades are used in the selections further down in the workflow. If this is not the case, there is no impact.

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