164 def create_path(self):
165 """
166 Sets up a path that plays back pregenerated events or generates events
167 based on the properties in the base class.
168 """
169 path = super().create_path()
170
171 path.add_module("TFCDC_WireHitPreparer",
172 flightTimeEstimation="outwards",
173 UseNLoops=0.5
174 )
175
176 path.add_module("TFCDC_ClusterPreparer")
177
178
179 if self.monte_carlo == "no":
180
181 path.add_module("TFCDC_SegmentFinderFacetAutomaton",
182 SegmentOrientation="outwards"
183 )
184
185 path.add_module("TFCDC_SegmentFitter",
186 inputSegments="CDCSegment2DVector",
187 updateDriftLength=True,
188 useAlphaInDriftLength=True,
189 )
190
191 elif self.monte_carlo == "medium":
192
193 path.add_module("TFCDC_SegmentFinderFacetAutomaton",
194 FacetFilter="truth",
195 FacetRelationFilter="truth",
196 SegmentOrientation="outwards"
197 )
198
199 path.add_module("TFCDC_SegmentFitter",
200 inputSegments="CDCSegment2DVector",
201 updateDriftLength=True,
202 useAlphaInDriftLength=True,
203 )
204
205 elif self.monte_carlo == "full":
206
207
208 path.add_module("TFCDC_SegmentCreatorMCTruth",
209 reconstructedDriftLength=False,
210 reconstructedPositions=True,
211
212 )
213
214 path.add_module("TFCDC_SegmentFitter",
215 inputSegments="CDCSegment2DVector",
216 updateDriftLength=False,
217
218 )
219
220 else:
221 raise ValueError("Invalid degree of Monte Carlo information")
222
223 path.add_module("TFCDC_SegmentOrienter",
224 SegmentOrientation="outwards",
225
226 inputSegments="CDCSegment2DVector",
227 segments="CDCSegment2DVectorOriented"
228 )
229
230 path.add_module("TFCDC_TrackFinderSegmentPairAutomaton",
231 inputSegments="CDCSegment2DVectorOriented",
232 WriteSegmentPairs=True,
233 SegmentPairFilter="truth",
234 SegmentPairFilterParameters={"allowReverse": True},
235 SegmentPairRelationFilter="none"
236 )
237
238 path.add_module(AxialStereoPairFitterModule(fit_method=self.get_fit_method()))
239 return path
240
241