Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 14:21:38

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 process = cms.Process("myprocess")
0004 process.TFileService=cms.Service("TFileService",fileName=cms.string('JECplots.root'))
0005 ##-------------------- Communicate with the DB -----------------------
0006 process.load('Configuration.StandardSequences.Services_cff')
0007 #process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff')
0008 #process.GlobalTag.globaltag = 'START38_V13::All'
0009 
0010 
0011 ##-------------------- Import the JEC services -----------------------
0012 process.load('JetMETCorrections.Configuration.DefaultJEC_cff')
0013 
0014 
0015 from CondCore.DBCommon.CondDBSetup_cfi import *
0016 process.jec = cms.ESSource("PoolDBESSource",CondDBSetup,
0017                    connect = cms.string("sqlite:Jec11_V10.db"),
0018                    toGet =  cms.VPSet(
0019                        cms.PSet(record = cms.string("JetCorrectionsRecord"),
0020                                 tag = cms.string("JetCorrectorParametersCollection_Jec11_V10_AK5Calo"),
0021                                 label=cms.untracked.string("AK5Calo")),
0022                        cms.PSet(record = cms.string("JetCorrectionsRecord"),
0023                                 tag = cms.string("JetCorrectorParametersCollection_Jec11_V10_AK5PF"),
0024                                 label=cms.untracked.string("AK5PF")),
0025                        cms.PSet(record = cms.string("JetCorrectionsRecord"),
0026                                 tag = cms.string("JetCorrectorParametersCollection_Jec11_V10_AK5PFchs"),
0027                                 label=cms.untracked.string("AK5PFchs")),
0028                        cms.PSet(record = cms.string("JetCorrectionsRecord"),
0029                                 tag = cms.string("JetCorrectorParametersCollection_Jec11_V10_AK5JPT"),
0030                                 label=cms.untracked.string("AK5JPT"))
0031                        )
0032                    
0033                    )
0034 es_prefer_jec = cms.ESPrefer("PoolDBESSource","jec")
0035 
0036 
0037 
0038 
0039 
0040 
0041 ##-------------------- Define the source  ----------------------------
0042 process.maxEvents = cms.untracked.PSet(
0043         input = cms.untracked.int32(1)
0044         )
0045 process.source = cms.Source("EmptySource")
0046 
0047 ##-------------------- User analyzer  --------------------------------
0048 process.ak5calol2l3Residuall5l7  = cms.EDAnalyzer('FactorizedJetCorrectorDemo',
0049     levels                   = cms.vstring( 'L2Relative', 'L3Absolute', 'L5Flavor_gJ', 'L7Parton_gJ'),
0050     UncertaintyTag           = cms.string('Uncertainty'),
0051     UncertaintyFile          = cms.string(''),
0052     PayloadName              = cms.string('AK5Calo'),
0053     NHistoPoints             = cms.int32(10000),
0054     NGraphPoints             = cms.int32(500),
0055     EtaMin                   = cms.double(-5),
0056     EtaMax                   = cms.double(5),
0057     PtMin                    = cms.double(10),
0058     PtMax                    = cms.double(1000),
0059     #--- eta values for JEC vs pt plots ----
0060     VEta                     = cms.vdouble(0.0,1.0,2.0,3.0,4.0),
0061     #--- corrected pt values for JEC vs eta plots ----
0062     VPt                      = cms.vdouble(20,30,50,100,200),
0063     Debug                    = cms.untracked.bool(True)
0064 )
0065 
0066 process.p = cms.Path(process.ak5calol2l3Residuall5l7)
0067