Ejemplo n.º 1
0
def InDetMeasRecalibST(name='InDetMeasRecalibST', **kwargs):
    from TrkKalmanFitter.TrkKalmanFitterConf import Trk__MeasRecalibSteeringTool

    split_cluster_map_extension = kwargs.pop('SplitClusterMapExtension', '')

    from InDetRecExample import TrackingCommon as TrackingCommon
    if 'BroadPixelClusterOnTrackTool' not in kwargs:
        kwargs = setDefaults(
            kwargs,
            BroadPixelClusterOnTrackTool=TrackingCommon.
            getInDetBroadPixelClusterOnTrackTool(
                nameSuffix=split_cluster_map_extension,
                SplitClusterMapExtension=split_cluster_map_extension))
    if 'BroadSCT_ClusterOnTrackTool' not in kwargs:
        kwargs = setDefaults(kwargs,
                             BroadSCT_ClusterOnTrackTool=TrackingCommon.
                             getInDetBroadSCT_ClusterOnTrackTool())

    if 'CommonRotCreator' not in kwargs:
        kwargs = setDefaults(
            kwargs,
            CommonRotCreator=TrackingCommon.getInDetRefitRotCreator(
                SplitClusterMapExtension=split_cluster_map_extension))

    return Trk__MeasRecalibSteeringTool(name, **kwargs)
Ejemplo n.º 2
0
def InDetGlobalChi2FitterTRT(name='InDetGlobalChi2FitterTRT', **kwargs):
    '''
    Global Chi2 Fitter for TRT segments with different settings
    '''
    split_cluster_map_extension = kwargs.pop('SplitClusterMapExtension', '')

    if 'RotCreatorTool' not in kwargs:
        from InDetRecExample import TrackingCommon as TrackingCommon
        kwargs = setDefaults(
            kwargs,
            RotCreatorTool=TrackingCommon.getInDetRefitRotCreator(
                nameSuffix=split_cluster_map_extension,
                SplitClusterMapExtension=split_cluster_map_extension))

    from InDetRecExample.InDetJobProperties import InDetFlags
    return InDetGlobalChi2FitterBase(
        name,
        **setDefaults(
            kwargs,
            MaterialUpdateTool='',  # default
            TrackingGeometrySvc='',  # default
            SignedDriftRadius=True,  # default,
            RecalibrateSilicon=False,  # default,
            RecalibrateTRT=False,  # default,
            TRTTubeHitCut=2.5,  # default,
            MaxIterations=10,
            Acceleration=False,  # default,
            RecalculateDerivatives=False,
            TRTExtensionCuts=True,  # default,
            TrackChi2PerNDFCut=999999,
            Momentum=1000. * Units.MeV if InDetFlags.materialInteractions()
            and not InDetFlags.solenoidOn() else 0,  # default,
            OutlierCut=5,  # default
            MaxOutliers=99 if InDetFlags.doRobustReco()
            or InDetFlags.doCosmics() else 10,  # default,
            ReintegrateOutliers=False
            if InDetFlags.doRefit() else False  # default
        ))
Ejemplo n.º 3
0
def InDetKalmanTrackFitterBase(name='InDetKalmanTrackFitterBase', **kwargs):
    from InDetRecExample import TrackingCommon as TrackingCommon
    from TrkKalmanFitter.TrkKalmanFitterConf import Trk__KalmanFitter
    from AthenaCommon.AppMgr import ToolSvc
    split_cluster_map_extension = kwargs.get('SplitClusterMapExtension', '')

    kwargs.setdefault('ExtrapolatorHandle',
                      TrackingCommon.getInDetExtrapolator())
    if 'RIO_OnTrackCreatorHandle' not in kwargs:
        from InDetRecExample import TrackingCommon as TrackingCommon
        kwargs = setDefaults(
            kwargs,
            RIO_OnTrackCreatorHandle=TrackingCommon.getInDetRefitRotCreator(
                SplitClusterMapExtension=split_cluster_map_extension))

    kwargs.setdefault('MeasurementUpdatorHandle', ToolSvc.InDetUpdator)
    setTool('KalmanSmootherHandle', 'InDetBKS', kwargs)
    setTool('KalmanOutlierLogicHandle', 'InDetKOL', kwargs)
    kwargs.setdefault('DynamicNoiseAdjustorHandle', None)
    kwargs.setdefault('BrempointAnalyserHandle', None)
    kwargs.setdefault('AlignableSurfaceProviderHandle', None)
    if len(split_cluster_map_extension) > 0:
        if 'RecalibratorHandle' not in kwargs:
            the_tool_name = 'InDetMeasRecalibST'
            kwargs.setdefault(
                'RecalibratorHandle',
                CfgGetter.getPublicToolClone(
                    the_tool_name + split_cluster_map_extension,
                    the_tool_name,
                    SplitClusterMapExtension=split_cluster_map_extension))
    else:
        setTool('RecalibratorHandle', 'InDetMeasRecalibST', kwargs)
    # setTool('InternalDAFHandle','KalmanInternalDAF',kwargs )
    # from InDetRecExample.InDetJobProperties import InDetFlags
    # kwargs.setdefault('DoDNAForElectronsOnly', True if InDetFlags.doBremRecovery() and InDetFlags.trackFitterType() is 'KalmanFitter' else False)
    return Trk__KalmanFitter(name, **kwargs)