Skip to content

Issue-525: To optimise the bnoc code

Zewen Chen requested to merge issue-525-bnoc into master

This MR is to optimise the bnoc code for HLT2 lines mentioned in issue #525 (closed).

The BnoC Hlt2 line rate in the master and this branch is at https://codimd.web.cern.ch/SRYI3YyNSwWMU_lG6jIF6Q?view.

  • The total BnoC Hlt2 rate is 8.69\pm0.29 kHz (in master) and 11.32\pm0.33 kHz (in this branch, before rm high rate lines), 4.18\pm0.20 kHz (in this branch, after rm high rate lines).
    • currently, the high rate lines are not removed. The total rate is about 11.32\pm0.33 kHz.
  • For BuTohhh/BcTohhh lines, the rate is not right, since we add the tight ghostprob and trackchi2ndof cuts on the particles again.

The discussion should be addressed: !1746 (comment 6435810).

In more details:

  • remove the cc for self-charged-conjugated lines
  • unify the basic builders and filters
  • remove the ghostprob and trackchi2ndof cuts for particles
  • check the control flow of all BnoC lines and properly define it, i.e. return line_alg -> return [composite_daughter(s), final_combination]

The changes in the bnoc code:

  1. These lines with rate around (greater than) 1kHz need to be optimized!! (https://codimd.web.cern.ch/SRYI3YyNSwWMU_lG6jIF6Q?view)
    • Hlt2BnoC_BdsToKpKmKpKm: 0.98±0.10 kHz
    • Hlt2BnoC_BdsToKpKmPipPim: 1.01±0.10 kHz
    • Hlt2BnoC_BdsToKpPimPipPim: 1.48±0.12 kHz
    • Hlt2BnoC_BuToKSKKPip_LL: 1.51±0.12 kHz
    • Hlt2BnoC_BuToKSKmPiPi_LL: 1.02±0.10 kHz
    • Hlt2BnoC_BuToKSKpPiPi_LL: 1.34±0.12 kHz
    • Hlt2BnoC_BuToKSPiPiPi_LL: 0.94±0.10 kHz
    • Hlt2BnoC_BdToPPbarKPi: 1.09±0.10 kHz
    • Hlt2BnoC_BdToPPbarPiPi: 1.14±0.11 kHz
  2. merge B_ppbarhh_builder.py into basic_builder.py and b_builder.py
    • builders for proton, kaon, pion -> basic_builder.py
    • B combiner -> b_builder.py
  3. change the name of B_ppbarhh.py to BdToppbarhh.py
  4. register BdToppbarhh lines in hlt2_bnoc.py
  5. use ParticleCombiner rather than ParticleContainersMerger for B combiner
    • remove ParticleContainersMerger in b_builder.py
    • remove the underscore at the beginning the name of B combiner in b_builder.py, e.g. _make_b2hhh -> make_b2hhh. (Since B combiners are called directly in the line definition now.)
    • change the descriptor in the line definition, e.g. descriptors=['B0 -> pi+ pi+ pi- pi-'] -> descriptor='B0 -> pi+ pi+ pi- pi-'
  6. comment out the ghostprob and trackchi2ndof cuts for particles before the stable data taking period, the relevant files are listed below
    • basic_builder.py
    • b_builder.py
    • BcTohhh.py
    • BuTohhh.py
    • bTohh.py
  7. add separate lines in b_builder.py and hlt2_bnoc.py for lines defined in different files, and modify the order of lines.
  8. remove BdTohh.py, details in !2102 (merged)
  9. remove BuTophh.py, it is merged into BuTohhh.py
  10. remove the cc for self-charged-conjugated lines
  11. optimize the control flow in the line definition
    • change return final_combination -> return [composite_daughter(s), final_combination] in the line definition
    • change return HltLine(name=name, prescale=prescale, algs=bnoc_prefilters() + [line_alg]) -> return HltLine(name=name, prescale=prescale, algs=bnoc_prefilters() + line_alg) in the hlt2_bnoc.py
  12. correct the descriptor in bbaryon_to_lightbaryon_h.py
    • descriptor='[Lambda_b0 -> Xi- D0]cc' -> descriptor='[Lambda_b0 -> Xi- K+]cc' for make_LbToXimKp_XimToLambdaDDPi
    • descriptor='[Xi_b- -> Omega- pi+ pi-]cc' -> descriptor='[Omega_b- -> Omega- pi+ pi-]cc' for make_OmbmToOmmPipPim_OmmToLambdaLLK
    • descriptor='[Xi_b- -> Omega- pi+ pi-]cc' -> descriptor='[Omega_b- -> Omega- pi+ pi-]cc' for make_OmbmToOmmPipPim_OmmToLambdaDDK
  13. move the Xib lines in bTohh module to bbaryon_to_lightbaryon_h module
  14. add make_BcToKSDD(LL)K with descriptor='[B_c+ -> KS0 K+]cc' in BuToKSh.py, and use them for Hlt2BnoC_BcToKsDD(LL)K lines in hlt2_bnoc.py
Edited by Zewen Chen

Merge request reports

Loading