ATLAS Offline Software
Functions
TCAL2 Namespace Reference

Functions

def TCAL2MbtsToVectorsToolCfg (flags, **kwargs)
 
def TCAL2E4prToVectorsToolCfg (flags, **kwargs)
 
def TCAL2KernelCfg (flags, name='TCAL2Kernel', **kwargs)
 
def TCAL2Cfg (flags)
 

Function Documentation

◆ TCAL2Cfg()

def TCAL2.TCAL2Cfg (   flags)
Configure the TCAL1 derivation framework

Definition at line 69 of file TCAL2.py.

69 def TCAL2Cfg(flags):
70  """Configure the TCAL1 derivation framework"""
71 
72  TCAL2Prefix = 'TCAL2_'
73 
74  acc = ComponentAccumulator()
75  acc.merge(TCAL2KernelCfg(flags, name="TCAL2Kernel", StreamName = "StreamDAOD_TCAL2", Prefix=TCAL2Prefix))
76 
77  from OutputStreamAthenaPool.OutputStreamConfig import OutputStreamCfg
78  from xAODMetaDataCnv.InfileMetaDataConfig import SetupMetaDataForStreamCfg
79  from DerivationFrameworkCore.SlimmingHelper import SlimmingHelper
80  TCAL2SlimmingHelper = SlimmingHelper("TCAL2SlimmingHelper", NamesAndTypes = flags.Input.TypedCollections, flags = flags)
81  TCAL2SlimmingHelper.SmartCollections = ["EventInfo"]
82 
83  if flags.GeoModel.Run in [LHCPeriod.Run1, LHCPeriod.Run2, LHCPeriod.Run3]:
84  mbtsItems = [f'std::vector<float>#TCAL2_mbts_{item}' for item in ['energy', 'time', 'eta', 'phi']]
85  mbtsItems += [f'std::vector<int>#TCAL2_mbts_{item}' for item in ['quality', 'module', 'channel', 'type']]
86  TCAL2SlimmingHelper.StaticContent = mbtsItems
87  if flags.GeoModel.Run is LHCPeriod.Run2:
88  e4prItems = [f'std::vector<float>#TCAL2_e4pr_{item}' for item in ['energy', 'time']]
89  e4prItems += ['std::vector<int>#TCAL2_e4pr_{item}' for item in ['quality', 'module', 'channel', 'type']]
90  TCAL2SlimmingHelper.StaticContent += e4prItems
91  TCAL2ItemList = TCAL2SlimmingHelper.GetItemList()
92 
93  acc.merge(OutputStreamCfg(flags, "DAOD_TCAL2", ItemList=TCAL2ItemList, AcceptAlgs=["TCAL2Kernel"]))
94  acc.merge(SetupMetaDataForStreamCfg(flags, "DAOD_TCAL2", AcceptAlgs=["TCAL2Kernel"], createMetadata=[MetadataCategory.CutFlowMetaData]))
95 
96  return acc

◆ TCAL2E4prToVectorsToolCfg()

def TCAL2.TCAL2E4prToVectorsToolCfg (   flags,
**  kwargs 
)
Configure the E4prToVectorsTool augmentation tool 

Definition at line 29 of file TCAL2.py.

29 def TCAL2E4prToVectorsToolCfg(flags, **kwargs):
30  """ Configure the E4prToVectorsTool augmentation tool """
31 
32  acc = ComponentAccumulator()
33 
34  from TileGeoModel.TileGMConfig import TileGMCfg
35  acc.merge(TileGMCfg(flags))
36 
37  from LArGeoAlgsNV.LArGMConfig import LArGMCfg
38  acc.merge(LArGMCfg(flags))
39 
40  kwargs.setdefault('name', 'TCAL2E4prToVectorsTool')
41  kwargs.setdefault('Prefix', 'TCAL2_e4pr')
42  kwargs.setdefault('SaveEtaPhiInfo', False)
43  kwargs.setdefault('CellContainer', 'E4prContainer')
44 
45  MbtsToVectorsTool = CompFactory.DerivationFramework.MbtsToVectorsTool
46  acc.addPublicTool(MbtsToVectorsTool(**kwargs), primary = True)
47 
48  return acc
49 
50 

◆ TCAL2KernelCfg()

def TCAL2.TCAL2KernelCfg (   flags,
  name = 'TCAL2Kernel',
**  kwargs 
)
Configure the TCAL2 derivation framework driving algorithm (kernel)

