Ejemplo n.º 1
0
    def __init__(self, name = 'ConfiguredTrigL2_Extrapolator') :
        Trk__Extrapolator.__init__(self, name)
        from AthenaCommon.AppMgr import ToolSvc
        from TrkDetDescrSvc.AtlasTrackingGeometrySvc import AtlasTrackingGeometrySvc

        from IOVDbSvc.CondDB import conddb
        if not (conddb.folderRequested( "/Indet/TrkErrorScaling" ) or conddb.folderRequested( "/Indet/Onl/TrkErrorScaling" )):
            conddb.addFolderSplitOnline("INDET", "/Indet/Onl/TrkErrorScaling", "/Indet/TrkErrorScaling" )
        
        from TrkExSTEP_Propagator.TrkExSTEP_PropagatorConf import Trk__STEP_Propagator
        TrigL2_StepPropagator = Trk__STEP_Propagator(name = 'TrigL2_StepPropagator')
        ToolSvc += TrigL2_StepPropagator
        from TrkExRungeKuttaPropagator.TrkExRungeKuttaPropagatorConf import Trk__RungeKuttaPropagator
        TrigL2_RKPropagator = Trk__RungeKuttaPropagator(name = 'TrigL2_RKPropagator')
        ToolSvc += TrigL2_RKPropagator
        from InDetTrigRecExample.InDetTrigFlags import InDetTrigFlags
        if InDetTrigFlags.propagatorType() is "STEP":
            TrigL2_Propagator = TrigL2_StepPropagator
        else:
            TrigL2_Propagator = TrigL2_RKPropagator
        
        from AthenaCommon.AppMgr import ServiceMgr as svcMgr
        AtlasTrackingGeometrySvc  = svcMgr.AtlasTrackingGeometrySvc
        from TrkExTools.TrkExToolsConf import Trk__Navigator
        TrigL2_Navigator = Trk__Navigator(name = 'TrigL2_Navigator',TrackingGeometrySvc = AtlasTrackingGeometrySvc)
        ToolSvc += TrigL2_Navigator
        from TrkExTools.TrkExToolsConf import Trk__MaterialEffectsUpdator
        TrigL2_MaterialUpdator = Trk__MaterialEffectsUpdator(name = "TrigL2_MaterialEffectsUpdator")
        ToolSvc += TrigL2_MaterialUpdator
        TrigL2_SubPropagators = []
        TrigL2_SubUpdators = []
        TrigL2_SubPropagators += [ TrigL2_Propagator.name() ]
        TrigL2_SubUpdators    += [ TrigL2_MaterialUpdator.name() ]
        TrigL2_SubPropagators += [ TrigL2_Propagator.name() ]
        TrigL2_SubUpdators    += [ TrigL2_MaterialUpdator.name() ]
        TrigL2_SubPropagators += [ TrigL2_StepPropagator.name() ]
        TrigL2_SubUpdators    += [ TrigL2_MaterialUpdator.name() ]
        self.Propagators             = [ TrigL2_RKPropagator, TrigL2_StepPropagator]
        self.MaterialEffectsUpdators = [ TrigL2_MaterialUpdator ]
        self.Navigator               = TrigL2_Navigator
        self.SubPropagators          = TrigL2_SubPropagators
        self.SubMEUpdators           = TrigL2_SubUpdators
Ejemplo n.º 2
0
    def __init__(self, name='LocalExtrapolator'):

        # get the correct TrackingGeometry setup
        include('TrkDetDescrSvc/LocalTrackingGeometrySvc.py')
        from __main__ import LocalTrackingGeometrySvc
        from __main__ import ToolSvc

        # the Navigator has to get this one
        from TrkExTools.TrkExToolsConf import Trk__Navigator
        LocalNavigator = Trk__Navigator(name='LocalNavigator')
        LocalNavigator.TrackingGeometryName = LocalTrackingGeometrySvc.TrackingGeometryName
        ToolSvc += LocalNavigator

        # the standard RungeKuttaPropagator
        from TrkExRungeKuttaPropagator.TrkExRungeKuttaPropagatorConf import Trk__RungeKuttaPropagator as Propagator
        LocalPropagator = Propagator(name='LocalPropagator')
        ToolSvc += LocalPropagator
        # call the base class constructor
        Trk__Extrapolator.__init__(self,
                                   name,
                                   Navigator=LocalNavigator,
                                   Propagators=[LocalPropagator])
