3 from METReconstruction.METAssocCfg
import AssocConfig, METAssocConfig,getMETAssocAlg
4 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
10 from TrkConfig.AtlasExtrapolatorConfig
import AtlasExtrapolatorCfg
12 extrapCfg.popPrivateTools()
13 components.merge(extrapCfg)
17 if configFlags.MET.UseTracks:
18 modConstKey=
"OriginCorr"
20 'LCOriginCorrClusters':
'LCOriginTopoClusters',
21 'EMOriginCorrClusters':
'EMOriginTopoClusters'
24 if jetType ==
"AntiKt4LCTopo":
25 associators = [AssocConfig(
'LCJet'),
31 cfg_akt4lc = METAssocConfig(
'AntiKt4LCTopo',
35 modConstKey=modConstKey,
36 modClusColls=modClusColls
38 components_akt4lc=
getAssocCA(cfg_akt4lc,METName=
'AntiKt4LCTopo')
39 components.merge(components_akt4lc)
41 elif jetType ==
"AntiKt4EMTopo":
42 associators = [AssocConfig(
'EMJet'),
48 cfg_akt4em = METAssocConfig(
'AntiKt4EMTopo',
52 modConstKey=modConstKey,
53 modClusColls=modClusColls
55 components_akt4em=
getAssocCA(cfg_akt4em,METName=
'AntiKt4EMTopo')
56 components.merge(components_akt4em)
58 elif jetType ==
"AntiKt4EMPFlow":
59 associators = [AssocConfig(
'PFlowJet'),
65 cfg_akt4pf = METAssocConfig(
'AntiKt4EMPFlow',
69 usePFOLinks=configFlags.MET.UseFELinks
71 components_akt4pf=
getAssocCA(cfg_akt4pf,METName=
'AntiKt4EMPFlow')
72 components.merge(components_akt4pf)
74 raise RuntimeError(
"Jet type not recognized by METAssociatorCfg: {}".
format(jetType) )
80 components.merge(config.accumulator)
81 assocAlg =
getMETAssocAlg(algName=
'METAssociation_'+METName,configs={config.suffix:config})
82 components.addEventAlgo(assocAlg)