def __init__(self, name="SiTrigSpacePointFinder_Electron_EF", type="electron", lowPt=False): super(InDet__SiTrigSpacePointFinder, self).__init__(name) from AthenaCommon.AppMgr import ToolSvc from InDetTrigRecExample.InDetTrigConfigRecLoadTools import \ InDetTrigSiSpacePointMakerTool,SCT_TrigSpacePointTool from InDetTrigRecExample.InDetTrigFlags import InDetTrigFlags if (InDetTrigFlags.doPrintConfigurables()): print(SCT_TrigSpacePointTool) ToolSvc += SCT_TrigSpacePointTool # Condition algorithm for SiTrigSpacePointFinder from AthenaCommon.AlgSequence import AthSequencer condSeq = AthSequencer("AthCondSeq") if not hasattr(condSeq, "InDetSiElementPropertiesTableCondAlg"): from SiSpacePointFormation.SiSpacePointFormationConf import InDet__SiElementPropertiesTableCondAlg condSeq += InDet__SiElementPropertiesTableCondAlg( name="InDetSiElementPropertiesTableCondAlg") self.SiSpacePointMakerTool = InDetTrigSiSpacePointMakerTool self.SCTSpacePointTrigHelperTool = SCT_TrigSpacePointTool self.ProcessPixels = True self.ProcessSCTs = True self.ProcessOverlaps = InDetTrigFlags.doOverlapSP() if type == 'cosmicsN': from InDetTrigRecExample.InDetTrigConfigRecLoadToolsCosmics import \ InDetTrigSiSpacePointMakerToolCosmics, SCT_TrigSpacePointToolCosmics self.SiSpacePointMakerTool = InDetTrigSiSpacePointMakerToolCosmics self.SCTSpacePointTrigHelperTool = SCT_TrigSpacePointToolCosmics self.SpacePointsSCTName = "SCT_CosmicsTrigSpacePoints" self.SpacePointsPixelName = "PixelCosmicsTrigSpacePoints" from InDetTrigRecExample.InDetTrigSliceSettings import InDetTrigSliceSettings self.EtaHalfWidth = InDetTrigSliceSettings[('etaHalfWidth', type)] self.PhiHalfWidth = InDetTrigSliceSettings[('phiHalfWidth', type)] self.doFullScan = InDetTrigSliceSettings[('doFullScan', type)] #monitoring from SiTrigSpacePointFormation.SiTrigSpacePointFormatMonitoring import SiTrigSpacePointFormatValidationMonitor from SiTrigSpacePointFormation.SiTrigSpacePointFormatMonitoring import SiTrigSpacePointFormatOnlineMonitor from TrigTimeMonitor.TrigTimeHistToolConfig import TrigTimeHistToolConfig sitime = TrigTimeHistToolConfig("SiTime") sitime.TimerHistLimits = [0, 50] self.AthenaMonTools = [ SiTrigSpacePointFormatValidationMonitor(type=type), SiTrigSpacePointFormatOnlineMonitor(type=type), sitime ]
def __init__(self, name="SiTrigTrackFinder_Electron_EF", type="electron", lowPt=False): super(InDet__SiTrigSPSeededTrackFinder, self).__init__(name) from InDetTrigRecExample.InDetTrigConfigRecLoadTools import InDetTrigPrdAssociationTool, \ InDetTrigPatternPropagator, InDetTrigPatternUpdator, \ InDetTrigRotCreator, InDetTrigPixelConditionsSummarySvc, InDetTrigSCTConditionsSummarySvc from AthenaCommon.AppMgr import ToolSvc # configure tools used # Space points seeds maker # from InDetTrigRecExample.InDetTrigSliceSettings import InDetTrigSliceSettings from AthenaCommon.DetFlags import DetFlags if type == "beamgas": from InDetTrigRecExample.InDetTrigConfigRecLoadToolsBeamGas import InDetTrigSiSpacePointsSeedMakerBeamGas InDetTrigSiSpacePointsSeedMaker = InDetTrigSiSpacePointsSeedMakerBeamGas elif type == "cosmicsN": from SiSpacePointsSeedTool_xk.SiSpacePointsSeedTool_xkConf import InDet__SiSpacePointsSeedMaker_Cosmic InDetTrigSiSpacePointsSeedMaker = \ InDet__SiSpacePointsSeedMaker_Cosmic(name = 'InDetTrigSiSpacePointsSeedMaker_'+type, pTmin = InDetTrigSliceSettings[('pTmin',type)], maxdImpact = EFIDTrackingCutsCosmics.maxPrimaryImpact(), maxZ = EFIDTrackingCutsCosmics.maxZImpact(), minZ = -EFIDTrackingCutsCosmics.maxZImpact(), SpacePointsPixelName = 'SCT_CosmicsTrigSpacePoints', SpacePointsSCTName = 'PixelCosmicsTrigSpacePoints', #SpacePointsOverlapName = InDetKeys.OverlapSpacePoints(), UseAssociationTool = False, AssociationTool = InDetTrigPrdAssociationTool) elif lowPt: from InDetTrigRecExample.InDetTrigConfigRecLoadToolsLowPt import InDetTrigSiSpacePointsSeedMakerLowPt InDetTrigSiSpacePointsSeedMaker = InDetTrigSiSpacePointsSeedMakerLowPt elif type == "heavyIon" or type == "heavyIonFS": from SiSpacePointsSeedTool_xk.SiSpacePointsSeedTool_xkConf import InDet__SiSpacePointsSeedMaker_HeavyIon InDetTrigSiSpacePointsSeedMaker = \ InDet__SiSpacePointsSeedMaker_HeavyIon(name= 'InDetTrigSiSpacePointsSeedMaker_'+type, pTmin = InDetTrigSliceSettings[('pTmin',type)], maxdImpact = EFIDTrackingCutsHeavyIon.maxPrimaryImpact(), maxZ = EFIDTrackingCutsHeavyIon.maxZImpact(), minZ = -EFIDTrackingCutsHeavyIon.maxZImpact(), #useOverlapSpCollection = False, #overlapCollections not used in EFID useOverlapSpCollection = InDetTrigFlags.doOverlapSP(), #testing usePixel = DetFlags.haveRIO.pixel_on(), useSCT = DetFlags.haveRIO.SCT_on(), SpacePointsSCTName = 'SCT_TrigSpacePoints', SpacePointsPixelName = 'PixelTrigSpacePoints', SpacePointsOverlapName = 'SPTrigOverlap', radMax = EFIDTrackingCutsHeavyIon.radMax()) else: from SiSpacePointsSeedTool_xk.SiSpacePointsSeedTool_xkConf import InDet__SiSpacePointsSeedMaker_ATLxk InDetTrigSiSpacePointsSeedMaker = \ InDet__SiSpacePointsSeedMaker_ATLxk( name = 'InDetTrigSiSpacePointsSeedMaker_'+type, pTmin = InDetTrigSliceSettings[('pTmin',type)], maxdImpact = InDetTrigCutValues.maxPrimaryImpact(), maxZ = InDetTrigCutValues.maxZImpact(), minZ = -InDetTrigCutValues.maxZImpact(), #useOverlapSpCollection = False, #overlapCollections not used in EFID useOverlapSpCollection = InDetTrigFlags.doOverlapSP(), #testing usePixel = DetFlags.haveRIO.pixel_on(), useSCT = DetFlags.haveRIO.SCT_on(), SpacePointsSCTName = 'SCT_TrigSpacePoints', SpacePointsPixelName = 'PixelTrigSpacePoints', SpacePointsOverlapName = 'SPTrigOverlap', radMax = InDetTrigCutValues.radMax(), maxdImpactPPS = InDetTrigCutValues.maxdImpactPPSSeeds(), maxdImpactSSS = InDetTrigCutValues.maxdImpactSSSSeeds(), ) if type != "cosmicsN": InDetTrigSiSpacePointsSeedMaker.maxRadius1 = 0.75 * InDetTrigCutValues.radMax( ) InDetTrigSiSpacePointsSeedMaker.maxRadius2 = InDetTrigCutValues.radMax( ) InDetTrigSiSpacePointsSeedMaker.maxRadius3 = InDetTrigCutValues.radMax( ) # if type=="minBias": # InDetTrigSiSpacePointsSeedMaker.maxdImpact=5. ToolSvc += InDetTrigSiSpacePointsSeedMaker if (InDetTrigFlags.doPrintConfigurables()): print InDetTrigSiSpacePointsSeedMaker #InDetTrigSiSpacePointsSeedMaker.OutputLevel = 1 # Z-coordinates primary vertices finder # from SiZvertexTool_xk.SiZvertexTool_xkConf import InDet__SiZvertexMaker_xk InDetTrigZvertexMaker = InDet__SiZvertexMaker_xk( name='InDetTrigZvertexMaker_' + type, Zmax=InDetTrigCutValues.maxZImpact(), Zmin=-InDetTrigCutValues.maxZImpact(), minRatio=0.17 # not default ) if type == "heavyIon" or type == "heavyIonFS": InDetTrigZvertexMaker.HistSize = 2000 InDetTrigZvertexMaker.minContent = 30 #InDetTrigZvertexMaker.SeedMakerTool = InDet__SiSpacePointsSeedMaker_ATLxk('InDetTrigSiSpacePointsSeedMaker_'+type)#to make it tool neutral InDetTrigZvertexMaker.SeedMakerTool = ToolSvc.allConfigurables[ 'InDetTrigSiSpacePointsSeedMaker_' + type] ToolSvc += InDetTrigZvertexMaker #InDetTrigZvertexMaker.OutputLevel=1 # SCT and Pixel detector elements road builder # from InDetTrigRecExample.InDetTrigConfigRecLoadTools import InDetTrigSiDetElementsRoadMaker, InDetTrigSiComTrackFinder # Local track finding using space point seed # from SiTrackMakerTool_xk.SiTrackMakerTool_xkConf import InDet__SiTrackMaker_xk InDetTrigSiTrackMaker = InDet__SiTrackMaker_xk( name='InDetTrigSiTrackMaker_' + type, RoadTool=InDetTrigSiDetElementsRoadMaker, CombinatorialTrackFinder=InDetTrigSiComTrackFinder, pTmin=InDetTrigSliceSettings[('pTmin', type)], nClustersMin=InDetTrigCutValues.minClusters(), nHolesMax=InDetTrigCutValues.nHolesMax(), nHolesGapMax=InDetTrigCutValues.nHolesGapMax(), SeedsFilterLevel=InDetTrigCutValues.seedFilterLevel(), Xi2max=InDetTrigCutValues.Xi2max(), Xi2maxNoAdd=InDetTrigCutValues.Xi2maxNoAdd(), nWeightedClustersMin=InDetTrigCutValues.nWeightedClustersMin(), #CosmicTrack = InDetFlags.doCosmics(), Xi2maxMultiTracks=InDetTrigCutValues.Xi2max(), UseAssociationTool=False) if type == "beamgas": InDetTrigSiTrackMaker.pTmin = EFIDTrackingCutsBeamGas.minPT() InDetTrigSiTrackMaker.nClustersMin = EFIDTrackingCutsBeamGas.minClusters( ) InDetTrigSiTrackMaker.nHolesMax = EFIDTrackingCutsBeamGas.nHolesMax( ) InDetTrigSiTrackMaker.UseAssociationTool = True #for BG and LowPt elif type == "cosmicsN": #create an additional for cosmics from InDetTrigRecExample.InDetTrigConfigRecLoadToolsCosmics import InDetTrigSiDetElementsRoadMakerCosmics InDetTrigSiTrackMaker.RoadTool = InDetTrigSiDetElementsRoadMakerCosmics InDetTrigSiTrackMaker.nClustersMin = EFIDTrackingCutsCosmics.minClusters( ) InDetTrigSiTrackMaker.nHolesMax = EFIDTrackingCutsCosmics.nHolesMax( ) #3 vs 7 InDetTrigSiTrackMaker.nHolesGapMax = EFIDTrackingCutsCosmics.nHolesGapMax( ) #3 InDetTrigSiTrackMaker.CosmicTrack = True #InDetTrigSiTrackMaker.GoodSeedClusterCount = 3 elif type == 'electron' and InDetTrigFlags.doBremRecovery(): InDetTrigSiTrackMaker.useBremModel = True ToolSvc += InDetTrigSiTrackMaker if (InDetTrigFlags.doPrintConfigurables()): print InDetTrigSiTrackMaker self.SeedsTool = InDetTrigSiSpacePointsSeedMaker self.ZvertexTool = InDetTrigZvertexMaker self.useZvertexTool = InDetTrigFlags.useZvertexTool() if type == "beamgas" or type == "cosmicsN": self.ZvertexTool = None self.useZvertexTool = False elif type == "heavyIon" or type == "heavyIonFS": self.useZvertexTool = True if lowPt: from InDetTrigRecExample.InDetTrigConfigRecLoadToolsLowPt \ import InDetTrigSiSpacePointsSeedMakerLowPt,InDetTrigSiTrackMakerLowPt, InDetTrigZvertexMakerLowPt self.TrackTool = InDetTrigSiTrackMakerLowPt self.SeedsTool = InDetTrigSiSpacePointsSeedMakerLowPt self.useZvertexTool = InDetTrigFlags.useZvertexTool() self.ZvertexTool = InDetTrigZvertexMakerLowPt else: #self.TrackTool = InDetTrigSiTrackMaker self.TrackTool = InDet__SiTrackMaker_xk('InDetTrigSiTrackMaker_' + type) self.EtaHalfWidth = InDetTrigSliceSettings[('etaHalfWidth', type)] self.PhiHalfWidth = InDetTrigSliceSettings[('phiHalfWidth', type)] self.doFullScan = InDetTrigSliceSettings[('doFullScan', type)] #monitoring from SiTrigSPSeededTrackFinder.SiTrigSPSeededTrackFinderMonitoring import \ SiTrigSPSeededTrackFinderValidationMonitor, \ SiTrigSPSeededTrackFinderOnlineMonitor from TrigTimeMonitor.TrigTimeHistToolConfig import TrigTimeHistToolConfig sitrktime = TrigTimeHistToolConfig("SiTRKTime") sitrktime.TimerHistLimits = [0, 200] self.AthenaMonTools = [ SiTrigSPSeededTrackFinderValidationMonitor(type=type), SiTrigSPSeededTrackFinderOnlineMonitor(type=type), sitrktime ]
ToolSvc += InDetTrigSiDetElementsRoadMakerCosmics #SP formation from SiSpacePointTool.SiSpacePointToolConf import InDet__SiSpacePointMakerTool InDetTrigSiSpacePointMakerToolCosmics = InDet__SiSpacePointMakerTool( name='InDetTrigSiSpacePointMakerToolCosmics', StripLengthTolerance=0.05, UsePerpendicularProjection=True) if (InDetTrigFlags.doPrintConfigurables()): print InDetTrigSiSpacePointMakerToolCosmics ToolSvc += InDetTrigSiSpacePointMakerToolCosmics from SiTrigSpacePointFormation.SiTrigSpacePointFormationConf import InDet__SCT_TrigSpacePointTool SCT_TrigSpacePointToolCosmics = InDet__SCT_TrigSpacePointTool( name='InDetTrigSCTSpacePointToolCosmics', ProcessOverlaps=InDetTrigFlags.doOverlapSP(), SiSpacePointMakerToolName= "InDet::SiSpacePointMakerTool/InDetTrigSiSpacePointMakerToolCosmics", OverlapLimitOpposite=5., OverrideBeamSpot=True, VertexY=99999999, VertexX=0, VertexZ=0, ) if (InDetTrigFlags.doPrintConfigurables()): print SCT_TrigSpacePointToolCosmics ToolSvc += SCT_TrigSpacePointToolCosmics