18 def egammaCluster (egamma, allSamplings = False, fwdEVars = False):
19 ClusterAssoc = SimpleAssociation \
22 ClusterAssoc.defineBlock \
27 ClusterAssoc.defineBlock (
33 ClusterAssoc.defineBlock \
38 ClusterAssoc.defineBlock \
39 (2,
'Position0InCalo',
43 FillSeedCoordinates=
True)
44 ClusterAssoc.defineBlock \
50 ClusterAssoc.defineBlock \
54 EmHadEnergies =
False,
55 SamplingEnergies =
True)
57 ClusterAssoc.defineBlock (
60 Vars = [
'firstEdens = FIRST_ENG_DENS < float: 0',
61 'cellmaxfrac = ENG_FRAC_MAX < float: 0',
62 'longitudinal = LONGITUDINAL < float: 0',
63 'secondlambda = SECOND_LAMBDA < float: 0',
64 'lateral = LATERAL < float: 0',
65 'secondR = SECOND_R < float: 0',
66 'centerlambda = CENTER_LAMBDA < float: 0',
71 Cells = ContainedVectorMultiAssociation (
77 blockname =
'ClusterCells')
78 Cells.defineBlock (4,
'CellKinematics',
80 WriteE =
True, WriteM =
False)
81 Cells.defineBlock (4,
'CellRawPosition',
84 Cells.defineBlock (5,
'CellDetail1',
91 SaveBadCellStatus=
False,
93 SavePositionInfo=
False,
96 Cells.defineBlock (6,
'CellDetail2',
99 SaveCellQuality=
False,
103 SaveBadCellStatus=
True,
105 SavePositionInfo=
True,
107 def _cellDetail2Hook (c, flags, acc, *args, **kw):
108 from CaloBadChannelTool.CaloBadChanToolConfig
import CaloBadChanToolCfg
109 c.BadChannelTool = acc.popToolsAndMerge (CaloBadChanToolCfg (flags))
111 cellDetail2.defineHook (_cellDetail2Hook)