ATLAS Offline Software
FPGATrackSimConfigFlags.py
Go to the documentation of this file.
1 #Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3 
5  from AthenaConfiguration.AthConfigFlags import AthConfigFlags
6  cf = AthConfigFlags()
7  cf.addFlag('pipeline', '')
8  cf.addFlag('algoTag', 'Hough')
9  cf.addFlag('wrapperFileName', [])
10  cf.addFlag('wrapperFileName2', [])
11  cf.addFlag('secondInputToolN', 0)
12  cf.addFlag('mapsDir', '__MUST_BE_SET__')
13  cf.addFlag('wrapperMetaData', "Default Meta Data")
14  cf.addFlag('sampleType', 'singleMuons')
15  cf.addFlag('FPGATrackSimMatrixFileRegEx', [])
16  cf.addFlag('FPGATrackSimMaxnMatrixInputFiles', -1)
17  cf.addFlag('outputMergedFPGATrackSimMatrixFile', 'combined_matrix.root')
18  cf.addFlag('FPGATrackSimNBanks', 1)
19  cf.addFlag('FPGATrackSimallBanks', False)
20  cf.addFlag('region', 0)
21  cf.addFlag('minSpacePlusPixel', 3)
22  cf.addFlag('baseName', '')
23  cf.addFlag('CheckGood2ndStage', True)
24  cf.addFlag('Is2ndStage', False)
25  cf.addFlag('UseHitScaleFactor', False)
26  cf.addFlag('missHitsConsts', False)
27  cf.addFlag('tracking', False)
28  cf.addFlag('doOverlapRemoval', True)
29  cf.addFlag('clustering', 1)
30  cf.addFlag('bankDir', '')
31  cf.addFlag('spacePoints', True)
32  cf.addFlag('outputMonitorFile',"monitoring.root")
33  cf.addFlag('connectToToITkTracking',True)
34  cf.addFlag('loglevel', AthenaCommon.Constants.INFO)
35  cf.addFlag('msgLimit',-1)
36  cf.addFlag('singleTrackSample', True)
37  cf.addFlag('FakeNNonnxFile', '')
38  cf.addFlag('ParamNNonnxFile', '')
39 
40  def __httHough1DFlags():
41  """Additional function delays import"""
42  from FPGATrackSimConfTools.FPGATrackSimConfigFlags import createHough1dFPGATrackSimConfigFlags
44  cf.addFlagsCategory("Hough1D", __httHough1DFlags, prefix=True )
45 
46  def __httHoughFlags():
47  """Additional function delays import"""
48  from FPGATrackSimConfTools.FPGATrackSimConfigFlags import createHoughFPGATrackSimConfigFlags
50  cf.addFlagsCategory("Hough", __httHoughFlags, prefix=True )
51 
52  def __httGenScanFlags():
53  """Additional function delays import"""
54  from FPGATrackSimConfTools.FPGATrackSimConfigFlags import createGenScanFPGATrackSimConfigFlags
56  cf.addFlagsCategory("GenScan", __httGenScanFlags, prefix=True )
57 
58  def __httDev21_02_15Flags():
59  """Additional function delays import"""
60  from FPGATrackSimConfTools.FPGATrackSimConfigFlags import createDev21_02_15_FPGATrackSimConfigFlags
62  cf.addFlagsCategory("Dev21_02_15", __httDev21_02_15Flags, prefix=True )
63 
64 
65  # EDM conversion
66  cf.addFlag('doEDMConversion', False)
67  cf.addFlag('convertUnmappedHits', False)
68  cf.addFlag('writeToAOD', False)
69 
70  # ACTS Tracking
71  cf.addFlag('runCKF',True)
72  return cf
73 
74 
76  from AthenaConfiguration.AthConfigFlags import AthConfigFlags
77  cf = AthConfigFlags()
78 
79  # common
80  cf.addFlag('name', '')
81 
82  # input
83  cf.addFlag('firstInputToolN', 1)
84  cf.addFlag('realHitsOverlay', False)
85  cf.addFlag('hitFiltering', False)
86  cf.addFlag('spacePointFiltering', False)
87  cf.addFlag('writeOutputData', True)
88 
89  # road finding selection
90  cf.addFlag('houghRootoutput', False)
91  cf.addFlag('hough', True)
92  cf.addFlag('hough1D', False)
93  cf.addFlag('genScan', False)
94  cf.addFlag('NumOfHitPerGrouping', 5)
95 
96  cf.addFlag('etaPatternFilter', False)
97  cf.addFlag('phiRoadFilter', False)
98 
99 
100  # NN filtering
101  cf.addFlag('trackNNAnalysis', False)
102 
103  # overlap removal
104  cf.addFlag('doFastOR', False)
105 
106  # hough
107  cf.addFlag('xVar', 'phi')
108  cf.addFlag('yVar', 'q/pt')
109  cf.addFlag('qptMin', -1.0)
110  cf.addFlag('qptMax', 1.0)
111  cf.addFlag('d0Slices', [])
112  cf.addFlag('slicing', True)
113  cf.addFlag('localMaxWindowSize', 0)
114  cf.addFlag('roadSliceOR', False)
115  cf.addFlag('fieldCorrection', True)
116  cf.addFlag('phiMin', 0.0)
117  cf.addFlag('phiMax', 0.0)
118  cf.addFlag('xBins', 216)
119  cf.addFlag('yBins', 216)
120  cf.addFlag('xBufferBins', 6)
121  cf.addFlag('yBufferBins', 2)
122  cf.addFlag('threshold', [8])
123  cf.addFlag('IdealGeoRoads', True)
124  cf.addFlag('convolution', [])
125  cf.addFlag('convSizeX', 0)
126  cf.addFlag('convSizeY', 0)
127  cf.addFlag('hitExtendX', [])
128 
129  cf.addFlag('doMajority', 1)
130 
131  cf.addFlag('doTracking', False)
132  cf.addFlag('outputHitTxt', False)
133 
134  # performance monitoring
135  cf.addFlag('barcodeFracMatch', 0.5)
136 
137  # track Fitter
138  cf.addFlag('chi2DoFRecoveryMin', 40)
139  cf.addFlag('chi2DoFRecoveryMax', 20000)
140  cf.addFlag('nHitsNoRecovery', -1)
141  cf.addFlag('guessHits', True)
142  cf.addFlag('doMissingHitsChecks', False)
143  cf.addFlag('idealCoordFitType', 2)
144  cf.addFlag('doDeltaGPhis', False)
145  cf.addFlag('chi2cut', 40)
146 
147  # second stage fitting
148  cf.addFlag('secondStage', False)
149  cf.addFlag('secondChi2Cut', 40)
150 
151  # fast monitoring
152  cf.addFlag('fastMon', False)
153  cf.addFlag('canExtendHistRanges', False)
154  cf.addFlag('dataClass', 2)
155 
156  # lrt settings
157  cf.addFlag('lrt', False)
158  cf.addFlag('lrtUseBasicHitFilter', False)
159  cf.addFlag('lrtUseMlHitFilter', False)
160  cf.addFlag('lrtUseStraightTrackHT', False)
161  cf.addFlag('lrtUseDoubletHT', False)
162  cf.addFlag('lrtDoubletD0Range', 120.0)
163  cf.addFlag('lrtDoubletD0Bins', 216)
164  cf.addFlag('lrtDoubletQptRange', 0.02)
165  cf.addFlag('lrtDoubletQptBins', 216)
166  cf.addFlag('lrtMonPhiRange', (0.2, 0.5))
167  cf.addFlag('lrtMonD0Range', (-100,100))
168  cf.addFlag('lrtMonZ0Range', (-300,300))
169  cf.addFlag('sampleType', '')
170 
171  return cf
172 
173 
176 
177  cf.name = 'hough_1d'
178 
179  cf.hough1D = True
180 
181  cf.phiMin = 0.0
182  cf.phiMax = 0.8
183  cf.xBins = 200
184  cf.threshold = [7]
185  cf.hitExtendX = [1] * 9
186 
187  cf.addFlag('phiRangeCut', True)
188  cf.addFlag('splitpt', 1)
189  cf.addFlag('phifilterwindow', 0.005)
190 
191  cf.outputHitTxt = ""
192 
193  return cf
194 
195 
198 
199  cf.name = 'hough'
200  cf.hough = True
201 
202 
203  cf.phiMin = 0.3
204  cf.phiMax = 0.5
205  cf.xBins = 216
206  cf.yBins = 216
207  cf.xBufferBins = 6
208  cf.yBufferBins = 2
209  cf.addFlag('combineLayers', [])
210  cf.addFlag('scale', [])
211  cf.hitExtendX = [2,1,0,0,0,0,0,0,0]
212 
213  cf.addFlag('lrtSkipHitFiltering', False)
214  cf.addFlag('lrtPtmin', 5)
215  cf.addFlag('allowHighTruthBarcode', False)
216  cf.addFlag('mLRTpdgID', 0)
217  cf.addFlag('lrtStraighttrackXVar', 'phi')
218  cf.addFlag('lrtStraighttrackYVar', 'd0')
219  cf.addFlag('lrtStraighttrackPhiMin', 0.3)
220  cf.addFlag('lrtStraighttrackPhiMax', 0.5)
221  cf.addFlag('lrtStraighttrackD0Min', -300.0)
222  cf.addFlag('lrtStraighttrackD0Max', 300.0)
223  cf.addFlag('lrtStraighttrackXBins', 216)
224  cf.addFlag('lrtStraighttrackYBins', 216)
225  cf.addFlag('lrtStraighttrackXBufferBins', 6)
226  cf.addFlag('lrtStraighttrackYBufferBins', 2)
227  cf.addFlag('lrtStraighttrackSlicing', True)
228  cf.addFlag('lrtStraighttrackThreshold', [1])
229  cf.addFlag('lrtStraighttrackConvolution', [])
230  cf.addFlag('lrtStraighttrackCombineLayers', [0,1,2,3,4,5,6,7])
231  cf.addFlag('lrtStraighttrackScale', [1])
232  cf.addFlag('lrtStraighttrackConvSizeX', 0)
233  cf.addFlag('lrtStraighttrackConvSizeY', 0)
234  cf.addFlag('lrtStraighttrackHitExtendX', [])
235  cf.addFlag('lrtStraighttrackStereo', False)
236  cf.addFlag('lrtStraighttrackLocalMaxWindowSize', 0)
237 
238  return cf
239 
240 
243 
244  cf.name = 'dev_21-02-15'
245  cf.phiMin = 0.3
246  cf.phiMax = 0.5
247  cf.xBins = 64
248  cf.yBins = 216
249  cf.xBufferBins = 2
250  cf.yBufferBins = 2
251  cf.threshold = [70]
252  cf.convolution = [1, 10, 1]
253  cf.addFlag('combineLayers', [])
254  cf.addFlag('scale', [])
255  cf.convSizeX = 3
256  cf.convSizeY = 1
257 
258  cf.doMajority = 0
259  cf.doTracking = True
260 
261  return cf
262 
265 
266  cf.name = 'genScan'
267  cf.addFlag('genScanCuts','FPGATrackSimHough.FPGATrackSimGenScanCuts')
268  cf.addFlag('reverse','False')
269  cf.addFlag('binFilter','PairThenGroup')
270 
271  return cf
272 
273 
274 
275 
278 
279 if __name__ == "__main__":
280 
282  flags.loadAllDynamicFlags()
283  flags.initAll()
284  flags.dump()
285  assert flags.Hough.firstInputToolN == 1 , "default firstInputToolN is wrong"
286  assert flags.Hough.barcodeFracMatch == 0.5, "default barcodeFracMatch is wrong"
287  assert flags.Hough.fastMon is False , "default fastMon is wrong"
288  assert flags.Hough.lrtMonZ0Range == (-300,300), "default lrtMonZ0Rang is wrong"
289 
290  print( "allok" )
291 
292 
293 
294 
295 
296 
297 
298 
python.FPGATrackSimConfigFlags.createHoughFPGATrackSimConfigFlags
def createHoughFPGATrackSimConfigFlags()
Definition: FPGATrackSimConfigFlags.py:196
python.FPGATrackSimConfigFlags.createGenScanFPGATrackSimConfigFlags
def createGenScanFPGATrackSimConfigFlags()
Definition: FPGATrackSimConfigFlags.py:263
python.FPGATrackSimConfigFlags.createDev21_02_15_FPGATrackSimConfigFlags
def createDev21_02_15_FPGATrackSimConfigFlags()
Definition: FPGATrackSimConfigFlags.py:241
python.FPGATrackSimConfigFlags.createFPGATrackSimConfigFlags
def createFPGATrackSimConfigFlags()
Definition: FPGATrackSimConfigFlags.py:4
Constants
some useful constants -------------------------------------------------—
print
void print(char *figname, TCanvas *c1)
Definition: TRTCalib_StrawStatusPlots.cxx:25
python.FPGATrackSimConfigFlags.createHough1dFPGATrackSimConfigFlags
def createHough1dFPGATrackSimConfigFlags()
Definition: FPGATrackSimConfigFlags.py:174
python.FPGATrackSimConfigFlags.createBasicFPGATrackSimConfigFlags
def createBasicFPGATrackSimConfigFlags()
Definition: FPGATrackSimConfigFlags.py:75