CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_3/src/DPGAnalysis/Skims/python/CosmicsPD_Skims.py

Go to the documentation of this file.
00001 import FWCore.ParameterSet.Config as cms
00002 
00003 process = cms.Process("SKIM")
00004 
00005 process.configurationMetadata = cms.untracked.PSet(
00006     version = cms.untracked.string('$Revision: 1.2 $'),
00007     name = cms.untracked.string('$Source: /cvs/CMSSW/CMSSW/DPGAnalysis/Skims/python/CosmicsPD_Skims.py,v $'),
00008     annotation = cms.untracked.string('CRAFT Cosmics PD skim')
00009 )
00010 
00011 #
00012 #
00013 # This is for testing purposes.
00014 #
00015 #
00016 process.source = cms.Source("PoolSource",
00017                             fileNames = cms.untracked.vstring(
00018 '/store/data/Commissioning09/Cosmics/RECO/v5/000/105/755/D266D139-D871-DE11-A709-001D09F28F0C.root',
00019 '/store/data/Commissioning09/Cosmics/RECO/v5/000/105/755/CA27788D-E871-DE11-8B46-001D09F276CF.root',
00020 '/store/data/Commissioning09/Cosmics/RECO/v5/000/105/755/AC5633B2-D471-DE11-9B3A-001D09F252F3.root',
00021 '/store/data/Commissioning09/Cosmics/RECO/v5/000/105/755/9CD957E7-D071-DE11-B6AE-001D09F252F3.root',
00022 '/store/data/Commissioning09/Cosmics/RECO/v5/000/105/755/94BF68F7-D171-DE11-902B-000423D986A8.root',
00023 '/store/data/Commissioning09/Cosmics/RECO/v5/000/105/755/7838FE1E-C771-DE11-9FD5-000423D98950.root',
00024 '/store/data/Commissioning09/Cosmics/RECO/v5/000/105/755/56632803-DD71-DE11-BAF5-000423D9870C.root',
00025 '/store/data/Commissioning09/Cosmics/RECO/v5/000/105/755/42A67CB9-E971-DE11-AA86-001D09F252F3.root',
00026 '/store/data/Commissioning09/Cosmics/RECO/v5/000/105/755/407225D3-D071-DE11-809B-001D09F297EF.root',
00027 '/store/data/Commissioning09/Cosmics/RECO/v5/000/105/755/3E5E1CF0-D271-DE11-AC2B-000423D94700.root',
00028 '/store/data/Commissioning09/Cosmics/RECO/v5/000/105/755/2C57E916-D071-DE11-AF0E-001D09F24E39.root',
00029 '/store/data/Commissioning09/Cosmics/RECO/v5/000/105/755/228896A5-E571-DE11-A60B-001D09F2AF96.root'),
00030 
00031 #  '/store/data/Commissioning08/Cosmics/RECO/CRAFT_ALL_V9_225-v1/0002/0A12CE23-D7F9-DD11-819E-00E081348D21.root'),
00032                             secondaryFileNames = cms.untracked.vstring(
00033 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/F6887FD0-9371-DE11-B69E-00304879FBB2.root',
00034 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/EEAF292E-9571-DE11-9A17-000423D94C68.root',
00035 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/ECC04DEB-9071-DE11-9F3A-001D09F23174.root',
00036 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/E8CE8710-9171-DE11-9211-000423D94534.root',
00037 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/DEB9057C-9471-DE11-BAF5-000423D94524.root',
00038 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/DC2A7158-A171-DE11-ACD3-001D09F24047.root',
00039 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/D6E68664-9271-DE11-AE97-000423D9970C.root',
00040 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/D2D94C9C-9171-DE11-AA96-000423D94AA8.root',
00041 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/B045C7CB-9371-DE11-AF39-001D09F24489.root',
00042 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/A2C791EF-9071-DE11-871D-001D09F2423B.root',
00043 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/9E1A4336-9071-DE11-81BD-001D09F251B8.root',
00044 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/8C28F89C-9171-DE11-B944-000423D9A2AE.root',
00045 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/82A37610-9371-DE11-A293-000423D98B6C.root',
00046 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/822D1510-9371-DE11-A329-000423D99A8E.root',
00047 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/76515611-9371-DE11-8BF2-001D09F24024.root',
00048 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/76434EA1-9171-DE11-B39F-000423D98E54.root',
00049 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/6E1DB87B-9471-DE11-B4E8-000423D98B28.root',
00050 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/6A15A1C7-9371-DE11-9ACB-0030487A18F2.root',
00051 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/4E95107B-9471-DE11-9E86-000423D944F0.root',
00052 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/42C723CA-9871-DE11-8614-000423D6B48C.root',
00053 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/3E934456-9271-DE11-BA19-000423D99AA2.root',
00054 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/3AF89B38-9371-DE11-AEE9-000423D33970.root',
00055 '/store/data/Commissioning09/Cosmics/RAW/v3/000/105/755/2C696C5B-9271-DE11-BD57-000423D94990.root')
00056 
00057 #        '/store/data/Commissioning08/Cosmics/RAW/v1/000/069/578/085EFED4-E5AB-DD11-9ACA-001617C3B6FE.root')
00058 )
00059 
00060 process.maxEvents = cms.untracked.PSet(
00061     input = cms.untracked.int32(500)
00062 )
00063 
00064 process.options = cms.untracked.PSet(
00065     wantSummary = cms.untracked.bool(True)
00066 )
00067 
00068 #------------------------------------------
00069 # Load standard sequences.
00070 #------------------------------------------
00071 process.load('Configuration/StandardSequences/MagneticField_AutoFromDBCurrent_cff')
00072 process.load('Configuration/StandardSequences/GeometryIdeal_cff')
00073 
00074 
00075 process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
00076 process.GlobalTag.globaltag = 'CRAFT09_R_V4::All' 
00077 
00078 process.load("Configuration/StandardSequences/RawToDigi_Data_cff")
00079 process.load("Configuration/StandardSequences/ReconstructionCosmics_cff")
00080 
00081 process.load('Configuration/EventContent/EventContentCosmics_cff')
00082 
00083 
00084 import DPGAnalysis.Skims.CSCSkim_cfi
00085 process.extend(DPGAnalysis.Skims.CSCSkim_cfi)
00086 
00087 ############################CSCSkim trial ##########################################
00088 
00089 #### the path
00090 
00091 process.mySkim = cms.Path(process.cscSkim)
00092 
00093 
00094 #### output 
00095 process.outputSkim = cms.OutputModule(
00096     "PoolOutputModule",
00097     outputCommands = cms.untracked.vstring('keep *','drop *_MEtoEDMConverter_*_*'),
00098     fileName = cms.untracked.string("cscskimEvents.root"),
00099     dataset = cms.untracked.PSet(
00100       dataTier = cms.untracked.string('RAW-RECO'),
00101       filterName = cms.untracked.string('CSCSkim_trial')
00102     ),
00103     SelectEvents = cms.untracked.PSet(SelectEvents = cms.vstring('mySkim'))
00104 )
00105 
00106 ##########################CSC Skim BField Studies#######################################
00107 
00108 process.cscbfield=DPGAnalysis.Skims.CSCSkim_cfi.cscSkim.clone()
00109 process.cscbfield.typeOfSkim = cms.untracked.int32(9)
00110 
00111 #### the path
00112 
00113 process.BfieldStudySkim = cms.Path(process.cscbfield)
00114 
00115 
00116 #### output 
00117 process.outputSkimBField = cms.OutputModule(
00118     "PoolOutputModule",
00119     outputCommands = cms.untracked.vstring('keep *','drop *_MEtoEDMConverter_*_*'),
00120     fileName = cms.untracked.string("CSCEvents_BFieldStudy.root"),
00121     dataset = cms.untracked.PSet(
00122       dataTier = cms.untracked.string('RAW-RECO'),
00123       filterName = cms.untracked.string('CSCSkim_BFieldStudies')
00124     ),
00125     SelectEvents = cms.untracked.PSet(SelectEvents = cms.vstring('BfieldStudySkim'))
00126 )
00127 
00128 
00129 
00130 ######################################Super Pointing#################################################
00131 
00132 process.cosmicMuonsBarrelOnlyFilter = cms.EDFilter("HLTMuonPointingFilter",
00133                                                    SALabel = cms.string("cosmicMuonsBarrelOnly"),
00134                                                    PropagatorName = cms.string("SteppingHelixPropagatorAny"),
00135                                                    radius = cms.double(10.0),
00136                                                    maxZ = cms.double(50.0),
00137                                                    saveTags = cms.bool(False)
00138                                                    )
00139 
00140 process.cosmicMuonsFilter = cms.EDFilter("HLTMuonPointingFilter",
00141                                          SALabel = cms.string("cosmicMuons"),
00142                                          PropagatorName = cms.string("SteppingHelixPropagatorAny"),
00143                                          radius = cms.double(10.0),
00144                                          maxZ = cms.double(50.0),
00145                                          saveTags = cms.bool(False)
00146                                          )
00147 
00148 process.cosmicMuons1LegFilter = cms.EDFilter("HLTMuonPointingFilter",
00149                                                        SALabel = cms.string("cosmicMuons1Leg"),
00150                                                        PropagatorName = cms.string("SteppingHelixPropagatorAny"),
00151                                                        radius = cms.double(10.0),
00152                                                        maxZ = cms.double(50.0),
00153                                                        saveTags = cms.bool(False)
00154                                                        )
00155 
00156 process.globalCosmicMuonsBarrelOnlyFilter = cms.EDFilter("HLTMuonPointingFilter",
00157                                                          SALabel = cms.string("globalCosmicMuonsBarrelOnly"),
00158                                                          PropagatorName = cms.string("SteppingHelixPropagatorAny"),
00159                                                          radius = cms.double(10.0),
00160                                                          maxZ = cms.double(50.0),
00161                                                          saveTags = cms.bool(False)
00162                                                          )
00163 
00164 process.cosmictrackfinderP5Filter = cms.EDFilter("HLTMuonPointingFilter",
00165                                                  SALabel = cms.string("cosmictrackfinderP5"),
00166                                                  PropagatorName = cms.string("SteppingHelixPropagatorAny"),
00167                                                  radius = cms.double(10.0),
00168                                                  maxZ = cms.double(50.0),
00169                                                  saveTags = cms.bool(False)
00170                                                  )
00171 
00172 process.globalCosmicMuonsFilter = cms.EDFilter("HLTMuonPointingFilter",
00173                                                SALabel = cms.string("globalCosmicMuons"),
00174                                                PropagatorName = cms.string("SteppingHelixPropagatorAny"),
00175                                                radius = cms.double(10.0),
00176                                                maxZ = cms.double(50.0),
00177                                                saveTags = cms.bool(False)
00178                                                )
00179 
00180 process.rsWithMaterialTracksP5Filter = cms.EDFilter("HLTMuonPointingFilter",
00181                                                     SALabel = cms.string("rsWithMaterialTracksP5"),
00182                                                     PropagatorName = cms.string("SteppingHelixPropagatorAny"),
00183                                                     radius = cms.double(10.0),
00184                                                     maxZ = cms.double(50.0),
00185                                                     saveTags = cms.bool(False)
00186                                                     )
00187 
00188 process.globalCosmicMuons1LegFilter = cms.EDFilter("HLTMuonPointingFilter",
00189                                                              SALabel = cms.string("globalCosmicMuons1Leg"),
00190                                                              PropagatorName = cms.string("SteppingHelixPropagatorAny"),
00191                                                              radius = cms.double(10.0),
00192                                                              maxZ = cms.double(50.0),
00193                                                              saveTags = cms.bool(False)
00194                                                              )
00195 
00196 process.ctfWithMaterialTracksP5Filter = cms.EDFilter("HLTMuonPointingFilter",
00197                                                      SALabel = cms.string("ctfWithMaterialTracksP5"),
00198                                                      PropagatorName = cms.string("SteppingHelixPropagatorAny"),
00199                                                      radius = cms.double(10.0),
00200                                                      maxZ = cms.double(50.0),
00201                                                      saveTags = cms.bool(False)
00202                                                      )
00203 
00204 
00205 process.cosmicMuonsBarrelOnlyPath = cms.Path(process.cosmicMuonsBarrelOnlyFilter)
00206 process.cosmicMuonsPath = cms.Path(process.cosmicMuonsFilter)
00207 process.cosmicMuons1LegPath = cms.Path(process.cosmicMuons1LegFilter)
00208 process.globalCosmicMuonsBarrelOnlyPath = cms.Path(process.globalCosmicMuonsBarrelOnlyFilter)
00209 process.cosmictrackfinderP5Path = cms.Path(process.cosmictrackfinderP5Filter)
00210 process.globalCosmicMuonsPath = cms.Path(process.globalCosmicMuonsFilter)
00211 process.rsWithMaterialTracksP5Path = cms.Path(process.rsWithMaterialTracksP5Filter)
00212 process.globalCosmicMuons1LegPath = cms.Path(process.globalCosmicMuons1LegFilter)
00213 process.ctfWithMaterialTracksP5Path = cms.Path(process.ctfWithMaterialTracksP5Filter)
00214 
00215 
00216 
00217 process.outSP = cms.OutputModule("PoolOutputModule",
00218                                outputCommands = cms.untracked.vstring('keep *','drop *_MEtoEDMConverter_*_*'),
00219                                SelectEvents = cms.untracked.PSet(SelectEvents = cms.vstring('cosmicMuonsBarrelOnlyPath',
00220                                                                                             'cosmicMuonsPath',
00221                                                                                             'cosmicMuons1LegPath',
00222                                                                                             'globalCosmicMuonsBarrelOnlyPath',
00223                                                                                             'cosmictrackfinderP5Path',
00224                                                                                             'globalCosmicMuonsPath',
00225                                                                                             'rsWithMaterialTracksP5Path',
00226                                                                                             'globalCosmicMuons1LegPath',
00227                                                                                             'ctfWithMaterialTracksP5Path')),                               
00228                                dataset = cms.untracked.PSet(
00229                                          dataTier = cms.untracked.string('RAW-RECO'),
00230                                          filterName = cms.untracked.string('SuperPointing')),
00231                                fileName = cms.untracked.string('/tmp/arizzi/superPointing.root')
00232                                )
00233 
00234 #################################Tracker Pointing###############################################
00235 process.cosmictrackfinderP5TkCntFilter = cms.EDFilter("TrackCountFilter",
00236                                                       src = cms.InputTag('cosmictrackfinderP5'),
00237                                                       minNumber = cms.uint32(1) 
00238                                                       )
00239 
00240 process.ctfWithMaterialTracksP5TkCntFilter = cms.EDFilter("TrackCountFilter",
00241                                                           src = cms.InputTag('ctfWithMaterialTracksP5'),
00242                                                           minNumber = cms.uint32(1) 
00243                                                           )
00244 
00245 process.rsWithMaterialTracksP5TkCntFilter = cms.EDFilter("TrackCountFilter",
00246                                                          src = cms.InputTag('rsWithMaterialTracksP5'),
00247                                                          minNumber = cms.uint32(1) 
00248                                                          )
00249 
00250 process.cosmicMuonsBarrelOnlyTkFilter = cms.EDFilter("HLTMuonPointingFilter",
00251                                                      SALabel = cms.string("cosmicMuonsBarrelOnly"),
00252                                                      PropagatorName = cms.string("SteppingHelixPropagatorAny"),
00253                                                      radius = cms.double(90.0),
00254                                                      maxZ = cms.double(130.0)
00255                                                      )
00256 
00257 process.cosmicMuonsBarrelOnlyTkPath = cms.Path(process.cosmicMuonsBarrelOnlyTkFilter)
00258 process.cosmictrackfinderP5TkCntPath = cms.Path(process.cosmictrackfinderP5TkCntFilter)
00259 process.ctfWithMaterialTracksP5TkCntPath = cms.Path(process.ctfWithMaterialTracksP5TkCntFilter)
00260 process.rsWithMaterialTracksP5TkCntPath = cms.Path(process.rsWithMaterialTracksP5TkCntFilter)
00261 
00262 
00263 process.outTP = cms.OutputModule("PoolOutputModule",
00264                                outputCommands = cms.untracked.vstring('keep *','drop *_MEtoEDMConverter_*_*'),
00265                                SelectEvents = cms.untracked.PSet(SelectEvents = cms.vstring('cosmicMuonsBarrelOnlyTkPath',
00266                                                                                             'cosmictrackfinderP5TkCntPath',
00267                                                                                             'ctfWithMaterialTracksP5TkCntPath',
00268                                                                                             'rsWithMaterialTracksP5TkCntPath')),
00269                                dataset = cms.untracked.PSet(
00270                                          dataTier = cms.untracked.string('RAW-RECO'),
00271                                          filterName = cms.untracked.string('TrackingPointing')),
00272                                fileName = cms.untracked.string('/tmp/arizzi/trackerPointing.root')
00273                                )
00274 
00275 
00276 ####################################### Multi Muon ###########################################################
00277 
00278 process.multiCosmicMuonFilter = cms.EDFilter("TrackCountFilter",
00279                                              src = cms.InputTag('cosmicMuonsBarrelOnly'),
00280                                              minNumber = cms.uint32(5) 
00281                                              )
00282 
00283 process.multiLHCMuonFilter = cms.EDFilter("TrackCountFilter",
00284                                           src = cms.InputTag('lhcStandAloneMuonsBarrelOnly'),
00285                                           minNumber = cms.uint32(5) 
00286                                           )
00287 
00288 process.multiCosmicMuonPath = cms.Path(process.multiCosmicMuonFilter)
00289 process.multiLHCMuonPath = cms.Path(process.multiLHCMuonFilter)
00290 
00291 process.outMM = cms.OutputModule("PoolOutputModule",
00292                                 process.RECOEventContent,
00293                                SelectEvents = cms.untracked.PSet(SelectEvents = cms.vstring('multiCosmicMuonPath',
00294                                                                                             'multiLHCMuonPath')),
00295                                dataset = cms.untracked.PSet(
00296                                          dataTier = cms.untracked.string('RECO'),
00297                                          filterName = cms.untracked.string('multiCosmicMuon')),
00298                                fileName = cms.untracked.string('/tmp/arizzi/multiMuon.root')
00299                                )
00300 
00301 process.outMM.outputCommands.append('drop *_MEtoEDMConverter_*_*')
00302 
00303 
00304 
00305 
00306 
00307 import FWCore.ParameterSet.Config as cms
00308 import DPGAnalysis.Skims.HCALHighEnergyCombinedPath_cff
00309 
00310 #################################HCAL High Energy#########################################
00311 
00312 process.extend(DPGAnalysis.Skims.HCALHighEnergyCombinedPath_cff)
00313 
00314 process.outHCAL = cms.OutputModule("PoolOutputModule",
00315                                outputCommands = cms.untracked.vstring('keep *','drop *_MEtoEDMConverter_*_*'),
00316                                SelectEvents = cms.untracked.PSet(
00317     SelectEvents = cms.vstring("HCALHighEnergyPath")
00318     ),
00319                                dataset = cms.untracked.PSet(
00320                                dataTier = cms.untracked.string('RAW-RECO'),
00321                                filterName = cms.untracked.string('HCALHighEnergy')),
00322                                fileName = cms.untracked.string('/tmp/arizzi/HCALHighEnergy_filter.root')
00323                                )
00324 
00325 #################################ECAL High Energy#########################################
00326 process.skimming = cms.EDFilter("EcalSkim",
00327     #cosmic cluster energy threshold in GeV
00328     energyCutEB = cms.untracked.double(2.0),
00329     energyCutEE = cms.untracked.double(2.0),
00330     endcapClusterCollection = cms.InputTag("cosmicSuperClusters","CosmicEndcapSuperClusters"),
00331     barrelClusterCollection = cms.InputTag("cosmicSuperClusters","CosmicBarrelSuperClusters")
00332 )
00333 process.ecalPath = cms.Path(process.skimming)
00334 
00335 process.outECAL = cms.OutputModule("PoolOutputModule",
00336     process.RECOEventContent,                               
00337     fileName = cms.untracked.string('/tmp/arizzi/ecalSkim.root'),
00338     dataset = cms.untracked.PSet(
00339               dataTier = cms.untracked.string('RECO'),
00340               filterName = cms.untracked.string('ecalSkim_fromRECO')),
00341     SelectEvents = cms.untracked.PSet(
00342         SelectEvents = cms.vstring('ecalPath')
00343     )
00344 )
00345 
00346 process.outECAL.outputCommands.append('drop *_MEtoEDMConverter_*_*')
00347 
00348 ###############################StoppedHSCP################################
00349 
00350 process.outHSCP = cms.OutputModule("PoolOutputModule",
00351                                outputCommands = cms.untracked.vstring('keep *','drop *_MEtoEDMConverter_*_*'),
00352                                SelectEvents = cms.untracked.PSet(
00353     SelectEvents = cms.vstring("HLT_StoppedHSCP_*:HLT")
00354     ),
00355                                dataset = cms.untracked.PSet(
00356                                dataTier = cms.untracked.string('RAW-RECO'),
00357                                filterName = cms.untracked.string('StoppedHSCP')),
00358                                fileName = cms.untracked.string('/tmp/arizzi/StoppedHSCP_filter.root')
00359                                )
00360 
00361 
00362 process.outpath = cms.EndPath(process.outSP+process.outTP+process.outMM+process.outputSkim+process.outputSkimBField+process.outHCAL+process.outECAL+process.outHSCP)