11 acc = ComponentAccumulator()
12 TileContByteStreamTool = CompFactory.getComp(name)
13 tool = TileContByteStreamTool(name, **kwargs)
14 tool.InitializeForWriting = InitializeForWriting
15 acc.addPublicTool(tool)
18 if InitializeForWriting:
19 from TileByteStream.TileHid2RESrcIDConfig
import TileHid2RESrcIDCondAlgCfg
20 acc.merge( TileHid2RESrcIDCondAlgCfg(flags, ForHLT=
True) )
22 extraOutputs = [(
'TileHid2RESrcID',
'ConditionStore+TileHid2RESrcIDHLT')]
24 return acc, extraOutputs
63 readMuRcv=None, readMuRcvDigits=False, readMuRcvRawCh=False,
64 readBeamElem=None, readLaserObj=None, readDigitsFlx=False,
65 readL2=False, stateless=False, **kwargs):
67 Configure reading the Tile BS files
70 read[...] -- flag to read the corresponding Tile data from BS.
71 Possible values: None (default), True, False.
72 In the case of None it will be autoconfigured.
73 stateless -- read online Tile data using emon BS service.
76 isPhysicsRun = flags.Tile.RunType
is TileRunType.PHY
77 isLaserRun = flags.Tile.RunType
in [TileRunType.LAS, TileRunType.BILAS]
78 isCalibRun =
not isPhysicsRun
81 readMuRcv = isPhysicsRun
if readMuRcv
is None else readMuRcv
82 readBeamElem = isCalibRun
if readBeamElem
is None else readBeamElem
83 readLaserObj = isLaserRun
if readLaserObj
is None else readLaserObj
85 typeNames = kwargs.pop(
'type_names', [])
87 prefix = flags.Overlay.BkgPrefix
if flags.Common.ProductionStep
is ProductionStep.MinbiasPreprocessing
else ''
89 cfg = ComponentAccumulator()
90 from TileConditions.TileCablingSvcConfig
import TileCablingSvcCfg
91 cfg.merge(TileCablingSvcCfg(flags))
94 from ByteStreamEmonSvc.EmonByteStreamConfig
import EmonByteStreamCfg
95 cfg.merge( EmonByteStreamCfg(flags, type_names=typeNames) )
97 from ByteStreamCnvSvc.ByteStreamConfig
import ByteStreamReadCfg
98 cfg.merge( ByteStreamReadCfg(flags, type_names=typeNames) )
100 from TileByteStream.TileHid2RESrcIDConfig
import TileHid2RESrcIDCondAlgCfg
101 cfg.merge( TileHid2RESrcIDCondAlgCfg(flags, ROD2ROBmap=[
'-1']) )
104 addTileReadAlg(cfg,
'TileDigitsReadAlg', TileDigitsContainer=f
'{prefix}TileDigitsCnt')
106 addTileReadAlg(cfg,
'TileRawChannelReadAlg', TileRawChannelContainer=f
'{prefix}TileRawChannelCnt')
108 addTileReadAlg(cfg,
'TileMuRcvReadAlg', TileMuonReceiverContainer=
'TileMuRcvCnt')
110 addTileReadAlg(cfg,
'MuRcvDigitsReadAlg', MuRcvDigitsContainer=f
'{prefix}MuRcvDigitsCnt')
112 addTileReadAlg(cfg,
'TileMuRcvRawChReadAlg', MuRcvRawChannelContainer=
'MuRcvRawChCnt')
114 addTileReadAlg(cfg,
'TileLaserObjReadAlg', TileLaserObject=
'TileLaserObj')
116 addTileReadAlg(cfg,
'TileBeamElemReadAlg', TileBeamElemContainer=
'TileBeamElemCnt')
118 addTileReadAlg(cfg,
'TileDigitsFlxReadAlg', TileDigitsFlxContainer=
'TileDigitsFlxCnt')
128 from AthenaConfiguration.TestDefaults
import defaultGeometryTags, defaultTestFiles
TileRawDataReadingCfg(flags, readDigits=True, readRawChannel=True, readMuRcv=None, readMuRcvDigits=False, readMuRcvRawCh=False, readBeamElem=None, readLaserObj=None, readDigitsFlx=False, readL2=False, stateless=False, **kwargs)