forked from TaiSakuma/WorkBookMet
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathpat_rawMET_cfg.py
43 lines (34 loc) · 1.69 KB
/
pat_rawMET_cfg.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
##____________________________________________________________________________||
from PhysicsTools.PatAlgos.patTemplate_cfg import *
##____________________________________________________________________________||
import FWCore.ParameterSet.VarParsing as VarParsing
options = VarParsing.VarParsing('analysis')
options.inputFiles = 'file:/afs/cern.ch/cms/Tutorials/TWIKI_DATA/MET/TTJets_AODSIM_532_numEvent100.root',
options.outputFile = 'pat_rawMET.root'
options.maxEvents = -1
options.parseArguments()
##____________________________________________________________________________||
process.maxEvents = cms.untracked.PSet(input = cms.untracked.int32(options.maxEvents))
process.MessageLogger.cerr.FwkReport.reportEvery = 10
##____________________________________________________________________________||
# from PhysicsTools.PatAlgos.tools.coreTools import *
# runOnData(process)
##____________________________________________________________________________||
from PhysicsTools.PatAlgos.tools.pfTools import *
switchToPFMET(process, input=cms.InputTag('pfMet'))
##____________________________________________________________________________||
process.source = cms.Source(
"PoolSource",
fileNames = cms.untracked.vstring(options.inputFiles)
)
##____________________________________________________________________________||
process.p = cms.Path(
process.patDefaultSequence
)
##____________________________________________________________________________||
process.out.fileName = cms.untracked.string(options.outputFile)
process.out.outputCommands = cms.untracked.vstring(
'drop *',
'keep patMETs_patMETs__PAT',
)
##____________________________________________________________________________||