ATLAS Offline Software
Loading...
Searching...
No Matches
LucidRecConfig.py
Go to the documentation of this file.
1# Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
2
3from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
4from AthenaConfiguration.ComponentFactory import CompFactory
5from OutputStreamAthenaPool.OutputStreamConfig import addToESD
6from ByteStreamCnvSvc.ByteStreamConfig import ByteStreamReadCfg
7
8
9def LucidRecCfg(flags):
10 result=ComponentAccumulator()
11
12 if flags.Input.isMC:
13 result.addEventAlgo(CompFactory.LUCID_DigitRawDataCnv("LUCID_DigitRawDataCnv"))
14 else:
15 result.merge(ByteStreamReadCfg(flags))
16 result.addEventAlgo(CompFactory.LUCID_ByteStreamRawDataCnv("LUCID_ByteStreamRawDataCnv"))
17 result.merge(addToESD(flags,["LUCID_RawDataContainer#Lucid_RawData",]))
18
19 return result
20
21
22
23
24if __name__=="__main__":
25 from AthenaConfiguration.MainServicesConfig import MainServicesCfg
26 from AthenaConfiguration.AllConfigFlags import initConfigFlags
27 from AthenaCommon.Logging import log
28 from AthenaCommon.Constants import DEBUG
29 log.setLevel(DEBUG)
30
31 from AthenaConfiguration.TestDefaults import defaultTestFiles
32 flags = initConfigFlags()
33 flags.Input.Files = defaultTestFiles.RAW_RUN2
34 flags.lock()
35
36 acc = MainServicesCfg(flags)
37 acc.merge(LucidRecCfg(flags))
38
39 acc.run(10)