Ejemplo n.º 3
0
    def __init__(self,
                 name="ConfiguredDistributedKalmanFilter",
                 ExtrapTool=None,
                 ROTCreator=None):
        Trk__DistributedKalmanFilter.__init__(self, name)
        from __main__ import ToolSvc
        if ExtrapTool is None:
            from TrkExTools.TrkExToolsConf import Trk__Extrapolator
            myExtrapolator = Trk__Extrapolator()
            ToolSvc += myExtrapolator
            self.ExtrapolatorTool = myExtrapolator
        else:
            self.ExtrapolatorTool = ExtrapTool

        if ROTCreator is None:
            from TrkRIO_OnTrackCreator.TrkRIO_OnTrackCreatorConf import Trk__RIO_OnTrackCreator
            myRIO_OnTrackCreator = Trk__RIO_OnTrackCreator(name='RotCreator',
                                                           Mode='indet')
            ToolSvc += myRIO_OnTrackCreator
            self.ROTcreator = myRIO_OnTrackCreator
        else:
            self.ROTcreator = ROTCreator
InDetSubUpdators    += [ InDetMaterialUpdator.name() ]
 
# default for Calo is (Rk,MatLandau)
InDetSubPropagators += [ InDetPropagator.name() ]
InDetSubUpdators    += [ InDetMaterialUpdator.name() ]
 
# default for MS is (STEP,Mat)
InDetSubPropagators += [ InDetStepPropagator.name() ]
InDetSubUpdators    += [ InDetMaterialUpdator.name() ]
#----------------------------------------------------------------------------------------------------------            

from TrkExTools.TrkExToolsConf import Trk__Extrapolator
InDetExtrapolator = Trk__Extrapolator(name                    = 'InDetExtrapolator',
                                      Propagators             = [ InDetPropagator, InDetStepPropagator ],
                                      MaterialEffectsUpdators = [ InDetMaterialUpdator ],
                                      Navigator               = InDetNavigator,
                                      SubPropagators          = InDetSubPropagators,
                                      SubMEUpdators           = InDetSubUpdators,
                                      DoCaloDynamic           = False)
ToolSvc += InDetExtrapolator
if InDetFlags.doPrintConfigurables: print      InDetExtrapolator  


# LEVEL 4

from InDetAssociationTools.InDetAssociationToolsConf import InDet__InDetPRD_AssociationToolGangedPixels
InDetPrdAssociationTool = InDet__InDetPRD_AssociationToolGangedPixels(name                           = "InDetPrdAssociationTool",
                                                                      PixelClusterAmbiguitiesMapName = InDetKeys.GangedPixelMap())
ToolSvc += InDetPrdAssociationTool
if InDetFlags.doPrintConfigurables: print      InDetPrdAssociationTool
  
Ejemplo n.º 5
0
TestSubPropagators += [TestSTEP_Propagator.name()]
TestSubUpdators += [TestMaterialEffectsUpdator.name()]

TestSubPropagators += [TestSTEP_Propagator.name()]
TestSubUpdators += [TestMaterialEffectsUpdator.name()]

TestSubPropagators += [TestPropagator.name()]
TestSubUpdators += [TestMaterialEffectsUpdator.name()]
# ----------------------------------------------------------------------------------------------------------

# call the base class constructor
from TrkExTools.TrkExToolsConf import Trk__Extrapolator
TestExtrapolator = Trk__Extrapolator('TestExtrapolator',\
                           Navigator = TestNavigator,\
                           MaterialEffectsUpdators = TestUpdators,\
                           Propagators = TestPropagators,\
                           EnergyLossUpdators = TestEnergyLossUpdator,\
                           STEP_Propagator = TestSTEP_Propagator.name(),\
                           SubPropagators = TestSubPropagators,\
                           SubMEUpdators = TestSubUpdators)
ToolSvc += TestExtrapolator

from TrkG4UserActions.TrkG4UserActionsConf import Trk__GeantFollowerHelper
GeantFollowerHelper = Trk__GeantFollowerHelper(name="GeantFollowerHelper")
GeantFollowerHelper.Extrapolator = TestExtrapolator
GeantFollowerHelper.ExtrapolateDirectly = True
GeantFollowerHelper.ExtrapolateIncrementally = True
GeantFollowerHelper.OutputLevel = VERBOSE
ToolSvc += GeantFollowerHelper

SimFlags.OptionalUserActionList.addAction('G4UA::GeantFollowerTool',
                                          ['Step', 'Event', 'Run'])