Definition at line 51 of file TCAL2.py.

51 def TCAL2KernelCfg(flags, name='TCAL2Kernel', **kwargs):
52  """Configure the TCAL2 derivation framework driving algorithm (kernel)"""
53 
54  acc = ComponentAccumulator()
55 
56  prefix = kwargs.pop('Prefix', 'TCAL2_')
57 
58  cellsToVectorstools = []
59  if flags.GeoModel.Run in [LHCPeriod.Run1, LHCPeriod.Run2, LHCPeriod.Run3]:
60  cellsToVectorstools.append( acc.getPrimaryAndMerge(TCAL2MbtsToVectorsToolCfg(flags, Prefix=f'{prefix}mbts_')) )
61  if flags.GeoModel.Run is LHCPeriod.Run2:
62  cellsToVectorstools += acc.getPrimaryAndMerge(TCAL2E4prToVectorsToolCfg(flags, Prefix=f'{prefix}e4pr_'))
63 
64  DerivationKernel = CompFactory.DerivationFramework.DerivationKernel
65  acc.addEventAlgo(DerivationKernel(name, AugmentationTools = cellsToVectorstools))
66 
67  return acc
68 

◆ TCAL2MbtsToVectorsToolCfg()

def TCAL2.TCAL2MbtsToVectorsToolCfg (   flags,
**  kwargs 
)
Configure the MbtsToVectorsTool augmentation tool 

Definition at line 7 of file TCAL2.py.

7 def TCAL2MbtsToVectorsToolCfg(flags, **kwargs):
8  """ Configure the MbtsToVectorsTool augmentation tool """
9 
10  acc = ComponentAccumulator()
11 
12  from TileGeoModel.TileGMConfig import TileGMCfg
13  acc.merge(TileGMCfg(flags))
14 
15  from LArGeoAlgsNV.LArGMConfig import LArGMCfg
16  acc.merge(LArGMCfg(flags))
17 
18  kwargs.setdefault('name', 'TCAL2MbtsToVectorsTool')
19  kwargs.setdefault('Prefix', 'TCAL2_mbts_')
20  kwargs.setdefault('SaveEtaPhiInfo', True)
21  kwargs.setdefault('CellContainer', 'MBTSContainer')
22 
23  MbtsToVectorsTool = CompFactory.DerivationFramework.MbtsToVectorsTool
24  acc.addPublicTool(MbtsToVectorsTool(**kwargs), primary = True)
25 
26  return acc
27 
28 
python.JetAnalysisCommon.ComponentAccumulator
ComponentAccumulator
Definition: JetAnalysisCommon.py:302
python.OutputStreamConfig.OutputStreamCfg
def OutputStreamCfg(flags, streamName, ItemList=[], MetadataItemList=[], disableEventTag=False, trigNavThinningSvc=None, takeItemsFromInput=False, extendProvenanceRecord=True, AcceptAlgs=[], HelperTools=[])
Definition: OutputStreamConfig.py:12
TCAL2.TCAL2MbtsToVectorsToolCfg
def TCAL2MbtsToVectorsToolCfg(flags, **kwargs)
Definition: TCAL2.py:7
TCAL2.TCAL2E4prToVectorsToolCfg
def TCAL2E4prToVectorsToolCfg(flags, **kwargs)
Definition: TCAL2.py:29
TCAL2.TCAL2Cfg
def TCAL2Cfg(flags)
Definition: TCAL2.py:69
LArGMConfig.LArGMCfg
def LArGMCfg(flags)
Definition: LArGMConfig.py:8
TCAL2.TCAL2KernelCfg
def TCAL2KernelCfg(flags, name='TCAL2Kernel', **kwargs)
Definition: TCAL2.py:51
InfileMetaDataConfig.SetupMetaDataForStreamCfg
def SetupMetaDataForStreamCfg(flags, streamName="", AcceptAlgs=None, createMetadata=None, propagateMetadataFromInput=True, *args, **kwargs)
Definition: InfileMetaDataConfig.py:222
SlimmingHelper
Definition: SlimmingHelper.py:1
python.HION12.DerivationKernel
DerivationKernel
Definition: HION12.py:66
TileGMConfig.TileGMCfg
def TileGMCfg(flags)
Definition: TileGMConfig.py:7