CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
goldenZmmSelectionLOOSE_cfi.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 import copy
4 
5 # Uncomment to use trigger requirements
6 #import HLTrigger.HLTfilters.hltHighLevel_cfi
7 #zmmHLTFilter = HLTrigger.HLTfilters.hltHighLevel_cfi.hltHighLevel.clone()
8 #zmmHLTFilter.TriggerResultsTag = cms.InputTag("TriggerResults","","HLT")
9 #zmmHLTFilter.HLTPaths = ["HLT_Mu9", "HLT_Mu11", "HLT_Mu15", "HLT_DoubleMu3"]
10 #zmmHLTFilter.throw = cms.bool(False)
11 
12 # Cuts for each muon
13 goodMuons1 = cms.EDFilter("MuonViewRefSelector",
14  src = cms.InputTag("muons"),
15  cut = cms.string('isGlobalMuon=1 && isTrackerMuon=1 && abs(eta)<2.1 && abs(globalTrack().dxy)<0.2 && pt>20. && globalTrack().normalizedChi2<10 && globalTrack().hitPattern().numberOfValidTrackerHits>10 && globalTrack().hitPattern().numberOfValidMuonHits>0 && globalTrack().hitPattern().numberOfValidPixelHits>0 && numberOfMatches>1 && (isolationR03().sumPt+isolationR03().emEt+isolationR03().hadEt)<0.15*pt'),
16  filter = cms.bool(True)
17 )
18 
19 # Cuts for each muon
20 goodMuons2 = cms.EDFilter("MuonViewRefSelector",
21  src = cms.InputTag("muons"),
22  cut = cms.string('isGlobalMuon=1 && pt>20. && abs(eta)<2.4 && abs(globalTrack().dxy)<1.0 && globalTrack().hitPattern().numberOfValidTrackerHits>6'),
23  filter = cms.bool(True)
24 )
25 
26 # Cuts on dimuon system
27 zmmCands = cms.EDProducer("CandViewShallowCloneCombiner",
28  checkCharge = cms.bool(False),
29  cut = cms.string('mass>60'),
30  decay = cms.string("goodMuons1 goodMuons2")
31 )
32 zmmFilter = cms.EDFilter("CandViewCountFilter",
33  src = cms.InputTag("zmmCands"),
34  minNumber = cms.uint32(1)
35 )
36 
37 # Selection sequence
38 goldenZmmSelectionSequence = cms.Sequence(
39  #zmmHLTFilter *
40  goodMuons1*goodMuons2 *
41  zmmCands*zmmFilter
42 )