CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ZMuSkim_cff.py
Go to the documentation of this file.
2 
3 ### HLT filter
4 import copy
6 ZMuHLTFilter = copy.deepcopy(hltHighLevel)
7 ZMuHLTFilter.throw = cms.bool(False)
8 ZMuHLTFilter.HLTPaths = ["HLT_Mu*","HLT_IsoMu*","HLT_DoubleMu*"]
9 
10 ### Z -> MuMu candidates
11 
12 # Get muons of needed quality for Zs
13 looseMuonsForZ = cms.EDFilter("MuonSelector",
14  src = cms.InputTag("muons"),
15  cut = cms.string('pt > 10 && abs(eta)<2.4 && isGlobalMuon = 1 && isTrackerMuon = 1 && abs(innerTrack().dxy)<2.0'),
16  filter = cms.bool(True)
17  )
18 
19 tightMuonsForZ = cms.EDFilter("MuonSelector",
20  src = cms.InputTag("looseMuonsForZ"),
21  cut = cms.string('pt > 20'),
22  filter = cms.bool(True)
23  )
24 
25 # build Z-> MuMu candidates
26 dimuons = cms.EDProducer("CandViewShallowCloneCombiner",
27  checkCharge = cms.bool(False),
28  cut = cms.string('mass > 30'),
29  decay = cms.string("tightMuonsForZ looseMuonsForZ")
30  )
31 
32 # Z filter
33 dimuonsFilter = cms.EDFilter("CandViewCountFilter",
34  src = cms.InputTag("dimuons"),
35  minNumber = cms.uint32(1)
36  )
37 
38 # Z Skim sequence
39 diMuonSelSeq = cms.Sequence(ZMuHLTFilter *
40  looseMuonsForZ *
41  tightMuonsForZ *
42  dimuons *
43  dimuonsFilter
44  )
45 
46