CMS 3D CMS Logo

benchmark-oval_cfg.py
Go to the documentation of this file.
1 # Runs PFBenchmarkAnalyzer and PFElectronBenchmark on PFElectron sample to
2 # monitor performance of PFElectron
3 import sys
4 import os
5 sys.path.append('.')
6 import dbs_discovery
7 import elec_selection
8 
9 import FWCore.ParameterSet.Config as cms
10 
11 process = cms.Process("TEST")
12 process.load("DQMServices.Core.DQM_cfg")
13 
14 
15 # Source : general definition
16 process.source = cms.Source("PoolSource",
17  fileNames = cms.untracked.vstring(),
18  secondaryFileNames = cms.untracked.vstring(),
19  noEventSort = cms.untracked.bool(True),
20  duplicateCheckMode = cms.untracked.string('noDuplicateCheck')
21  )
22 
23 # Update input files
24 #print dbs_discovery.search()
25 process.source.fileNames.extend(dbs_discovery.search())
26 
27 
28 process.maxEvents = cms.untracked.PSet(
29  input = cms.untracked.int32(-1)
30  )
31 
32 
33 process.load("Validation.RecoParticleFlow.electronBenchmarkGeneric_cff")
34 
35 # Update the electron selection
36 process.gensource.select = elec_selection.selection()
37 
38 # Update the delta R matching criteria : 0.2 for electrons; 0.05 for pions
39 process.pfElectronBenchmarkGeneric.deltaRMax = elec_selection.deltaR()
40 
41 # Update the output file
42 #process.pfElectronBenchmarkGeneric.OutputFile = cms.untracked.string(os.environ['TEST_OUTPUT_FILE'])
43 
44 process.pfElectronBenchmarkGeneric.OutputFile = cms.untracked.string('benchmark.root')
45 
46 
47 
48 process.p =cms.Path(
49  process.electronBenchmarkGeneric
50  )
51 
52 
53 #process.out = cms.OutputModule("PoolOutputModule",
54 # outputCommands = cms.untracked.vstring('keep *'),
55 # outputFile = cms.string(os.environ['TEST_OUTPUT_FILE'])
56 # )
57 #process.outpath = cms.EndPath(process.out)
58 
59 process.load("FWCore.MessageLogger.MessageLogger_cfi")
60 
61 process.MessageLogger.cerr.FwkReport.reportEvery = 100
62 
63 
64 
elec_selection.deltaR
def deltaR()
Definition: elec_selection.py:20
elec_selection.selection
def selection()
Definition: elec_selection.py:6
dbs_discovery.search
def search()
Definition: dbs_discovery.py:11