4 This file defines the factories of the algorithms to be used in a photon trigger sequence in athenaMT
5 These are inspired by the offline factories, alhtough modified so they reflect the configuration we need for these algorithms at the HLT.
6 Offline configurations are available here:
7 https://gitlab.cern.ch/atlas/athena/blob/master/Reconstruction/egamma/egammaAlgs/python/
9 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
10 from AthenaConfiguration.ComponentFactory
import CompFactory
14 from TriggerMenuMT.HLT.Egamma.TrigEgammaKeys
import getTrigEgammaKeys
16 from TrigEgammaMonitoring.egammaMonitorPrecisionConfig
import egammaMonitorPrecisionCfg
18 collectionIn = TrigEgammaKeys.precisionPhotonContainer
19 PrecisionPhotonCaloIsoMonitor = CompFactory.egammaMonitorPhotonAlgorithm(
21 PhotonKey = TrigEgammaKeys.precisionPhotonContainer,
22 IsoVarKeys = [
'%s.topoetcone20' % collectionIn,
'%s.topoetcone40' % collectionIn],
24 acc.addEventAlgo(PrecisionPhotonCaloIsoMonitor)
29 from TriggerMenuMT.HLT.Egamma.TrigEgammaKeys
import getTrigEgammaKeys
31 from egammaMVACalib.egammaMVACalibConfig
import egammaMVASvcCfg
32 tool = CompFactory.EMClusterTool(
'TrigEMClusterTool_photon',
33 OutputClusterContainerName = TrigEgammaKeys.precisionPhotonEMClusterContainer,
34 MVACalibSvc = acc.getPrimaryAndMerge(
egammaMVASvcCfg(flags,name =
"TrigEgammaMVASvc")))
35 acc.setPrivateTools(tool)
40 from TriggerMenuMT.HLT.Egamma.TrigEgammaKeys
import getTrigEgammaKeys
42 from egammaTools.EMShowerBuilderConfig
import EMShowerBuilderCfg
43 from egammaTools.EMPIDBuilderConfig
import EMPIDBuilderPhotonCfg
44 TrigTopoEgammaPhotons = CompFactory.xAODEgammaBuilder( name =
'TrigTopoEgammaPhotons',
45 InputElectronRecCollectionName = TrigEgammaKeys.precisionElectronSuperClusterRecCollection,
46 InputPhotonRecCollectionName = TrigEgammaKeys.precisionPhotonSuperClusterCollection,
47 ElectronOutputName = TrigEgammaKeys.precisionElectronContainer,
48 PhotonOutputName = TrigEgammaKeys.precisionPhotonContainer,
50 EMShowerTool = acc.popToolsAndMerge(
EMShowerBuilderCfg(flags,name=
'TrigEMShowerBuilder',CellsName=
"CaloCells")),
55 acc.addEventAlgo(TrigTopoEgammaPhotons)
60 from TriggerMenuMT.HLT.Egamma.TrigEgammaKeys
import getTrigEgammaKeys
62 from egammaTools.EMShowerBuilderConfig
import EMShowerBuilderCfg
63 from egammaTools.EMPIDBuilderConfig
import EMPIDBuilderPhotonCfg
64 TrigTopoEgammaPhotons = CompFactory.xAODEgammaBuilder( name =
'TrigTopoEgammaPhotons_HI',
65 InputElectronRecCollectionName = TrigEgammaKeys.precisionElectronSuperClusterRecCollection,
66 InputPhotonRecCollectionName = TrigEgammaKeys.precisionPhotonSuperClusterCollection,
67 ElectronOutputName = TrigEgammaKeys.precisionElectronContainer,
68 PhotonOutputName = TrigEgammaKeys.precisionPhotonContainer,
70 EMShowerTool = acc.popToolsAndMerge(
EMShowerBuilderCfg(flags,name=
'TrigEMShowerBuilder_HI',CellsName=
"CorrectedRoICaloCells")),
71 PhotonTools = [acc.popToolsAndMerge(
EMPIDBuilderPhotonCfg(flags,name=
'TrigEMPIDBuilderPhotonCfg_HI'))],
75 acc.addEventAlgo(TrigTopoEgammaPhotons)
81 from TriggerMenuMT.HLT.Egamma.TrigEgammaKeys
import getTrigEgammaKeys
83 from TrigEgammaMonitoring.egammaMonitorPrecisionConfig
import egammaMonitorPrecisionCfg
86 PrecisionPhotonTopoMonitor = CompFactory.egammaMonitorPhotonAlgorithm(
87 name = name+(
'HI' if ion
is True else ''),
88 PhotonKey = TrigEgammaKeys.precisionPhotonContainer,
92 acc.addEventAlgo(PrecisionPhotonTopoMonitor)
98 from TriggerMenuMT.HLT.Egamma.TrigEgammaKeys
import getTrigEgammaKeys
100 from TrigEgammaMonitoring.egammaMonitorPrecisionConfig
import egammaMonitorSuperClusterCfg
103 PrecisionPhotonSuperClusterMonitor = CompFactory.egammaMonitorSuperClusterAlgorithm(
104 name = name+(
'HI' if ion
is True else ''),
105 InputEgammaRecContainerName = TrigEgammaKeys.precisionPhotonSuperClusterCollection,
109 acc.addEventAlgo(PrecisionPhotonSuperClusterMonitor)