Ejemplo n.º 6
0
    def __init__(self,
                 instname='InDetAlignTrackSelTool',
                 propagatorType='RungeKutta'):

        # Load the Dlls
        if 'InDetAlignGenTools' not in theApp.Dlls:
            theApp.Dlls += ['InDetAlignGenTools']

        # Set names
        self.__instname__ = instname
        self.__svcname__ = 'InDetAlignTrackSelTool'

        self.__toolname__ = 'ToolSvc.' + self.__instname__
        self.__thistool__ = Service(self.__toolname__)

        # Set options for tool
        self.__thistool__.MinMomentum = 0
        self.__thistool__.MinPt = 2
        self.__thistool__.MaxShared = 0
        self.__thistool__.MaxHoles = 1
        self.__thistool__.MinChi2Prob = 0.2

        ToolSvc = Service("ToolSvc")

        # Propagator
        if propagatorType is "STEP":
            from TrkExSTEP_Propagator.TrkExSTEP_PropagatorConf import Trk__STEP_Propagator as Propagator
        else:
            from TrkExRungeKuttaPropagator.TrkExRungeKuttaPropagatorConf import Trk__RungeKuttaPropagator as Propagator
        InDetAlignTrackSelPropagator = Propagator(
            name='InDetAlignTrackSelPropagator')
        ToolSvc += InDetAlignTrackSelPropagator
        print InDetAlignTrackSelPropagator

        # Navigator
        from TrkExTools.TrkExToolsConf import Trk__Navigator
        InDetAlignTrackSelNavigator = Trk__Navigator(
            name='InDetAlignTrackSelNavigator')
        ToolSvc += InDetAlignTrackSelNavigator
        print InDetAlignTrackSelNavigator

        # Material updator
        from TrkExTools.TrkExToolsConf import Trk__MaterialEffectsUpdator
        InDetAlignTrackSelMaterialUpdator = Trk__MaterialEffectsUpdator(
            name="InDetAlignTrackSelMaterialEffectsUpdator")
        ToolSvc += InDetAlignTrackSelMaterialUpdator
        print InDetAlignTrackSelMaterialUpdator

        # Extrapolator
        from TrkExTools.TrkExToolsConf import Trk__Extrapolator
        InDetAlignTrackSelExtrapolator = Trk__Extrapolator(
            name='InDetAlignTrackSelExtrapolator',
            Propagators=[InDetAlignTrackSelPropagator.getType()],
            PropagatorInstances=[InDetAlignTrackSelPropagator.getName()],
            Navigator=InDetAlignTrackSelNavigator,
            MaterialEffectsUpdator=InDetAlignTrackSelMaterialUpdator)
        ToolSvc += InDetAlignTrackSelExtrapolator
        print InDetAlignTrackSelExtrapolator

        # associator
        from InDetAssociationTools.InDetAssociationToolsConf import InDet__InDetPRD_AssociationToolGangedPixels
        InDetAlignTrackSelAssociationTool = InDet__InDetPRD_AssociationToolGangedPixels(
        )
        ToolSvc += InDetAlignTrackSelAssociationTool

        # summary
        from InDetTrackSummaryHelperTool.InDetTrackSummaryHelperToolConf import InDet__InDetTrackSummaryHelperTool
        InDetAlignTrackSelSummaryTool = InDet__InDetTrackSummaryHelperTool(
            name="InDetAlignTrackSelSummaryTool",
            Extrapolator=InDetAlignTrackSelExtrapolator,
            AssoTool=InDetAlignTrackSelAssociationTool,
            DoSharedHits=True)
        ToolSvc += InDetAlignTrackSelSummaryTool
        print InDetAlignTrackSelSummaryTool
Ejemplo n.º 7
0
theApp.Dlls += ["InDetAlignGenAlgs", "InDetAlignGenTools"]
from InDetAlignGenAlgs.InDetAlignGenAlgsConf import InDetAlignNt
AlignNt = InDetAlignNt(Truth=False,
                       Overlap=False,
                       NumDeriv=0,
                       AlignNt=True,
                       BeamPos=False,
                       ReadAl=True,
                       OutputLevel=3)
topSequence += AlignNt

# setup extrapolator/propagator instance specially for InDetAlignNt
# InDetAlignNt expects to find one with name InDetAlignNtExtrap
from TrkExRungeKuttaPropagator.TrkExRungeKuttaPropagatorConf import Trk__RungeKuttaPropagator as Propagator
InDetAlignNtPropag = Propagator(name='InDetAlignNtPropag')
ToolSvc += InDetAlignNtPropag
from TrkExTools.TrkExToolsConf import Trk__Extrapolator
InDetAlignNtExtrap = Trk__Extrapolator(name='InDetAlignNtExtrap',
                                       Propagators=[InDetAlignNtPropag])
