15 """ With this function we will setup the sequence of offline EgammaAlgorithms so to make a electron for TrigEgamma
17 Sequence of algorithms is the following:
18 - egammaRecBuilder/TrigEgammaRecElectron creates egammaObjects out of clusters and tracks.
19 - electronSuperClusterBuilder algorithm will create superclusters out of the topoclusters and tracks in egammaRec under the electron hypothesis
20 https://gitlab.cern.ch/atlas/athena/blob/master/Reconstruction/egamma/egammaAlgs/python/egammaSuperClusterBuilder.py#L26
21 - TopoEgammBuilder will create photons and electrons out of trakcs and SuperClusters. Here at HLT electrons the aim is to ignore photons.
22 https://gitlab.cern.ch/atlas/athena/blob/master/Reconstruction/egamma/egammaAlgs/src/xAODEgammaBuilder.cxx
25 log.debug(
'precisionElectronRecoSequence(RoIs = %s, ion = %s, doGSF = %s, doLRT = %s)',RoIs,ion,doGSF,doLRT)
27 tag =
'_ion' if ion
is True else ''
36 if not doLRT
and not doGSF:
41 from TriggerMenuMT.HLT.Egamma.TrigEgammaKeys
import getTrigEgammaKeys
55 trackParticles = TrigEgammaKeys.precisionElectronTrackParticleContainerGSF
58 trackParticles = TrigEgammaKeys_noGSF.precisionTrackingContainer
61 caloClusters = TrigEgammaKeys.precisionElectronCaloClusterContainer
62 egammaRecContainer = TrigEgammaKeys.precisionEgammaRecCollection
63 superElectronRecCollectionName = TrigEgammaKeys.precisionElectronSuperClusterCollection
64 superPhotonRecCollectionName = TrigEgammaKeys.precisionPhotonSuperClusterCollection
65 photonOutputName = TrigEgammaKeys.precisionPhotonContainer
66 trackParticles_noGSF = TrigEgammaKeys_noGSF.precisionTrackingContainer
67 TrackParticleLocation = TrigEgammaKeys.precisionTrackingContainer
68 electronOutputName = TrigEgammaKeys.precisionElectronContainer
70 OutputClusterContainerName = TrigEgammaKeys.precisionElectronEMClusterContainer
73 cellsName =
"CaloCells" if not ion
else "CorrectedRoICaloCells"
74 dataObjects = [(
'CaloCellContainer' ,
'StoreGateSvc+%s' % cellsName ),
75 (
'xAOD::CaloClusterContainer' ,
'StoreGateSvc+%s' % caloClusters ),
76 (
'xAOD::TrackParticleContainer',
'StoreGateSvc+%s' % trackParticles_noGSF)]
80 (
'xAOD::TrackParticleContainer',
'StoreGateSvc+%s' % trackParticles),
81 (
'SG::AuxElement' ,
'StoreGateSvc+EventInfo.averageInteractionsPerCrossing' ),
82 (
'SG::AuxElement' ,
'StoreGateSvc+EventInfo.AveIntPerXDecor' )]
84 if flags.Detector.GeometryTRT:
85 dataObjects += [(
'InDet::TRT_DriftCircleContainer' ,
'StoreGateSvc+%s' %
"TRT_TrigDriftCircles" )]
87 dataObjects += [(
'TRT_RDO_Container' ,
'StoreGateSvc+TRT_RDOs' )]
89 dataObjects += [(
'TRT_RDO_Cache' , f
'StoreGateSvc+{flags.Trigger.InDetTracking.TRTRDOCacheKey}' )]
91 ambimap = flags.Trigger.InDetTracking.ClusterAmbiguitiesMap
92 if flags.Detector.GeometryITk:
93 ambimap = flags.Trigger.ITkTracking.ClusterAmbiguitiesMap
95 dataObjects += [(
'InDet::PixelGangedClusterAmbiguities' ,
'StoreGateSvc+%s' % ambimap )]
97 if not flags.Input.isMC:
98 dataObjects += [(
'IDCInDetBSErrContainer' ,
'StoreGateSvc+PixelByteStreamErrs' )]
100 precisionElectronVDV = CompFactory.AthViews.ViewDataVerifier(
"precisionElectron"+tag+
"VDV")
101 precisionElectronVDV.DataObjects = dataObjects
102 acc.addEventAlgo(precisionElectronVDV)
104 """ Retrieve the factories now """
105 from TriggerMenuMT.HLT.Electron.TrigElectronFactoriesCfg
import TrigEgammaRecElectronCfg, TrigElectronSuperClusterBuilderCfg, TrigTopoEgammaElectronCfg, TrigElectronIsoBuilderCfg
113 acc.merge(TrigEgammaRecAlgo)
117 acc.merge(TrigSuperElectronAlgo)
120 TrigTopoEgammaAlgo =
TrigTopoEgammaElectronCfg(flags, tag, variant, cellsName, superElectronRecCollectionName, superPhotonRecCollectionName, electronOutputName, photonOutputName,OutputClusterContainerName)
122 acc.merge(TrigTopoEgammaAlgo)
124 collectionOut = electronOutputName
128 acc.merge(isoBuilder)
130 isoVarKeys = [
'%s.ptcone20' % collectionOut,
131 '%s.ptvarcone20' % collectionOut,
132 '%s.ptcone30' % collectionOut,
133 '%s.ptvarcone30' % collectionOut ]
136 from TriggerMenuMT.HLT.Electron.TrigElectronFactoriesCfg
import PrecisionElectronTopoMonitorCfg
139 acc.merge(PrecisionElectronRecoMonAlgo)
142 from TriggerMenuMT.HLT.Electron.TrigElectronFactoriesCfg
import PrecisionElectronSuperClusterMonitorCfg
145 acc.merge(PrecisionElectronSuperClusterMonAlgo)