1 """Define methods to construct configured TRT overlay algorithms
3 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
6 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
7 from AthenaConfiguration.ComponentFactory
import CompFactory
11 """Return a ComponentAccumulator with TRT data overlay specifics"""
15 from TRT_RawDataByteStreamCnv.TRT_RawDataByteStreamCnvConfig
import TRTOverlayRawDataProviderAlgCfg
22 """Return a ComponentAccumulator for TRTOverlay algorithm"""
24 from TRT_GeoModel.TRT_GeoModelConfig
import TRT_ReadoutGeometryCfg
27 kwargs.setdefault(
"SortBkgInput", flags.Overlay.DataOverlay)
28 kwargs.setdefault(
"BkgInputKey", f
"{flags.Overlay.BkgPrefix}TRT_RDOs")
29 kwargs.setdefault(
"SignalInputKey", f
"{flags.Overlay.SigPrefix}TRT_RDOs")
30 kwargs.setdefault(
"SignalInputSDOKey", f
"{flags.Overlay.SigPrefix}TRT_SDO_Map")
31 kwargs.setdefault(
"OutputKey",
"TRT_RDOs")
33 if not flags.Overlay.DataOverlay:
34 from SGComps.SGInputLoaderConfig
import SGInputLoaderCfg
35 acc.merge(
SGInputLoaderCfg(flags, [f
'TRT_RDO_Container#{kwargs["BkgInputKey"]}']))
38 kwargs.setdefault(
"TRT_HT_OccupancyCorrectionBarrel", 0.110)
39 kwargs.setdefault(
"TRT_HT_OccupancyCorrectionEndcap", 0.090)
40 kwargs.setdefault(
"TRT_HT_OccupancyCorrectionBarrelNoE", 0.060)
41 kwargs.setdefault(
"TRT_HT_OccupancyCorrectionEndcapNoE", 0.050)
42 kwargs.setdefault(
"TRT_HT_OccupancyCorrectionBarrelAr", 0.100)
43 kwargs.setdefault(
"TRT_HT_OccupancyCorrectionEndcapAr", 0.101)
44 kwargs.setdefault(
"TRT_HT_OccupancyCorrectionBarrelArNoE", 0.088)
45 kwargs.setdefault(
"TRT_HT_OccupancyCorrectionEndcapArNoE", 0.102)
47 from InDetConfig.TRT_ElectronPidToolsConfig
import TRT_OverlayLocalOccupancyCfg
50 from RngComps.RngCompsConfig
import AthRNGSvcCfg
51 kwargs.setdefault(
"RndmSvc", acc.getPrimaryAndMerge(
AthRNGSvcCfg(flags)).name)
54 acc.addEventAlgo(CompFactory.TRTOverlay(name, **kwargs))
57 if flags.Output.doWriteRDO:
58 from OutputStreamAthenaPool.OutputStreamConfig
import OutputStreamCfg
60 "TRT_RDO_Container#TRT_RDOs"
63 if flags.Overlay.DataOverlay:
65 "TRT_BSErrContainer#TRT_ByteStreamErrs"
68 if flags.Output.doWriteRDO_SGNL:
69 from OutputStreamAthenaPool.OutputStreamConfig
import OutputStreamCfg
71 f
"TRT_RDO_Container#{flags.Overlay.SigPrefix}TRT_RDOs"
74 if flags.Overlay.doTrackOverlay:
77 f
"TRT_RDO_Container#{flags.Overlay.SigPrefix}TRT_RDOs"]))
83 """Return a ComponentAccumulator for the TRT SDO overlay algorithm"""
87 if flags.Overlay.DataOverlay:
88 kwargs.setdefault(
"BkgInputKey",
"")
90 kwargs.setdefault(
"BkgInputKey", f
"{flags.Overlay.BkgPrefix}TRT_SDO_Map")
92 if kwargs[
"BkgInputKey"]:
93 from SGComps.SGInputLoaderConfig
import SGInputLoaderCfg
94 acc.merge(
SGInputLoaderCfg(flags, [f
'InDetSimDataCollection#{kwargs["BkgInputKey"]}']))
96 kwargs.setdefault(
"SignalInputKey", f
"{flags.Overlay.SigPrefix}TRT_SDO_Map")
97 kwargs.setdefault(
"OutputKey",
"TRT_SDO_Map")
100 acc.addEventAlgo(CompFactory.InDetSDOOverlay(name, **kwargs))
103 if flags.Output.doWriteRDO:
104 from OutputStreamAthenaPool.OutputStreamConfig
import OutputStreamCfg
106 "InDetSimDataCollection#TRT_SDO_Map"
109 if flags.Output.doWriteRDO_SGNL:
110 from OutputStreamAthenaPool.OutputStreamConfig
import OutputStreamCfg
112 f
"InDetSimDataCollection#{flags.Overlay.SigPrefix}TRT_SDO_Map"
119 """Configure and return a ComponentAccumulator for TRT overlay"""
123 if flags.Overlay.DataOverlay:
127 from TRT_Digitization.TRT_DigitizationConfig
import TRT_OverlayDigitizationBasicCfg
132 if flags.Digitization.EnableTruth: