def __apply_configuration__(self): from Configurables import (CombinedParticleMaker, ProtoParticleMUONFilter, ProtoParticleCALOFilter, FilterDesktop) mName = "TaggingMuons" eName = "TaggingElectrons" pName = "TaggingPions" tagName = 'TaggingParticles' hat = 'Phys/' leaf = '/Particles' mLoc, eLoc, pLoc, tagLoc = [ hat + name + leaf for name in mName, eName, pName, tagName ] taggerMuons = CombinedParticleMaker(mName) taggerMuons.Particle = 'Muon' taggerMuons.addTool(ProtoParticleMUONFilter, name="Muon") taggerMuons.Muon.Selection = [ "RequiresDet='MUON' CombDLL(mu-pi)>'0.0'" ] taggerElectrons = CombinedParticleMaker(eName) taggerElectrons.Particle = 'Electron' taggerElectrons.addTool(ProtoParticleCALOFilter, name="Electron") taggerElectrons.Electron.Selection = [ "RequiresDet='CALO' CombDLL(e-pi)>'4.0'" ] taggerPions = CombinedParticleMaker(pName) taggerPions.Particle = 'Pion' taggingParticles = FilterDesktop(tagName) taggingParticles.Inputs = [eLoc, mLoc, pLoc] taggingParticles.Code = "(P>2.0*GeV)" dod = DataOnDemandSvc() dod.AlgMap.update({mLoc: taggerMuons}) dod.AlgMap.update({eLoc: taggerElectrons}) dod.AlgMap.update({pLoc: taggerPions}) dod.AlgMap.update({tagLoc: taggingParticles}) # configure charm candidate lists import FlavourTagging.CharmTaggerLists
def __init__(self, name='Tagging'): mName = name + "Muons" eName = name + "Electrons" pName = name + "Pions" tagName = name + 'Particles' _taggerMuons = CombinedParticleMaker(mName) _taggerMuons.Particle = 'Muon' _taggerMuons.addTool(ProtoParticleMUONFilter, name="Muon") _taggerMuons.Muon.Selection = [ "RequiresDet='MUON' CombDLL(mu-pi)>'0.0'" ] _taggerElectrons = CombinedParticleMaker(eName) _taggerElectrons.Particle = 'Electron' _taggerElectrons.addTool(ProtoParticleCALOFilter, name="Electron") _taggerElectrons.Electron.Selection = [ "RequiresDet='CALO' CombDLL(e-pi)>'4.0'" ] _taggerPions = CombinedParticleMaker(pName) _taggerPions.Particle = 'Pion' _taggingParticles = FilterDesktop(tagName) _taggingParticles.Code = "(P>2.0*GeV)" taggerMuons = Selection(mName, Algorithm=_taggerMuons) taggerElectrons = Selection(eName, Algorithm=_taggerElectrons) taggerPions = Selection(pName, Algorithm=_taggerPions) allTaggers = MergedSelection( name + 'All', RequiredSelections=[taggerPions, taggerMuons, taggerElectrons]) self.selection = Selection(tagName, Algorithm=_taggingParticles, RequiredSelections=[allTaggers])
) BiKalmanFittedPhotonFromL0Maker = Hlt2BiKalmanFittedForwardTracking.hlt2PhotonsFromL0( ) BiKalmanFittedPhotonFromL0LowMaker = Hlt2BiKalmanFittedForwardTracking.hlt2Pi0FromL0( ) ########################################################################## # # Make the Muons # Hlt2BiKalmanFittedMuons = CombinedParticleMaker( "Hlt2BiKalmanFittedMuons", Particle="muon", Input=BiKalmanFittedMuonProtoMaker.outputSelection(), Output='Hlt2/Hlt2BiKalmanFittedMuons/Particles', WriteP2PVRelations=False) Hlt2BiKalmanFittedMuons.addTool(ProtoParticleMUONFilter('Muon')) Hlt2BiKalmanFittedMuons.Muon.Selection = ["RequiresDet='MUON' IsMuon=True"] ########################################################################## # # Make the Downstream Muons # Hlt2BiKalmanFittedDownMuons = CombinedParticleMaker( "Hlt2BiKalmanFittedDownMuons", Particle="muon", Input=BiKalmanFittedDownMuonProtoMaker.outputSelection(), Output='Hlt2/Hlt2BiKalmanFittedDownMuons/Particles', WriteP2PVRelations=False) Hlt2BiKalmanFittedDownMuons.addTool(ProtoParticleMUONFilter('Muon')) Hlt2BiKalmanFittedDownMuons.Muon.Selection = ["RequiresDet='MUON' IsMuon=True"]
# Hlt2NoCutsKaons = Hlt2NoCutsPions.clone("Hlt2NoCutsKaons") Hlt2NoCutsKaons.Output = 'Hlt2/Hlt2NoCutsKaons/Particles' Hlt2NoCutsKaons.Particle = "kaon" ########################################################################## # Make the protons # Hlt2NoCutsProtons = Hlt2NoCutsPions.clone("Hlt2NoCutsProtons") Hlt2NoCutsProtons.Output = 'Hlt2/Hlt2NoCutsProtons/Particles' Hlt2NoCutsProtons.Particle = "proton" ########################################################################## # Make the Muons # Hlt2Muons = CombinedParticleMaker("Hlt2Muons") Hlt2Muons.Particle = "muon" Hlt2Muons.addTool(ProtoParticleMUONFilter('Muon')) Hlt2Muons.Muon.Selection = ["RequiresDet='MUON' IsMuon=True"] Hlt2Muons.Input = muonProtos.outputSelection() Hlt2Muons.Output = 'Htl2/Hlt2Muons/Particles' Hlt2Muons.WriteP2PVRelations = False ########################################################################## # Make the electrons # Hlt2Electrons = CombinedParticleMaker("Hlt2Electrons") Hlt2Electrons.Particle = "electron" Hlt2Electrons.Input = caloProtos.outputSelection() Hlt2Electrons.Output = 'Hlt2/Hlt2Electrons/Particles' Hlt2Electrons.addTool(ProtoParticleCALOFilter('Electron')) Hlt2Electrons.Electron.Selection = ["RequiresDet='CALO' CombDLL(e-pi)>'-2.0'"] Hlt2Electrons.WriteP2PVRelations = False ##########################################################################
velomuonProtos = Hlt2VeloMuonTracking.hlt2ProbeMuonProtos() fulldownProtos = Hlt2FullDownstreamTracking.hlt2ProbeMuonProtos() ########################################################################## # Make the pions # Hlt2TagAndProbePions = CombinedParticleMaker("Hlt2TagAndProbePions") Hlt2TagAndProbePions.Input = caloProtos.outputSelection() Hlt2TagAndProbePions.Output = 'Hlt2/Hlt2TagAndProbePions/Particles' Hlt2TagAndProbePions.Particle = "pion" Hlt2TagAndProbePions.WriteP2PVRelations = False ########################################################################## # Make the Muons # Hlt2TagAndProbeMuons = CombinedParticleMaker("Hlt2TagAndProbeMuons") Hlt2TagAndProbeMuons.Particle = "muon" Hlt2TagAndProbeMuons.addTool(ProtoParticleMUONFilter('Muon')) Hlt2TagAndProbeMuons.Muon.Selection = ["RequiresDet='MUON' IsMuon=True"] Hlt2TagAndProbeMuons.Input = muonWithCaloProtos.outputSelection() Hlt2TagAndProbeMuons.Output = 'Hlt2/Hlt2TagAndProbeMuons/Particles' Hlt2TagAndProbeMuons.WriteP2PVRelations = False ########################################################################## # # No PID muon particles, for association with probe track # ########################################################################## Hlt2LongAssocParts = NoPIDsParticleMaker("Hlt2LongAssocParts") Hlt2LongAssocParts.Particle = 'pion' # call this a pion for CombinePart to distringuish from probe Hlt2LongAssocParts.addTool(TrackSelector) Hlt2LongAssocParts.TrackSelector.TrackTypes = ["Long"] Hlt2LongAssocParts.Input = muonWithCaloProtos.outputSelection() Hlt2LongAssocParts.Output = "Hlt2/Hlt2LongAssocMuons/Particles"