MCTupleTool allows list of single-precision-float, bool and int branches
FYI @masmith @erodrigu @mramospe
See discussion at #4 (closed).
See related (but no interdependency) merge request Phys!878 (merged), which implements the equivalent functionality for DecayTreeTuple
Tested with
from DecayTreeTuple.Configuration import *
from Configurables import DaVinci
DaVinci().TupleFile = 'DVntuple.root'
DaVinci().Simulation = True
DaVinci().DataType = '2016'
DaVinci().EvtMax = 1000
DaVinci().PrintFreq = 100
from GaudiConf import IOHelper
IOHelper().inputFiles(['root://eoslhcb.cern.ch//eos/lhcb/grid/prod/lhcb/MC/2016/ALLSTREAMS.DST/00065692/0000/00065692_00000548_7.AllStreams.dst'])
from Configurables import MCDecayTreeTuple
FSR_electrons = ' {e+} {e-} {e+} {e-} '
mcdttW = MCDecayTreeTuple("mcdttW")
mcdttW.ToolList = []
mcdttW.Decay = '[W+ => ^mu+ ^nu_mu' + FSR_electrons + ']CC'
mcdttW.addBranches({
"W": '^[W+ => mu+ nu_mu' + FSR_electrons + ']CC',
"mu": '[W+ => ^mu+ nu_mu' + FSR_electrons + ']CC',
"nu": '[W+ => mu+ ^nu_mu' + FSR_electrons + ']CC'
})
atool = mcdttW.W.addTupleTool("LoKi::Hybrid::MCTupleTool/LoKi_MC")
atool.IntVariables = {"ID": "MCID"}
atool.FloatVariables = {
"ETA": "MCETA",
"PT": "MCPT",
"PHI": "MCPHI",
}
DaVinci().UserAlgorithms.append(mcdttW)
Merge request reports
Activity
added Tuples backport run2 labels
mentioned in merge request Phys!878 (merged)
added 1 commit
- a7bad357 - Put the new bool,int,float structures in the member init list
mentioned in issue #4 (closed)
assigned to @masmith
added 1 commit
- b8342c75 - Add initVariablesHelper to reduce boiler plate
@masmith I think this is ready too. There is no interdependency with Phys!878 (merged), but the code changes are very similar.
added all-slots label
- [2021-02-27 00:54] Validation started with lhcb-run2-gaudi-head#75
- [2021-02-27 00:58] Validation started with lhcb-run2-patches-dev4#615
- [2021-02-27 01:01] Validation started with lhcb-run2-patches#914
- [2021-02-27 01:34] Validation started with lhcb-run2-gaudi-head#75
- [2021-02-27 01:50] Validation started with lhcb-run2-gaudi-head#75
- [2021-02-28 00:20] Validation started with lhcb-run2-patches-dev4#616
- [2021-03-01 00:09] Validation started with lhcb-run2-patches-dev4#617
- [2021-03-02 00:34] Validation started with lhcb-run2-patches-dev4#618
- [2021-03-03 00:47] Validation started with lhcb-run2-gaudi-head#76
- [2021-03-03 00:49] Validation started with lhcb-run2-patches#915
- [2021-03-03 00:49] Validation started with lhcb-run2-patches-dev4#619
Edited by Software for LHCbMany thanks @mvesteri
mentioned in commit ca0c7b76
added enhancement label
added highlight label