Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 13:09:15

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 process = cms.Process("SKIM")
0004 
0005 process.configurationMetadata = cms.untracked.PSet(
0006     version = cms.untracked.string('$Revision: 1.3 $'),
0007     name = cms.untracked.string('$Source: /cvs_server/repositories/CMSSW/CMSSW/DPGAnalysis/Skims/python/GOODCOLL_filter_cfg.py,v $'),
0008     annotation = cms.untracked.string('Combined MinBias skim')
0009 )
0010 
0011 #
0012 #
0013 # This is for testing purposes.
0014 #
0015 #
0016 process.source = cms.Source("PoolSource",
0017                             fileNames = cms.untracked.vstring(
0018 # run 136066 lumi~500
0019 '/store/data/Run2010A/MinimumBias/RECO/v1/000/136/066/18F6DB82-5566-DF11-B289-0030487CAF0E.root'),
0020 )
0021 
0022 process.source.inputCommands = cms.untracked.vstring("keep *", "drop *_MEtoEDMConverter_*_*", "drop L1GlobalTriggerObjectMapRecord_hltL1GtObjectMap__HLT")
0023 
0024 process.maxEvents = cms.untracked.PSet(
0025     input = cms.untracked.int32(1000)
0026 )
0027 
0028 
0029 #------------------------------------------
0030 # Load standard sequences.
0031 #------------------------------------------
0032 process.load('Configuration/StandardSequences/MagneticField_AutoFromDBCurrent_cff')
0033 process.load('Configuration/StandardSequences/GeometryIdeal_cff')
0034 
0035 
0036 process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
0037 process.GlobalTag.globaltag = 'GR10_P_V6::All' 
0038 
0039 process.load("Configuration/StandardSequences/RawToDigi_Data_cff")
0040 process.load("Configuration/StandardSequences/Reconstruction_cff")
0041 process.load('Configuration/EventContent/EventContent_cff')
0042 
0043 #drop collections created on the fly
0044 process.RECOEventContent.outputCommands.append("drop *_MEtoEDMConverter_*_*")
0045 process.RECOEventContent.outputCommands.append("drop *_*_*_SKIM")
0046 
0047 #
0048 #  Load common sequences
0049 #
0050 process.load('L1TriggerConfig.L1GtConfigProducers.L1GtTriggerMaskAlgoTrigConfig_cff')
0051 process.load('L1TriggerConfig.L1GtConfigProducers.L1GtTriggerMaskTechTrigConfig_cff')
0052 process.load('HLTrigger/HLTfilters/hltLevel1GTSeed_cfi')
0053 
0054 ##################################good collisions############################################
0055 # This filter select ~73% of events in MinBias PD
0056 
0057 process.L1T1coll=process.hltLevel1GTSeed.clone()
0058 process.L1T1coll.L1TechTriggerSeeding = cms.bool(True)
0059 process.L1T1coll.L1SeedsLogicalExpression = cms.string('0 AND (40 OR 41) AND NOT (36 OR 37 OR 38 OR 39) AND NOT ((42 AND NOT 43) OR (43 AND NOT 42))')
0060 
0061 process.l1tcollpath = cms.Path(process.L1T1coll)
0062 
0063 process.primaryVertexFilter = cms.EDFilter("VertexSelector",
0064    src = cms.InputTag("offlinePrimaryVertices"),
0065    cut = cms.string("!isFake && ndof > 4 && abs(z) <= 15 && position.Rho <= 2"), # tracksSize() > 3 for the older cut
0066    filter = cms.bool(True),   # otherwise it won't filter the events, just produce an empty vertex collection.
0067 )
0068 
0069 
0070 process.noscraping = cms.EDFilter("FilterOutScraping",
0071 applyfilter = cms.untracked.bool(True),
0072 debugOn = cms.untracked.bool(False),
0073 numtrack = cms.untracked.uint32(10),
0074 thresh = cms.untracked.double(0.25)
0075 )
0076 
0077 process.selectHF = cms.EDFilter("SelectHFMinBias",
0078 applyfilter = cms.untracked.bool(True)
0079 )
0080 
0081 process.goodvertex=cms.Path(process.primaryVertexFilter+process.noscraping)
0082 process.selecthf = cms.Path(process.selectHF)
0083 
0084 process.collout = cms.OutputModule("PoolOutputModule",
0085     fileName = cms.untracked.string('good_coll_reco.root'),
0086     outputCommands = process.RECOEventContent.outputCommands,
0087     dataset = cms.untracked.PSet(
0088               dataTier = cms.untracked.string('RECO'),
0089               filterName = cms.untracked.string('GOODCOLL')),
0090     SelectEvents = cms.untracked.PSet(
0091         SelectEvents = cms.vstring('goodvertex','l1tcollpath','selecthf')
0092     )
0093 )
0094 
0095 
0096 ###########################################################################
0097 process.options = cms.untracked.PSet(
0098  wantSummary = cms.untracked.bool(True)
0099 )
0100 
0101 process.outpath = cms.EndPath(process.collout)
0102 
0103