ATLAS Offline Software
Functions
python.ITkTrackOutputConfig Namespace Reference

Functions

def ITkTrackRecoOutputCfg (flags, extensions_list=None)
 

Function Documentation

◆ ITkTrackRecoOutputCfg()

def python.ITkTrackOutputConfig.ITkTrackRecoOutputCfg (   flags,
  extensions_list = None 
)

Definition at line 6 of file ITkTrackOutputConfig.py.

6 def ITkTrackRecoOutputCfg(flags, extensions_list=None):
7  if extensions_list is None:
8  extensions_list = []
9 
10  from OutputStreamAthenaPool.OutputStreamConfig import addToESD, addToAOD
11  toAOD = []
12  toESD = []
13 
14  # excluded track aux data
15  excludedAuxData = ('-clusterAssociation.-TTVA_AMVFVertices_forReco.-AssoClustersUFO'
16  '.-TTVA_AMVFWeights_forReco')
17  # remove track decorations used internally by FTAG software
18  excludedAuxData += '.-'.join([''] + FTAG_AUXDATA)
19 
20  # exclude TTVA decorations
21  excludedAuxData += '.-TTVA_AMVFVertices.-TTVA_AMVFWeights'
22 
23  # exclude IDTIDE decorations
24  from DerivationFrameworkInDet.IDTIDE import IDTIDE_AOD_EXCLUDED_AUXDATA
25  excludedAuxData += '.-'.join([''] + IDTIDE_AOD_EXCLUDED_AUXDATA)
26  from DerivationFrameworkInDet.IDTRKVALID import IDTRKVALID_AOD_EXCLUDED_AUXDATA
27  excludedAuxData += '.-'.join([''] + IDTRKVALID_AOD_EXCLUDED_AUXDATA)
28 
29  if not flags.Tracking.writeExtendedSi_PRDInfo:
30  excludedAuxData += '.-msosLink'
31 
32  # Save PRD
33  toESD += [
34  "InDet::SCT_ClusterContainer#ITkStripClusters",
35  "InDet::PixelClusterContainer#ITkPixelClusters",
36  "InDet::PixelGangedClusterAmbiguities#ITkPixelClusterAmbiguitiesMap",
37  ]
38  if flags.Tracking.doPixelClusterSplitting:
39  toESD += [
40  "InDet::PixelGangedClusterAmbiguities#ITkSplitClusterAmbiguityMap"]
41 
42  from InDetConfig.ITkTrackRecoConfig import ITkClusterSplitProbabilityContainerName
43  toESD += ["Trk::ClusterSplitProbabilityContainer#" +
45 
46  # Save (Detailed) Track Truth
47  if flags.Tracking.doTruth:
48  toESD += [
49  "TrackTruthCollection#CombinedITkTracksTrackTruthCollection",
50  "DetailedTrackTruthCollection#CombinedITkTracksDetailedTrackTruth"]
51 
52  if flags.Tracking.doStoreTrackSeeds:
53  listOfExtensionsRequesting = [
54  e for e in extensions_list
55  if (e == '' or flags.Tracking[f"ITk{e}Pass"].storeTrackSeeds) ]
56 
57  for extension in listOfExtensionsRequesting:
58  toESD += ["TrackCollection#SiSPSeedSegments"+extension]
59 
60  toESD += ["TrackCollection#CombinedITkTracks"]
61 
62 
63  toAOD += [
64  "xAOD::TrackParticleContainer#InDetTrackParticles",
65  f"xAOD::TrackParticleAuxContainer#InDetTrackParticlesAux.{excludedAuxData}"
66  ]
67 
68  # This should be activated only if both Legacy and Acts-based tracking
69  # are executed at the same time during reconstruction
70  if flags.Acts.EDM.PersistifyTrackParticles:
71  toAOD += [
72  "xAOD::TrackParticleContainer#ActsInDetTrackParticles",
73  f"xAOD::TrackParticleAuxContainer#ActsInDetTrackParticlesAux.{excludedAuxData}"]
74 
75  if flags.Tracking.writeExtendedSi_PRDInfo:
76  toAOD += [
77  "xAOD::TrackMeasurementValidationContainer#ITkPixelClusters",
78  "xAOD::TrackMeasurementValidationAuxContainer#ITkPixelClustersAux.",
79  "xAOD::TrackMeasurementValidationContainer#ITkStripClusters",
80  "xAOD::TrackMeasurementValidationAuxContainer#ITkStripClustersAux.",
81  "xAOD::TrackStateValidationContainer#ITkPixelMSOSs",
82  "xAOD::TrackStateValidationAuxContainer#ITkPixelMSOSsAux.",
83  "xAOD::TrackStateValidationContainer#ITkStripMSOSs",
84  "xAOD::TrackStateValidationAuxContainer#ITkStripMSOSsAux."
85  ]
86 
87  if flags.Tracking.doStoreSiSPSeededTracks:
88  toAOD += [
89  "xAOD::TrackStateValidationContainer#SiSP_ITkPixel_MSOSs",
90  "xAOD::TrackStateValidationAuxContainer#SiSP_ITkPixel_MSOSsAux.",
91  "xAOD::TrackStateValidationContainer#SiSP_ITkStrip_MSOSs",
92  "xAOD::TrackStateValidationAuxContainer#SiSP_ITkStrip_MSOSsAux."
93  ]
94 
95  if (flags.Tracking.doLargeD0 and
96  flags.Tracking.storeSeparateLargeD0Container):
97  toAOD += [
98  "xAOD::TrackParticleContainer#InDetLargeD0TrackParticles",
99  f"xAOD::TrackParticleAuxContainer#InDetLargeD0TrackParticlesAux.{excludedAuxData}"
100  ]
101 
102  if flags.Tracking.doStoreSiSPSeededTracks:
103  # get list of extensions requesting track candidates. Add always the Primary Pass.
104  listOfExtensionsRequesting = [
105  e for e in extensions_list
106  if (e == '' or flags.Tracking[f"ITk{e}Pass"].storeSiSPSeededTracks) ]
107 
108  for extension in listOfExtensionsRequesting:
109  toAOD += [
110  f"xAOD::TrackParticleContainer#SiSPSeededTracks{extension}TrackParticles",
111  f"xAOD::TrackParticleAuxContainer#SiSPSeededTracks{extension}TrackParticlesAux.{excludedAuxData}"]
112 
113  if flags.Tracking.doStoreTrackSeeds:
114  # get list of extensions requesting track seeds. Add always the Primary Pass.
115  listOfExtensionsRequesting = [
116  e for e in extensions_list
117  if (e == '' or flags.Tracking[f"ITk{e}Pass"].storeTrackSeeds) ]
118  for extension in listOfExtensionsRequesting:
119  toAOD += [
120  f"xAOD::TrackParticleContainer#SiSPSeedSegments{extension}PixelTrackParticles",
121  f"xAOD::TrackParticleAuxContainer#SiSPSeedSegments{extension}PixelTrackParticlesAux.",
122  f"xAOD::TrackParticleContainer#SiSPSeedSegments{extension}StripTrackParticles",
123  f"xAOD::TrackParticleAuxContainer#SiSPSeedSegments{extension}StripTrackParticlesAux."
124  ]
125 
126  result = ComponentAccumulator()
127  result.merge(addToESD(flags, toAOD+toESD))
128  result.merge(addToAOD(flags, toAOD))
129  return result
python.JetAnalysisCommon.ComponentAccumulator
ComponentAccumulator
Definition: JetAnalysisCommon.py:302
python.ITkTrackOutputConfig.ITkTrackRecoOutputCfg
def ITkTrackRecoOutputCfg(flags, extensions_list=None)
Definition: ITkTrackOutputConfig.py:6
python.ITkTrackRecoConfig.ITkClusterSplitProbabilityContainerName
def ITkClusterSplitProbabilityContainerName(flags)
Definition: ITkTrackRecoConfig.py:123
python.OutputStreamConfig.addToESD
def addToESD(flags, itemOrList, **kwargs)
Definition: OutputStreamConfig.py:127
TCS::join
std::string join(const std::vector< std::string > &v, const char c=',')
Definition: Trigger/TrigT1/L1Topo/L1TopoCommon/Root/StringUtils.cxx:10
python.OutputStreamConfig.addToAOD
def addToAOD(flags, itemOrList, **kwargs)
Definition: OutputStreamConfig.py:142