ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/Morgan/test/toto.py
Revision: 1.16
Committed: Tue Apr 21 10:42:23 2009 UTC (16 years ago) by lethuill
Content type: text/x-python
Branch: MAIN
CVS Tags: pat_2_2_7_01
Changes since 1.15: +6 -1 lines
Log Message:
Use beam spot in impact parameter calculation

File Contents

# User Rev Content
1 lethuill 1.1 import FWCore.ParameterSet.Config as cms
2    
3     process = cms.Process("NewProcess")
4    
5 lethuill 1.15 # Keep the logging output to a nice level
6 lethuill 1.1 process.load("FWCore.MessageLogger.MessageLogger_cfi")
7    
8     process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi")
9    
10 lethuill 1.15 # Needed for GlobalPositionRcd
11     process.load('Configuration/StandardSequences/FrontierConditions_GlobalTag_cff')
12     process.GlobalTag.globaltag = 'IDEAL_V12::All'
13    
14 lethuill 1.1 # Global geometry
15     process.load("Configuration.StandardSequences.Geometry_cff")
16 lethuill 1.15 process.load('Configuration/StandardSequences/MagneticField_38T_cff')
17    
18     # Transient Track Builder
19     process.load("TrackingTools.TransientTrack.TransientTrackBuilder_cfi")
20 lethuill 1.1
21 lethuill 1.15 # Geometry needed for clustering and calo shapes variables
22 lethuill 1.1 process.load("RecoEcal.EgammaClusterProducers.geometryForClustering_cff")
23    
24     # ES cluster for pi0 discrimination variables
25     #process.load("RecoEcal.EgammaClusterProducers.preshowerClusterShape_cfi")
26    
27     # pi0 discrimination variables
28     #process.load("RecoEcal.EgammaClusterProducers.piZeroDiscriminators_cfi")
29    
30     process.maxEvents = cms.untracked.PSet(
31 lethuill 1.12 input = cms.untracked.int32(10)
32 lethuill 1.1 )
33    
34 lethuill 1.4
35 lethuill 1.1 process.source = cms.Source("PoolSource",
36 lethuill 1.4 # RECO
37 lethuill 1.8 # fileNames = cms.untracked.vstring('file:/sps/cms/morgan/data/CMSSW_2_1_7__RelValTTbar__GEN-SIM-RECO__IDEAL_V9_v2__0002__56B92AB9-8B7E-DD11-A821-000423D6AF24.root')
38 lethuill 1.6 # fileNames = cms.untracked.vstring('file:/sps/cms/morgan/data/CMSSW_2_1_10__RelValH130GGgluonfusion__GEN-SIM-DIGI-RAW-HLTDEBUG-RECO__STARTUP_V7_v1__0001__00616C72-FA9A-DD11-A526-00304867902E.root')
39     # fileNames = cms.untracked.vstring('file:/sps/cms/boumedie/data/0A249693-FC85-DD11-AE0A-000423D99896.root')
40     # fileNames = cms.untracked.vstring('file:/sps/cms/smgascon/MCatNLO_HiggsSM_H_2gamma_mH120_10TeV_cff_py_RAW2DIGI_RECO.root')
41 lethuill 1.12 # fileNames = cms.untracked.vstring('file:/sps/cms/morgan/data/CMSSW_2_2_1__QCDpt170__Summer08_IDEAL_V11_redigi_v1__GEN-SIM-RECO__0010115D-6FE7-DD11-AFDC-0019B9E7CD05.root')
42 lethuill 1.4 # AOD
43 lethuill 1.6 # fileNames = cms.untracked.vstring('file:/sps/cms/morgan/data/CMSSW_2_1_7__Summer08__QCDDiJetPt380to470__AODSIM__IDEAL_V9_AODSIM_v1__0000__F630AA5F-EBA4-DD11-BABD-001D0967D71F.root')
44     # fileNames = cms.untracked.vstring('file:/sps/cms/morgan/data/CMSSW_2_1_7__Summer08__TTJets-madgraph__AODSIM__IDEAL_V9_AODSIM_v1__0004__000BCB88-49AF-DD11-A760-00E081791887.root')
45 lethuill 1.4 # PATAOD
46 lethuill 1.11 # fileNames = cms.untracked.vstring('file:/sps/cms/morgan/data/CMSSW_2_1_10__Summer08__TTJets-madgraph__IDEAL_V9__PATLayer1_OutputFromAOD_full_113.root')
47 lethuill 1.13 # fileNames = cms.untracked.vstring('file:/sps/cms/morgan/data/CMSSW_2_2_3__PATLayer1_Output.fromRECOinputCSA08test2_full.root')
48     fileNames = cms.untracked.vstring('file:/sps/cms/morgan/data/CMSSW_2_2_X__Farida__InclusiveMuPt15_IN2P3__PATL1_InclusiveMuPt15_Sum08_1.root')
49 lethuill 1.6 # PAT
50     # fileNames = cms.untracked.vstring('file:/sps/cms/morgan/data/CMSSW_2_1_10__TQAFLayer1_Output.fromAOD2110_IDEAL_full_0__PATOnly.root')
51 lethuill 1.1 )
52    
53    
54     process.analysis = cms.EDAnalyzer("TotoAnalyzer",
55     myConfig = cms.PSet(
56    
57 lethuill 1.4 # Data type of the PoolSource ( RECO / AOD / PAT / PATAOD )
58 lethuill 1.8 #dataType = cms.untracked.string("RECO"), # only RECO collections are present
59 lethuill 1.4 #dataType = cms.untracked.string("AOD"), # only AOD collections are present
60 lethuill 1.8 dataType = cms.untracked.string("PATAOD"), # mixture of PAT and AOD collections
61 lethuill 1.4 #dataType = cms.untracked.string("PAT"), # only PAT collections are present
62    
63 lethuill 1.1 # Verbosite
64     # 0 = muet
65     # 1 = No evts tous les 10 ou 100 evts
66     # 2 = Indique fonctions executees et nb d'objets reconstruits a chaque evt
67     # 3 = Liste objets de haut niveau (electrons, muons, photons...)
68     # 4 = Liste tous les objets (haut niveau, clusters....)
69     # 5 = Debug
70 lethuill 1.12 verbosity = cms.untracked.int32(5),
71 lethuill 1.1
72     # name of output root file
73 lethuill 1.16 RootFileName = cms.untracked.string('InclusiveMuPt15_Sum08_1_31191events_BEAMSPOT.root'),
74 lethuill 1.1
75 lethuill 1.8 # Is PoolSource coming from CSA07 Soup Production ? (needed to get CSA07 Process Id and weights)
76 lethuill 1.1 isCSA07Soup = cms.untracked.bool(False),
77    
78 lethuill 1.3 # What is written to rootuple
79 lethuill 1.13 doHLT = cms.untracked.bool(True),
80 lethuill 1.6 doMC = cms.untracked.bool(True),
81 lethuill 1.7 doPDFInfo = cms.untracked.bool(True),
82 lethuill 1.6 doSignalMuMuGamma = cms.untracked.bool(False), # not tested in 2.1.X...
83     doSignalTopTop = cms.untracked.bool(True),
84     # signalGenerator = cms.untracked.string('PYTHIA'),
85 lethuill 1.1 # signalGenerator = cms.untracked.string('COMPHEP'),
86     # signalGenerator = cms.untracked.string('ALPGEN'),
87 lethuill 1.6 signalGenerator = cms.untracked.string('MADGRAPH'),
88 lethuill 1.4 doPhotonConversionMC = cms.untracked.bool(False),
89 lethuill 1.6
90     doPhotonMC = cms.untracked.bool(True),
91     doElectronMC = cms.untracked.bool(True),
92     doMuonMC = cms.untracked.bool(True),
93     doJetMC = cms.untracked.bool(True),
94     doMETMC = cms.untracked.bool(True),
95     doUnstablePartsMC = cms.untracked.bool(True),
96 lethuill 1.12
97 lethuill 1.16 doBeamSpot = cms.untracked.bool(True),
98 lethuill 1.5 doPrimaryVertex = cms.untracked.bool(True),
99 lethuill 1.15 doTrack = cms.untracked.bool(True),
100 lethuill 1.1 doJet = cms.untracked.bool(True),
101     doMuon = cms.untracked.bool(True),
102     doElectron = cms.untracked.bool(True),
103 lethuill 1.12 doPhoton = cms.untracked.bool(True),
104 lethuill 1.4 doCluster = cms.untracked.bool(False),
105 lethuill 1.3 doMET = cms.untracked.bool(True),
106 lethuill 1.6
107 lethuill 1.15 doPhotonVertexCorrection = cms.untracked.bool(False),
108 lethuill 1.4 doPhotonIsolation = cms.untracked.bool(False),
109     doPhotonConversion = cms.untracked.bool(False),
110 lethuill 1.1 conversionLikelihoodWeightsFile = cms.untracked.string('RecoEgamma/EgammaTools/data/TMVAnalysis_Likelihood.weights.txt'),
111 lethuill 1.6
112 lethuill 1.1 # Draw MC particle tree
113 lethuill 1.8 drawMCTree = cms.untracked.bool(False),
114 lethuill 1.1 mcTreePrintP4 = cms.untracked.bool(True),
115     mcTreePrintPtEtaPhi = cms.untracked.bool(False),
116     mcTreePrintVertex = cms.untracked.bool(False),
117     mcTreePrintStatus = cms.untracked.bool(True),
118 lethuill 1.3 mcTreePrintIndex = cms.untracked.bool(True),
119     mcTreeStatus = cms.untracked.vint32( 3 ), # accepted status codes
120    
121 lethuill 1.6
122 lethuill 1.1 # MC particles acceptance cuts
123     photonMC_etaMax = cms.double(3.0),
124     photonMC_ptMin = cms.double(2.0),
125     electronMC_etaMax = cms.double(3.0),
126     electronMC_ptMin = cms.double(2.0),
127 lethuill 1.3 muonMC_etaMax = cms.double(3.0),
128 lethuill 1.2 muonMC_ptMin = cms.double(0.0),
129 lethuill 1.13 jetMC_etaMax = cms.double(10.0),
130     jetMC_ptMin = cms.double(0.0),
131 lethuill 1.6
132 lethuill 1.1 # Photon isolation
133     #ecalIsolation_BarrelBC_type = cms.int32(110), # Type of Clusters used for isolation in barrel (see TRootCluster.h for type definition)
134     #ecalIsolation_EndcapBC_type = cms.int32(120), # Type of Clusters used for isolation in endcap (see TRootCluster.h for type definition)
135     ecalIsolation_BarrelBC_type = cms.int32(210), # Type of Clusters used for isolation in barrel (see TRootCluster.h for type definition)
136     ecalIsolation_EndcapBC_type = cms.int32(320), # Type of Clusters used for isolation in endcap (see TRootCluster.h for type definition)
137     ecalIslandIsolation_DRmax = cms.double(0.3), # size of the DR cone around photon - Et of Island BC in this cone are added
138     ecalIslandIsolation_ClusterEt_threshold = cms.double(0.0), # Et threshold for BC added in DR cone
139     ecalDoubleConeIsolation_DRmin = cms.double(0.05), # size of the inner DR cone around photon - BC in this cone are rejected
140     ecalDoubleConeIsolation_DRmax = cms.double(0.3), # size of the outer DR cone around photon - Et of Island BC with DRmin < DR < DRmax are added
141     ecalDoubleConeIsolation_ClusterEt_threshold = cms.double(0.0), # Et threshold for BC added in DR cone
142     hcalRecHitIsolation_DRmax = cms.double(0.3), # size of the DR cone around photon - Et of HCAL rechits in this cone are added
143     hcalRecHitIsolation_HitEt_threshold = cms.double(0.0), # Et threshold for HCAL rechits in DR cone
144     trackerIsolation_DRmax = cms.double(0.3), # size of the DR cone around photon - pt of tracks in this cone are added
145     trackerIsolation_pt_threshold = cms.double(0.0), # pt threshold for tracks added in DR cone
146 lethuill 1.14 trackerIsolation_pixelLayers_threshold = cms.int32(0) # minimum number of pixel layers with measurement required for tracks to be added in DR cone isolation
147 lethuill 1.3 ),
148 lethuill 1.1
149 lethuill 1.4 producersNamesRECO = cms.PSet(
150     dataType = cms.untracked.string("RECO"),
151 lethuill 1.3 hltProducer = cms.InputTag("TriggerResults","","HLT"),
152     genParticlesProducer = cms.InputTag("genParticles"),
153 lethuill 1.13 genJetsProducer = cms.InputTag("iterativeCone5GenJets"),
154     genMETsProducer = cms.InputTag("genMet"),
155 lethuill 1.16 beamSpotProducer = cms.InputTag("offlineBeamSpot"),
156 lethuill 1.3 primaryVertexProducer = cms.InputTag("offlinePrimaryVerticesWithBS"),
157     trackProducer = cms.InputTag("generalTracks"),
158 lethuill 1.6 #jetProducer = cms.InputTag("iterativeCone5CaloJets"),
159     jetProducer = cms.InputTag("iterativeCone5PFJets"),
160 lethuill 1.3 muonProducer = cms.InputTag("muons"),
161     electronProducer = cms.InputTag("pixelMatchGsfElectrons"),
162 lethuill 1.12 photonProducer = cms.InputTag("photons"),
163     photonIDProducer = cms.InputTag("PhotonIDProd","PhotonAssociatedID"),
164 lethuill 1.3 metProducer = cms.InputTag("met"),
165     barrelEcalRecHitCollection = cms.InputTag("ecalRecHit","EcalRecHitsEB"),
166     endcapEcalRecHitCollection = cms.InputTag("ecalRecHit","EcalRecHitsEE"),
167 lethuill 1.6 reducedBarrelEcalRecHitCollection = cms.InputTag("reducedEcalRecHitsEB"),
168     reducedEndcapEcalRecHitCollection = cms.InputTag("reducedEcalRecHitsEE"),
169     #reducedBarrelEcalRecHitCollection = cms.InputTag("ecalRecHit","EcalRecHitsEB"),
170     #reducedEndcapEcalRecHitCollection = cms.InputTag("ecalRecHit","EcalRecHitsEE"),
171 lethuill 1.3 hbheRecHitProducer = cms.InputTag("hbhereco"),
172     hoRecHitProducer = cms.InputTag("horeco"),
173 lethuill 1.12 hfRecHitProducer = cms.InputTag("hfreco")
174 lethuill 1.4 ),
175    
176     producersNamesAOD = cms.PSet(
177     dataType = cms.untracked.string("AOD"),
178     hltProducer = cms.InputTag("TriggerResults","","HLT"),
179     genParticlesProducer = cms.InputTag("genParticles"),
180 lethuill 1.13 genJetsProducer = cms.InputTag("iterativeCone5GenJets"),
181     genMETsProducer = cms.InputTag("genMet"),
182 lethuill 1.16 beamSpotProducer = cms.InputTag("offlineBeamSpot"),
183 lethuill 1.4 primaryVertexProducer = cms.InputTag("offlinePrimaryVerticesWithBS"),
184     trackProducer = cms.InputTag("generalTracks"),
185     jetProducer = cms.InputTag("iterativeCone5CaloJets"),
186     muonProducer = cms.InputTag("muons"),
187     electronProducer = cms.InputTag("pixelMatchGsfElectrons"),
188 lethuill 1.12 photonProducer = cms.InputTag("photons"),
189     photonIDProducer = cms.InputTag("PhotonIDProd","PhotonAssociatedID"),
190 lethuill 1.4 metProducer = cms.InputTag("met"),
191     barrelEcalRecHitCollection = cms.InputTag("ecalRecHit","EcalRecHitsEB"),
192     endcapEcalRecHitCollection = cms.InputTag("ecalRecHit","EcalRecHitsEE"),
193     reducedBarrelEcalRecHitCollection = cms.InputTag("reducedEcalRecHitsEB"),
194     reducedEndcapEcalRecHitCollection = cms.InputTag("reducedEcalRecHitsEE"),
195     hbheRecHitProducer = cms.InputTag("hbhereco"),
196     hoRecHitProducer = cms.InputTag("horeco"),
197 lethuill 1.12 hfRecHitProducer = cms.InputTag("hfreco")
198 lethuill 1.4 ),
199    
200     producersNamesPATAOD = cms.PSet(
201     dataType = cms.untracked.string("PATAOD"),
202     hltProducer = cms.InputTag("TriggerResults","","HLT"),
203     genParticlesProducer = cms.InputTag("genParticles"),
204 lethuill 1.13 genJetsProducer = cms.InputTag("iterativeCone5GenJets"),
205     genMETsProducer = cms.InputTag("genMet"),
206 lethuill 1.16 beamSpotProducer = cms.InputTag("offlineBeamSpot"),
207 lethuill 1.4 primaryVertexProducer = cms.InputTag("offlinePrimaryVerticesWithBS"),
208     trackProducer = cms.InputTag("generalTracks"),
209     jetProducer = cms.InputTag("selectedLayer1Jets"),
210     muonProducer = cms.InputTag("selectedLayer1Muons"),
211     electronProducer = cms.InputTag("selectedLayer1Electrons"),
212 lethuill 1.12 photonProducer = cms.InputTag("selectedLayer1Photons"),
213     photonIDProducer = cms.InputTag("PhotonIDProd","PhotonAssociatedID"),
214 lethuill 1.4 metProducer = cms.InputTag("selectedLayer1METs"),
215     barrelEcalRecHitCollection = cms.InputTag("ecalRecHit","EcalRecHitsEB"),
216     endcapEcalRecHitCollection = cms.InputTag("ecalRecHit","EcalRecHitsEE"),
217     reducedBarrelEcalRecHitCollection = cms.InputTag("reducedEcalRecHitsEB"),
218     reducedEndcapEcalRecHitCollection = cms.InputTag("reducedEcalRecHitsEE"),
219     hbheRecHitProducer = cms.InputTag("hbhereco"),
220     hoRecHitProducer = cms.InputTag("horeco"),
221 lethuill 1.12 hfRecHitProducer = cms.InputTag("hfreco")
222 lethuill 1.4 ),
223    
224     producersNamesPAT = cms.PSet(
225     dataType = cms.untracked.string("PAT"),
226     hltProducer = cms.InputTag("PATALACON"),
227     genParticlesProducer = cms.InputTag("PATALACON"),
228 lethuill 1.13 genJetsProducer = cms.InputTag("iterativeCone5GenJets"),
229     genMETsProducer = cms.InputTag("genMet"),
230 lethuill 1.16 beamSpotProducer = cms.InputTag("offlineBeamSpot"),
231 lethuill 1.4 primaryVertexProducer = cms.InputTag("offlinePrimaryVerticesWithBS"),
232     trackProducer = cms.InputTag("PATALACON"),
233     jetProducer = cms.InputTag("selectedLayer1Jets"),
234     muonProducer = cms.InputTag("selectedLayer1Muons"),
235     electronProducer = cms.InputTag("selectedLayer1Electrons"),
236 lethuill 1.12 photonProducer = cms.InputTag("selectedLayer1Photons"),
237     photonIDProducer = cms.InputTag("PATALACON"),
238 lethuill 1.4 metProducer = cms.InputTag("selectedLayer1METs"),
239     barrelEcalRecHitCollection = cms.InputTag("PATALACON"),
240     endcapEcalRecHitCollection = cms.InputTag("PATALACON"),
241     reducedBarrelEcalRecHitCollection = cms.InputTag("PATALACON"),
242     reducedEndcapEcalRecHitCollection = cms.InputTag("PATALACON"),
243     hbheRecHitProducer = cms.InputTag("PATALACON"),
244     hoRecHitProducer = cms.InputTag("PATALACON"),
245 lethuill 1.12 hfRecHitProducer = cms.InputTag("PATALACON")
246 lethuill 1.3 )
247 lethuill 1.1 )
248    
249 lethuill 1.4
250 lethuill 1.6 ##process.hltHighLevel = cms.EDFilter("HLTHighLevel",
251     ## HLTPaths = cms.vstring('HLT2PhotonRelaxed'),
252     ## andOr = cms.bool(True),
253     ## TriggerResultsTag = cms.InputTag("TriggerResults","","HLT")
254     ##)
255 lethuill 1.4
256 lethuill 1.1 #process.egammIsolation = cms.Sequence(process.egammaHcalIsolation+process.egammaHOE+process.egammaTowerIsolation+process.egammaHOETower+process.egammaElectronTkIsolation+process.egammaElectronTkRelIsolation+process.egammaElectronTkNumIsolation+process.egammaPhotonTkIsolation+process.egammaPhotonTkRelIsolation+process.egammaEcalRelIsolationSequence+process.egammaEcalIsolationSequence)
257     #process.p = cms.Path(process.preshowerClusterShape*process.piZeroDiscriminators*process.analysis)
258     process.p = cms.Path(process.analysis)
259