Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 12:50:06

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 process = cms.Process("PFJETS")
0004 
0005 process.load("FWCore.MessageService.MessageLogger_cfi")
0006 
0007 process.source = cms.Source("PoolSource",
0008     fileNames = cms.untracked.vstring('file:/user/geisler/QCD_Pt-15to3000_Tune2C_Flat_8TeV_pythia8_AODSIM.root'),
0009 )
0010 
0011 ### conditions
0012 process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
0013 process.GlobalTag.globaltag = 'START53_V11::All'
0014         
0015 process.maxEvents = cms.untracked.PSet(
0016     input = cms.untracked.int32(100)
0017 )
0018 
0019 ### standard includes
0020 process.load('Configuration.Geometry.GeometryPilot2_cff')
0021 process.load("Configuration.StandardSequences.Reconstruction_cff")
0022 process.load("Configuration.StandardSequences.MagneticField_cff")
0023         
0024     
0025 process.selectedPrimaryVertexQuality = cms.EDFilter("VertexSelector",
0026     src = cms.InputTag('offlinePrimaryVertices'),
0027     cut = cms.string("isValid & ndof >= 4 & chi2 > 0 & tracksSize > 0 & abs(z) < 24 & abs(position.Rho) < 2."),
0028     filter = cms.bool(False),
0029 )
0030         
0031 ### PFCandidate AssociationMap-specific includes
0032 from CommonTools.RecoUtils.pfcand_assomap_cfi import PFCandAssoMap
0033         
0034 process.PFCand2VertexAM = PFCandAssoMap.clone(
0035           VertexCollection = cms.InputTag('selectedPrimaryVertexQuality'),
0036 )
0037         
0038 ### PFCandidateCollection-specific includes
0039 from CommonTools.RecoUtils.pfcand_nopu_witham_cfi import FirstVertexPFCandidates
0040         
0041 process.PFCand = FirstVertexPFCandidates.clone(
0042           VertexPFCandAssociationMap = cms.InputTag('PFCand2VertexAM'),
0043           VertexCollection = cms.InputTag('selectedPrimaryVertexQuality'),
0044 )
0045     
0046 ### JetProducer-specific includes
0047 from RecoJets.JetProducers.ak5PFJets_cfi import ak5PFJets   
0048 
0049 process.ak5PFJetsNew = ak5PFJets.clone(
0050     src = cms.InputTag("PFCand","P2V")
0051     #src = cms.InputTag("PFCand","V2P")
0052 )
0053 
0054 process.load("JetMETCorrections.Configuration.JetCorrectionServices_cff")
0055 process.load("JetMETCorrections.Configuration.JetCorrectionServicesAllAlgos_cff")
0056 
0057 # L2L3 Correction Producers
0058 process.ak5PFJetsNewL23 = cms.EDProducer('PFJetCorrectionProducer',
0059     src        = cms.InputTag('ak5PFJetsNew'),
0060     correctors = cms.vstring('ak5PFL2L3')
0061 )
0062         
0063 # L1L2L3 Correction Producers
0064 process.ak5PFJetsNewL123 = cms.EDProducer('PFJetCorrectionProducer',
0065     src        = cms.InputTag('ak5PFJetsNew'),
0066     correctors = cms.vstring('ak5PFL1L2L3')
0067 )
0068                 
0069 ### paths & sequences
0070         
0071 ##sequence to produce the collection of pfcand's associated to the first vertex
0072 process.pfc = cms.Sequence(
0073       process.selectedPrimaryVertexQuality
0074     * process.PFCand2VertexAM
0075     * process.PFCand
0076 )
0077         
0078 ##sequence to produce the jet collections
0079 process.pfjet = cms.Sequence(
0080       process.ak5PFJetsNew
0081     * process.ak5PFJetsNewL23
0082     * process.ak5PFJetsNewL123
0083 )
0084         
0085 
0086   
0087 process.p = cms.Path( 
0088       process.pfc
0089     * process.pfjet
0090 )
0091         
0092 process.myOutput = cms.OutputModule("PoolOutputModule",
0093         fileName = cms.untracked.string('myOutput.root'),
0094     outputCommands = cms.untracked.vstring('drop *',
0095           'keep *_*_*_PFJETS'),
0096 )
0097   
0098 process.e = cms.EndPath( process.myOutput )