ToolSvc += InDetAlignNtExtrap
print "Extrapolator for InDetAlignNt is", InDetAlignNtExtrap
AlignNt.NewTrkCol = "InDetCosmic_Tracks"

# include this to write alignment constants (use with care and edit WriteDBS.py
# beforehand to set your server/IOV/tag options
# include("InDetAlignGenAlgs/WriteDBS.py")

# produce ROOT ntuple using THistSvc
THistSvc = Service("THistSvc")
THistSvc.Output += ["IDALIGNFILE DATAFILE='idalign.root' OPT='RECREATE'"]
Ejemplo n.º 8
0
# job option fragment to enable InDetAlignNt for combined testbeam geometry
# in framework of RecExTB
# enables alignment ntuple production for InDetTB_Tracks (produced by
# straightline fitter)
#
theApp.Dlls += ["InDetAlignGenAlgs", "InDetAlignGenTools"]
theApp.TopAlg += ["InDetAlignNt"]
InDetAlignNt = Algorithm("InDetAlignNt")
InDetAlignNt.ReadAl = TRUE
InDetAlignNt.TRT = 1
InDetAlignNt.layout = 11
InDetAlignNt.truth = FALSE
InDetAlignNt.newtrk = True
InDetAlignNt.newtrkcol = "InDetTB_Tracks"

# setup extrapolator/propagator instance
from TrkExRungeKuttaPropagator.TrkExRungeKuttaPropagatorConf import Trk__RungeKuttaPropagator as Propagator
InDetAlignNtPropag = Propagator(name='InDetAlignNtPropag')
ToolSvc += InDetAlignNtPropag
from TrkExTools.TrkExToolsConf import Trk__Extrapolator
InDetAlignNtExtrap = Trk__Extrapolator(
    name='InDetAlignNtExtrap',
    Propagators=[InDetAlignNtPropag.getType()],
    PropagatorInstances=[InDetAlignNtPropag.getName()])
ToolSvc += InDetAlignNtExtrap
InDetAlignNt.Extrapolator = InDetAlignNtExtrap
Ejemplo n.º 9
0
LocalMaterialUpdator = Trk__MaterialEffectsUpdator(
    name="LocalMaterialEffectsUpdator")
ToolSvc += LocalMaterialUpdator
print LocalMaterialUpdator
#
# set the propagator
#
from TrkExRungeKuttaPropagator.TrkExRungeKuttaPropagatorConf import Trk__RungeKuttaPropagator as Propagator

LocalPropagator = Propagator(name='LocalPropagator')
ToolSvc += LocalPropagator
print LocalPropagator
#
# create extrapolator
#
from TrkExTools.TrkExToolsConf import Trk__Extrapolator

LocalExtrapolator = Trk__Extrapolator(
    name='LocalExtrapolator',
    Propagators=[LocalPropagator],
    Navigator=LocalNavigator,
    MaterialEffectsUpdator=LocalMaterialUpdator)
ToolSvc += LocalExtrapolator
print LocalExtrapolator
print 'Finished setting up default LocalExtrapolator'

#LocalExtrapolatorOutputLevel(1)

ToolSvc.LocalMaterialUpdator.ReferenceMaterial = True
ToolSvc.LocalMaterialUpdator.ValidationMode = False
ToolSvc.LocalMaterialUpdator.ValidationDirection = -1
Ejemplo n.º 10
0
MuonTGMaterialUpdator = Trk__MaterialEffectsUpdator( name = "MuonTGMaterialUpdator"
                                                   )
ToolSvc += MuonTGMaterialUpdator
print MuonTGMaterialUpdator
 
from TrkExSTEP_Propagator.TrkExSTEP_PropagatorConf import Trk__STEP_Propagator
MuonTGPropagator = Trk__STEP_Propagator( name = 'MuonTGPropagator' ,Tolerance=0.0001, MaterialEffects=True,IncludeBgradients=False)
ToolSvc += MuonTGPropagator
print      MuonTGPropagator

 
# assign it to the Extrapolator
from TrkExTools.TrkExToolsConf import Trk__Extrapolator
MuonTGExtrapolator = Trk__Extrapolator( name = 'MuonTGExtrapolator', 
                                      Propagators = [ MuonTGPropagator ],
                                      Navigator = MuonTGNavigator,
                                      MaterialEffectsUpdators = [ MuonTGMaterialUpdator ]
                                      )
ToolSvc += MuonTGExtrapolator
print MuonTGExtrapolator                          

