CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
HighMETSkim_cff.py
Go to the documentation of this file.
2 
3 
4 ## select events with at least one good PV
5 pvFilter = cms.EDFilter(
6  "VertexSelector",
7  src = cms.InputTag("offlinePrimaryVertices"),
8  cut = cms.string("!isFake && ndof > 4 && abs(z) <= 24 && position.Rho <= 2"),
9  filter = cms.bool(True), # otherwise it won't filter the events, just produce an empty vertex collection.
10  )
11 
12 
13 ## apply HBHE Noise filter
14 ## import CommonTools.RecoAlgos.HBHENoiseFilter_cfi
15 ## HBHENoiseFilter = CommonTools.RecoAlgos.HBHENoiseFilter_cfi.HBHENoiseFilter.clone()
16 
17 
18 ## select events with high pfMET
19 pfMETSelector = cms.EDFilter(
20  "CandViewSelector",
21  src = cms.InputTag("pfMet"),
22  cut = cms.string( "pt()>200" )
23  )
24 
25 pfMETCounter = cms.EDFilter(
26  "CandViewCountFilter",
27  src = cms.InputTag("pfMETSelector"),
28  minNumber = cms.uint32(1),
29  )
30 
31 pfMETSelSeq = cms.Sequence(
32  pvFilter*
33  ##HBHENoiseFilter*
34  pfMETSelector*
35  pfMETCounter
36  )
37 
38 
39 
40 ## select events with high caloMET
41 caloMETSelector = cms.EDFilter(
42  "CandViewSelector",
43  src = cms.InputTag("caloMetM"),
44  cut = cms.string( "pt()>200" )
45  )
46 
47 caloMETCounter = cms.EDFilter(
48  "CandViewCountFilter",
49  src = cms.InputTag("caloMETSelector"),
50  minNumber = cms.uint32(1),
51  )
52 
53 caloMETSelSeq = cms.Sequence(
54  pvFilter*
55  ##HBHENoiseFilter*
56  caloMETSelector*
57  caloMETCounter
58  )
59 
60 
61 ## select events with high MET dependent on PF and Calo MET Conditions
62 CondMETSelector = cms.EDProducer(
63  "CandViewShallowCloneCombiner",
64  decay = cms.string("pfMet caloMetM"),
65  cut = cms.string(" (daughter(0).pt > 200) || (daughter(0).pt/daughter(1).pt > 2 && daughter(1).pt > 150 ) || (daughter(1).pt/daughter(0).pt > 2 && daughter(0).pt > 150 ) " )
66  )
67 
68 CondMETCounter = cms.EDFilter(
69  "CandViewCountFilter",
70  src = cms.InputTag("CondMETSelector"),
71  minNumber = cms.uint32(1),
72  )
73 
74 CondMETSelSeq = cms.Sequence(
75  pvFilter*
76  ##HBHENoiseFilter*
77  CondMETSelector*
78  CondMETCounter
79  )
80 
81 
82 
83 ## select events with PAT METs in MINIAODSIM - remember to keep the right branches in the cmsDriver
84 miniMETSelector = cms.EDFilter(
85  "CandViewSelector",
86  src = cms.InputTag("slimmedMETs"),
87  cut = cms.string( "pt()>200" )
88  )
89 
90 miniMETCounter = cms.EDFilter(
91  "CandViewCountFilter",
92  src = cms.InputTag("miniMETSelector"),
93  minNumber = cms.uint32(1),
94  )
95 
96 miniMETSelSeq = cms.Sequence(
97  ##HBHENoiseFilter*
98  miniMETSelector*
99  miniMETCounter
100  )
101