ATLAS Offline Software
Loading...
Searching...
No Matches
LArRawSCDataReadingConfig.py
Go to the documentation of this file.
1# Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
2
3from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
4from AthenaConfiguration.ComponentFactory import CompFactory
5from ByteStreamCnvSvc.ByteStreamConfig import ByteStreamReadCfg
6from AthenaConfiguration.MainServicesConfig import MainServicesCfg
7
8def LArRawSCDataReadingCfg(configFlags, ROBList=None, name="LArRawSCDataReadingAlg", **kwargs):
9 acc=ComponentAccumulator()
10 from LArGeoAlgsNV.LArGMConfig import LArGMCfg
11 acc.merge(LArGMCfg(configFlags))
12 from LArCabling.LArCablingConfig import LArLATOMEMappingCfg
13 acc.merge(LArLATOMEMappingCfg(configFlags))
14
15 if ( not (ROBList is None) ):
16 acc.addEventAlgo(CompFactory.LArRawSCDataReadingAlg(name,
17 LATOMEDecoder = CompFactory.LArLATOMEDecoder("LArLATOMEDecoder",ProtectSourceId = True),
18 ROBList=ROBList,
19 **kwargs)
20 )
21 else :
22 acc.addEventAlgo(CompFactory.LArRawSCDataReadingAlg(name,
23 LATOMEDecoder = CompFactory.LArLATOMEDecoder("LArLATOMEDecoder",ProtectSourceId = True),
24 **kwargs)
25 )
26
27 return acc
28
29def LArRawSCDataReadingInRoICfg(configFlags,name="LArRawSCDataReadingInRoI",etIdCollKey="SC_ET_ID_RoI",ROBList=[]):
30 return LArRawSCDataReadingCfg(configFlags,name=name,adcCollKey="",adcBasCollKey="",etCollKey="",LArLATOMEHeaderKey="",etIdCollKey=etIdCollKey,ROBList=ROBList)
31
32
33if __name__=="__main__":
34
35 from AthenaConfiguration.AllConfigFlags import initConfigFlags
36 flags=initConfigFlags()
37 from AthenaCommon.Logging import log
38 from AthenaCommon.Constants import DEBUG
39 log.setLevel(DEBUG)
40
41 from AthenaConfiguration.TestDefaults import defaultTestFiles
42 flags.LAr.doAlign=False
43 flags.Exec.OutputLevel=DEBUG
44 flags.Input.Files = defaultTestFiles.RAW_RUN2
45 flags.lock()
46
47 acc = MainServicesCfg( flags )
48 acc.merge(ByteStreamReadCfg(flags))
49 acc.merge(LArRawSCDataReadingCfg(flags))
50
51 acc.run(2)
52
LArRawSCDataReadingCfg(configFlags, ROBList=None, name="LArRawSCDataReadingAlg", **kwargs)
LArRawSCDataReadingInRoICfg(configFlags, name="LArRawSCDataReadingInRoI", etIdCollKey="SC_ET_ID_RoI", ROBList=[])