-
Notifications
You must be signed in to change notification settings - Fork 4.2k
/
testPrimaryVertexFilter_cfg.py
30 lines (24 loc) · 1.33 KB
/
testPrimaryVertexFilter_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
import FWCore.ParameterSet.Config as cms
process = cms.Process("Test")
from PhysicsTools.PatAlgos.patInputFiles_cff import filesRelValProdTTbarGENSIMRECO
process.source = cms.Source("PoolSource",
fileNames = filesRelValProdTTbarGENSIMRECO
)
process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(100) )
process.MessageLogger = cms.Service("MessageLogger")
## ---
## This is an example of the use of the EDFilterWrapper to exploit C++ selector classes as defined in the
## PhysicsTools/SelectorUtils package wrapping them into an EDFilter. You can find the implementation of
## the EDFilter in PhysicsTools/UtilAlgos/plugins/PrimaryVertexFilter.cc. You can find the EDfilterWrapper
## class in PhysicsTools/UtilAlgos/interface/EDFilterWrapper.h. The class that has been exploited here is
## the PVSelector class of the PhysicsTools/SelectorUtils package, which makes implicit use of the
## PVObjectSelector class in the same package.You cna find the input parameters there.
process.primaryVertexFilter = cms.EDFilter("PrimaryVertexFilter",
pvSrc = cms.InputTag("offlinePrimaryVertices"),
minNdof = cms.double( 4 ),
maxZ = cms.double( 24.0 ),
maxRho = cms.double(2.0),
NPV = cms.int32(1)
)
process.p = cms.Path(process.primaryVertexFilter)
process.options = cms.untracked.PSet( wantSummary = cms.untracked.bool(True) )