Back to home page

Project CMSSW displayed by LXR

 
 

    


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

0001 import FWCore.ParameterSet.Config as cms
0002 import FWCore.ParameterSet.VarParsing as VarParsing
0003 
0004 process = cms.Process("APVShotAnalyzer")
0005 
0006 #prepare options
0007 
0008 options = VarParsing.VarParsing("analysis")
0009 
0010 options.register ('globalTag',
0011                   "DONOTEXIST",
0012                   VarParsing.VarParsing.multiplicity.singleton, # singleton or list
0013                   VarParsing.VarParsing.varType.string,          # string, int, or float
0014                   "GlobalTag")
0015 
0016 options.parseArguments()
0017 
0018 #
0019 
0020 process.options = cms.untracked.PSet(
0021     wantSummary = cms.untracked.bool(True),
0022     fileMode = cms.untracked.string("FULLMERGE")
0023     )
0024 
0025 process.load("FWCore.MessageService.MessageLogger_cfi")
0026 
0027 process.MessageLogger.cout.enable = cms.untracked.bool(True)
0028 process.MessageLogger.cout.threshold = cms.untracked.string("INFO")
0029 process.MessageLogger.cout.default = cms.untracked.PSet(
0030     limit = cms.untracked.int32(10000000)
0031     )
0032 process.MessageLogger.cout.FwkReport = cms.untracked.PSet(
0033     reportEvery = cms.untracked.int32(10000)
0034     )
0035 
0036 process.MessageLogger.cerr.enable = cms.untracked.bool(True)
0037 process.MessageLogger.cerr.threshold = cms.untracked.string("WARNING")
0038 process.MessageLogger.cerr.default = cms.untracked.PSet(
0039     limit = cms.untracked.int32(10000000)
0040     )
0041 process.MessageLogger.cerr.FwkReport = cms.untracked.PSet(
0042     reportEvery = cms.untracked.int32(100000)
0043     )
0044 
0045 process.MessageLogger.debugModules=cms.untracked.vstring("apvshotsanalyzer")
0046 #------------------------------------------------------------------
0047 
0048 process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) )
0049 
0050 process.source = cms.Source("PoolSource",
0051                     fileNames = cms.untracked.vstring(options.inputFiles),
0052 #                    skipBadFiles = cms.untracked.bool(True),
0053                     inputCommands = cms.untracked.vstring("keep *", "drop *_MEtoEDMConverter_*_*")
0054                     )
0055 
0056 #--------------------------------------
0057 process.load("Configuration.StandardSequences.RawToDigi_Data_cff")
0058 process.load("Configuration.StandardSequences.MagneticField_cff")
0059 process.load("Configuration.StandardSequences.GeometryRecoDB_cff")
0060 process.load("Configuration.StandardSequences.Reconstruction_cff")
0061 
0062 process.froml1abcHEs = cms.EDProducer("EventWithHistoryProducerFromL1ABC",
0063                                       l1ABCCollection=cms.InputTag("scalersRawToDigi")
0064                                       )
0065 process.load("DPGAnalysis.SiStripTools.apvcyclephaseproducerfroml1tsDB_cfi")
0066 process.load("DPGAnalysis.SiStripTools.eventtimedistribution_cfi")
0067 process.eventtimedistribution.historyProduct = cms.InputTag("froml1abcHEs")
0068 
0069 process.eventtimedistrFH1 = process.eventtimedistribution.clone()
0070 process.eventtimedistrFH2 = process.eventtimedistribution.clone()
0071 
0072 process.seqEventHistoryReco = cms.Sequence(process.froml1abcHEs + process.APVPhases)
0073 process.seqEventHistory = cms.Sequence(process.eventtimedistribution)
0074 process.seqEventHistoryFH1 = cms.Sequence(process.eventtimedistrFH1)
0075 process.seqEventHistoryFH2 = cms.Sequence(process.eventtimedistrFH2)
0076 
0077 process.seqProducers = cms.Sequence(process.seqEventHistoryReco)
0078 
0079 process.load("DPGAnalysis.SiStripTools.apvshotsanalyzer_cfi")
0080 process.apvshotsanalyzer.historyProduct = cms.InputTag("froml1abcHEs")
0081 process.apvshotsanalyzer.useCabling = cms.untracked.bool(True)
0082 process.apvshotsanalyzerFH1 = process.apvshotsanalyzer.clone()
0083 process.apvshotsanalyzerFH2 = process.apvshotsanalyzer.clone()
0084 
0085 process.FrameHeader1Events = cms.EDFilter('EventWithHistoryEDFilter',
0086                                           commonConfiguration = cms.untracked.PSet(
0087                                                                                    historyProduct = cms.untracked.InputTag("froml1abcHEs"),
0088                                                                                    APVPhaseLabel = cms.untracked.string("APVPhases"),
0089                                                                                    partitionName = cms.untracked.string("Any")
0090                                                                                     ),
0091                                           filterConfigurations = cms.untracked.VPSet(
0092                                                                                      cms.PSet(
0093                                                                                               dbxInCycleRangeLtcyAware = cms.untracked.vint32(298,300)
0094                                                                                               )
0095                                                                                      )
0096                                           )
0097 process.FrameHeader2Events = cms.EDFilter('EventWithHistoryEDFilter',
0098                                           commonConfiguration = cms.untracked.PSet(
0099                                                                                    historyProduct = cms.untracked.InputTag("froml1abcHEs"),
0100                                                                                    APVPhaseLabel = cms.untracked.string("APVPhases"),
0101                                                                                    partitionName = cms.untracked.string("Any")
0102                                                                                     ),
0103                                           filterConfigurations = cms.untracked.VPSet(
0104                                                                                      cms.PSet(
0105                                                                                               dbxInCycleRangeLtcyAware = cms.untracked.vint32(301,303)
0106                                                                                               )
0107                                                                                      )
0108                                           )
0109 
0110 
0111 process.load("DQM.SiStripCommon.TkHistoMap_cff")
0112 
0113 process.p0 = cms.Path(
0114    process.siStripDigis + process.siStripZeroSuppression +
0115    process.scalersRawToDigi +
0116    process.seqProducers +
0117    process.seqEventHistory +
0118    process.apvshotsanalyzer
0119    )
0120 process.pfh1 = cms.Path(
0121    process.siStripDigis + process.siStripZeroSuppression +
0122    process.scalersRawToDigi +
0123    process.seqProducers +
0124    process.FrameHeader1Events +
0125    process.seqEventHistoryFH1 +
0126    process.apvshotsanalyzerFH1
0127    )
0128 process.pfh2 = cms.Path(
0129    process.siStripDigis + process.siStripZeroSuppression +
0130    process.scalersRawToDigi +
0131    process.seqProducers +
0132    process.FrameHeader2Events +
0133    process.seqEventHistoryFH2 +
0134    process.apvshotsanalyzerFH2
0135    )
0136 
0137 #----GlobalTag ------------------------
0138 
0139 process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
0140 from Configuration.AlCa.GlobalTag import GlobalTag
0141 process.GlobalTag = GlobalTag(process.GlobalTag, options.globalTag, '')
0142 
0143 
0144 process.TFileService = cms.Service('TFileService',
0145                                    fileName = cms.string('APVShotAnalyzer.root')
0146                                    )
0147 
0148 #print process.dumpPython()