# load MuonHolesOnTrackTool 
from MuonTGRecTools.MuonTGRecToolsConf import Muon__MuonHolesOnTrackTool
MuonHolesOnTrackTool = Muon__MuonHolesOnTrackTool( name= 'MuonHolesOnTrackTool',
                                                   ExtrapolatorName = MuonTGExtrapolator,
                                                   TrackingGeometryName = 'MuonStandaloneTrackingGeometry') 
ToolSvc += MuonHolesOnTrackTool

#
doMuonOutliers = False
if ( doMuonOutliers ) :
Ejemplo n.º 11
0
    ToolSvc += iPatPropagator

    from TrkExTools.TrkExToolsConf import Trk__Navigator
    iPatNavigator = Trk__Navigator(
        name='iPatNavigator', TrackingGeometrySvc=AtlasTrackingGeometrySvc)
    ToolSvc += iPatNavigator

    from TrkExTools.TrkExToolsConf import Trk__MaterialEffectsUpdator
    iPatMaterialUpdator = Trk__MaterialEffectsUpdator(
        name="iPatMaterialEffectsUpdator")
    ToolSvc += iPatMaterialUpdator

    from TrkExTools.TrkExToolsConf import Trk__Extrapolator
    iPatExtrapolator = Trk__Extrapolator(
        name='iPatExtrapolator',
        MaterialEffectsUpdators=[iPatMaterialUpdator],
        Propagators=[iPatPropagator],
        Navigator=iPatNavigator,
        Tolerance=0.0011)
    ToolSvc += iPatExtrapolator

    from TrkiPatFitter.TrkiPatFitterConf import Trk__MaterialAllocator
    iPatMaterialAllocator = Trk__MaterialAllocator(
        name='iPatMaterialAllocator',
        #AggregateMaterial         = True,
        Extrapolator=iPatExtrapolator,
        SpectrometerExtrapolator="",
        TrackingGeometrySvc=ServiceMgr.AtlasTrackingGeometrySvc)
    ToolSvc += iPatMaterialAllocator

    from TrkiPatFitter.TrkiPatFitterConf import Trk__iPatFitter
    iPatRecFitter = Trk__iPatFitter(name='iPatRecFitter',
Ejemplo n.º 12
0
    def set_iPatFitter(self):
        from AthenaCommon.AppMgr import ToolSvc
        from MuonRecExample import MuonRecTools
        MuonExtrapolator = MuonRecTools.getPublicTool('MuonExtrapolator')

        from AthenaCommon.Include import include
        include('TrkDetDescrSvc/AtlasTrackingGeometrySvc.py')

        # set up the extrapolator and fitter as used by Muid
        from TrkExRungeKuttaIntersector.TrkExRungeKuttaIntersectorConf import \
            Trk__IntersectorWrapper as Propagator
        MuidPropagator = Propagator(name='MuidPropagator')
        ToolSvc += MuidPropagator

        from TrkExTools.TrkExToolsConf import Trk__MaterialEffectsUpdator
        MuidMaterialUpdator = Trk__MaterialEffectsUpdator(
            name="MuidMaterialEffectsUpdator")
        ToolSvc += MuidMaterialUpdator

        from AthenaCommon.AppMgr import ServiceMgr as svcMgr
        from TrkExTools.TrkExToolsConf import Trk__Navigator
        MuidNavigator = Trk__Navigator(
            name='MuidNavigator',
            TrackingGeometrySvc=svcMgr.AtlasTrackingGeometrySvc)
        ToolSvc += MuidNavigator

        from TrkExTools.TrkExToolsConf import Trk__Extrapolator
        MuidExtrapolator = Trk__Extrapolator(
            name='MuidExtrapolator',
            Propagators=[MuidPropagator],
            MaterialEffectsUpdators=[MuidMaterialUpdator],
            Navigator=MuidNavigator)
        ToolSvc += MuidExtrapolator

        # material allocation
        from TrkiPatFitter.TrkiPatFitterConf import Trk__MaterialAllocator
        MuidMaterialAllocator = Trk__MaterialAllocator(
            name='MuidMaterialAllocator',
            AggregateMaterial=True,
            Extrapolator=MuidExtrapolator,
            TrackingGeometrySvc=svcMgr.AtlasTrackingGeometrySvc)
        ToolSvc += MuidMaterialAllocator

        from TrkiPatFitter.TrkiPatFitterConf import Trk__iPatGlobalFitter
        Fitter = Trk__iPatGlobalFitter(
            name='iPatGlobalFitter',
            #from TrkiPatFitter.TrkiPatFitterConf import Trk__iPatFitter
            #Fitter = Trk__iPatFitter(
            #    name='iPatFitter',
            AggregateMaterial=True,
            AsymmetricCaloEnergy=False,
            FullCombinedFit=True,
            MaterialAllocator=MuidMaterialAllocator,
            OutputLevel=align.OutputLevel())
        #OutputLevel = VERBOSE)

        ToolSvc += Fitter
        self._fitter = ToolSvc.iPatGlobalFitter
        #self._fitter = ToolSvc.iPatFitter

        if align.useSLFitter():
            SLFitter = Trk__iPatGlobalFitter(
                name='iPatGlobalSLFitter',
                #SLFitter = Trk__iPatFitter(
                #    name                    = 'iPatSLFitter',
                AggregateMaterial=True,
                FullCombinedFit=True,
                LineFit=True,
                MaterialAllocator=MuidMaterialAllocator,
                OutputLevel=align.OutputLevel())
            ToolSvc += SLFitter
            self._slfitter = ToolSvc.iPatGlobalSLFitter
# the output file
OutputFilePath = ''
OutputFileName = OutputFilePath+'MaterialValidation-'
if doFatrasGeometry :
   OutputFileName = OutputFilePath+'FatrasMaterialValidation-'
ServiceMgr.THistSvc.Output = [ "val DATAFILE='"+OutputFileName+DetVerName+".root' TYPE='ROOT' OPT='RECREATE'"] 

# The standard material effects updator
from TrkExSlPropagator.TrkExSlPropagatorConf import Trk__StraightLinePropagator
ValidationPropagator = Trk__StraightLinePropagator(name='ValidationPropagator')
ToolSvc += ValidationPropagator

# Extrapolator 
from TrkExTools.TrkExToolsConf import Trk__Extrapolator
ValidationExtrapolator         = Trk__Extrapolator(name='ValidationExtrapolator')
ValidationExtrapolator.MaterialEffectsUpdators =  [ ValidationMaterialUpdator ]
ValidationExtrapolator.Navigator               =  ValidationNavigator
ValidationExtrapolator.Propagators             =  [ ValidationPropagator ]
ValidationExtrapolator.StopWithNavigationBreak         = True
ValidationExtrapolator.DetailedNavigationOutput        = True
ValidationExtrapolator.OutputLevel                     = INFO
ToolSvc += ValidationExtrapolator

###############################################################
from TrkDetDescrAlgs.TrkDetDescrAlgsConf import Trk__MaterialValidation

MaterialValidation = Trk__MaterialValidation(name='MaterialValidation')
MaterialValidation.Extrapolator              = ValidationExtrapolator
MaterialValidation.StartPerigeeSigmaD0       = 0.
MaterialValidation.StartPerigeeSigmaZ0       = 0.
Ejemplo n.º 14
0
AtlasSubUpdators = []

# -------------------- set it depending on the geometry ----------------------------------------------------
# default for ID is (Rk,Mat)
AtlasSubPropagators += [ AtlasRungeKuttaPropagator.name() ]
AtlasSubUpdators    += [ AtlasMaterialEffectsUpdator.name() ]

# default for Calo is (Rk,MatLandau)
AtlasSubPropagators += [ AtlasRungeKuttaPropagator.name() ]
AtlasSubUpdators    += [ AtlasMaterialEffectsUpdatorLandau.name() ]

# default for MS is (STEP,Mat)
AtlasSubPropagators += [ AtlasSTEP_Propagator.name() ]
AtlasSubUpdators    += [ AtlasMaterialEffectsUpdator.name() ]
# ----------------------------------------------------------------------------------------------------------
          
# the Extrapolator
from TrkExTools.TrkExToolsConf import Trk__Extrapolator
CombinedExtrapolator = Trk__Extrapolator( name = 'CombinedExtrapolator', 
                                          Navigator = CombinedNavigator,
                                          MaterialEffectsUpdators = AtlasUpdators,
                                          Propagators = AtlasPropagators,
                                          SubPropagators = AtlasSubPropagators,
                                          SubMEUpdators = AtlasSubUpdators 
                                          )
ToolSvc += CombinedExtrapolator
print CombinedExtrapolator

print 'Finished setting up CombinedExtrapolator'

Ejemplo n.º 15
0
ElectronTrkSubPropagators += [ElectronTrkPropagator.name()]
ElectronTrkSubUpdators += [ElectronTrkMaterialUpdator.name()]

# default for MS is (STEP,Mat)
ElectronTrkSubPropagators += [ElectronTrkStepPropagator.name()]
ElectronTrkSubUpdators += [ElectronTrkMaterialUpdator.name()]
# ----------------------------------------------------------------------------------------------------------

#
# set up extrapolator
#
from TrkExTools.TrkExToolsConf import Trk__Extrapolator
ElectronTrkExtrapolator = Trk__Extrapolator(
    name='ElectronTrkExtrapolator',
    Propagators=[ElectronTrkPropagator, ElectronTrkStepPropagator],
    MaterialEffectsUpdators=[ElectronTrkMaterialUpdator],
    Navigator=ElectronTrkNavigator,
    SubPropagators=ElectronTrkSubPropagators,
    SubMEUpdators=ElectronTrkSubUpdators,
    DoCaloDynamic=False)
ToolSvc += ElectronTrkExtrapolator

###############################################################################
###############################################################################
#######                     GSF Realted Packaages                      ########
###############################################################################
###############################################################################

from TrkGaussianSumFilter.TrkGaussianSumFilterConf import Trk__GsfMaterialMixtureConvolution
GsfMaterialUpdator = Trk__GsfMaterialMixtureConvolution(
    name='GsfMaterialUpdator')
ToolSvc += GsfMaterialUpdator
Ejemplo n.º 16
0
    def __init__(self, name='AtlasExtrapolator'):

        # get the correct TrackingGeometry setup
        from TrkDetDescrSvc.AtlasTrackingGeometrySvc import AtlasTrackingGeometrySvc
        from AthenaCommon.AppMgr import ServiceMgr as svcMgr
        AtlasTrackingGeometrySvc = svcMgr.AtlasTrackingGeometrySvc

        # import the ToolSvc
        from AthenaCommon.AppMgr import ToolSvc
        if 'ToolSvc' not in dir():
            ToolSvc = ToolSvc()

        # PROPAGATOR DEFAULTS --------------------------------------------------------------------------------------

        self.AtlasPropagators = []

        from TrkExRungeKuttaPropagator.TrkExRungeKuttaPropagatorConf import Trk__RungeKuttaPropagator as RkPropagator
        AtlasRungeKuttaPropagator = RkPropagator(
            name='AtlasRungeKuttaPropagator')
        ToolSvc += AtlasRungeKuttaPropagator

        self.AtlasPropagators += [AtlasRungeKuttaPropagator]

        from TrkExSTEP_Propagator.TrkExSTEP_PropagatorConf import Trk__STEP_Propagator as STEP_Propagator
        AtlasSTEP_Propagator = STEP_Propagator(name='AtlasSTEP_Propagator')
        ToolSvc += AtlasSTEP_Propagator

        self.AtlasPropagators += [AtlasSTEP_Propagator]

        # UPDATOR DEFAULTS -----------------------------------------------------------------------------------------

        self.AtlasUpdators = []

        from TrkExTools.TrkExToolsConf import Trk__MaterialEffectsUpdator as MaterialEffectsUpdator
        AtlasMaterialEffectsUpdator = MaterialEffectsUpdator(
            name='AtlasMaterialEffectsUpdator')
        ToolSvc += AtlasMaterialEffectsUpdator

        self.AtlasUpdators += [AtlasMaterialEffectsUpdator]

        AtlasMaterialEffectsUpdatorLandau = MaterialEffectsUpdator(
            name='AtlasMaterialEffectsUpdatorLandau')
        AtlasMaterialEffectsUpdatorLandau.LandauMode = True
        ToolSvc += AtlasMaterialEffectsUpdatorLandau

        self.AtlasUpdators += [AtlasMaterialEffectsUpdatorLandau]

        # the UNIQUE NAVIGATOR ( === UNIQUE GEOMETRY) --------------------------------------------------------------
        from TrkExTools.TrkExToolsConf import Trk__Navigator
        AtlasNavigator = Trk__Navigator(name='AtlasNavigator')
        AtlasNavigator.TrackingGeometrySvc = AtlasTrackingGeometrySvc
        ToolSvc += AtlasNavigator

        # CONFIGURE PROPAGATORS/UPDATORS ACCORDING TO GEOMETRY SIGNATURE

        AtlasSubPropagators = []
        AtlasSubUpdators = []

        # -------------------- set it depending on the geometry ----------------------------------------------------
        # default for Global is (Rk,Mat)
        AtlasSubPropagators += [AtlasRungeKuttaPropagator.name()]
        AtlasSubUpdators += [AtlasMaterialEffectsUpdator.name()]

        # default for ID is (Rk,Mat)
        AtlasSubPropagators += [AtlasRungeKuttaPropagator.name()]
        AtlasSubUpdators += [AtlasMaterialEffectsUpdator.name()]

        # default for BeamPipe is (Rk,Mat)
        AtlasSubPropagators += [AtlasRungeKuttaPropagator.name()]
        AtlasSubUpdators += [AtlasMaterialEffectsUpdator.name()]

        # default for Calo is (STEP,Mat)
        AtlasSubPropagators += [AtlasSTEP_Propagator.name()]
        AtlasSubUpdators += [AtlasMaterialEffectsUpdator.name()]

        # default for MS is (STEP,Mat)
        AtlasSubPropagators += [AtlasSTEP_Propagator.name()]
        AtlasSubUpdators += [AtlasMaterialEffectsUpdator.name()]

        # default for Cavern is (Rk,Mat)
        AtlasSubPropagators += [AtlasRungeKuttaPropagator.name()]
        AtlasSubUpdators += [AtlasMaterialEffectsUpdator.name()]

        # ----------------------------------------------------------------------------------------------------------

        # call the base class constructor
        Trk__Extrapolator.__init__(self,name,\
                                   Navigator = AtlasNavigator,\
                                   MaterialEffectsUpdators = self.AtlasUpdators,\
                                   Propagators = self.AtlasPropagators,\
                                   SubPropagators = AtlasSubPropagators,\
                                   SubMEUpdators = AtlasSubUpdators,\
                                   DoCaloDynamic = False
                                   )
Ejemplo n.º 17
0
egTrkSubPropagators += [egTrkPropagator.name()]
egTrkSubUpdators += [egTrkMaterialUpdator.name()]
# default for Calo is (Rk,MatLandau)
egTrkSubPropagators += [egTrkPropagator.name()]
egTrkSubUpdators += [egTrkMaterialUpdator.name()]
# default for MS is (STEP,Mat)
egTrkSubPropagators += [egTrkStepPropagator.name()]
egTrkSubUpdators += [egTrkMaterialUpdator.name()]
# ----------------------------------------------------------------------------------------------------------
# set up extrapolator to be used by egamma during tracking / vertexing operations
from TrkExTools.TrkExToolsConf import Trk__Extrapolator

egTrkExtrapolator = Trk__Extrapolator(
    name='egTrkExtrapolator',
    Propagators=[egTrkPropagator, egTrkStepPropagator],
    MaterialEffectsUpdators=[egTrkMaterialUpdator],
    Navigator=egTrkNavigator,
    SubPropagators=egTrkSubPropagators,
    SubMEUpdators=egTrkSubUpdators)
ToolSvc += egTrkExtrapolator
#
###############################################################################
# Set up the GSF
from TrkGaussianSumFilter.TrkGaussianSumFilterConf import Trk__GsfMaterialMixtureConvolution

GsfMaterialUpdator = Trk__GsfMaterialMixtureConvolution(
    name='GsfMaterialUpdator')
ToolSvc += GsfMaterialUpdator
# component Reduction
from TrkGaussianSumFilter.TrkGaussianSumFilterConf import Trk__QuickCloseComponentsMultiStateMerger
Ejemplo n.º 18
0
FatrasMaterialUpdator.HadronicInteractionProcessor = FatrasHadIntProcessor
ToolSvc += FatrasMaterialUpdator
# energy loss
FatrasMaterialUpdator.EnergyLoss = True
FatrasMaterialUpdator.EnergyLossUpdator = FatrasEnergyLossUpdator
# mutiple scattering
FatrasMaterialUpdator.MultipleScattering = True
FatrasMaterialUpdator.MultipleScatteringUpdator = FatrasMultipleScatteringUpdator
# the validation output
# the sim propagator
FatrasPropagator = Propagator('FatrasPropagatorID')
ToolSvc += FatrasPropagator
FatrasSTEP_Propagator = STEP_Propagator('FatrasSTEP_PropagatorID')
ToolSvc += FatrasSTEP_Propagator
# Extrapolator for fatras
FatrasExtrapolator = Extrapolator(name='FatrasExtrapolatorID')
# assign the tools
FatrasExtrapolator.Navigator = FatrasNavigator
FatrasExtrapolator.MaterialEffectsUpdators = [FatrasMaterialUpdator]
FatrasExtrapolator.Propagators = [FatrasPropagator]
FatrasExtrapolator.STEP_Propagator = FatrasSTEP_Propagator
ToolSvc += FatrasExtrapolator

################################################################
# load the AtlasExtrapolator

from TrkExTools.AtlasExtrapolator import AtlasExtrapolator
MyExtrapolator = AtlasExtrapolator(name='TestExtrapolator')
MyExtrapolator.NavigationStatisticsOutput = True
MyExtrapolator.OutputLevel = INFO
MyExtrapolator.StopWithNavigationBreak = True