CMS 3D CMS Logo

/afs/cern.ch/work/a/aaltunda/public/www/CMSSW_6_2_5/src/Configuration/DataProcessing/python/Impl/prodmc.py

Go to the documentation of this file.
00001 #!/usr/bin/env python
00002 """
00003 _prodmc_
00004 
00005 Scenario supporting MC production
00006 
00007 """
00008 
00009 import os
00010 import sys
00011 
00012 from Configuration.DataProcessing.Scenario import *
00013 import FWCore.ParameterSet.Config as cms
00014 
00015 class prodmc(Scenario):
00016     """
00017     _prodmc_
00018 
00019     Implement configuration building for MC production 
00020 
00021     """
00022 
00023     def dqmHarvesting(self, datasetName, runNumber, globalTag, **args):
00024         """
00025         _dqmHarvesting_
00026 
00027         DQM Harvesting for MC production
00028 
00029         """
00030         options = defaultOptions
00031         options.scenario = "pp"
00032         options.step = "HARVESTING:validationprodHarvesting"
00033         options.isMC = True
00034         options.isData = False
00035         options.beamspot = None
00036         options.eventcontent = None
00037         options.name = "EDMtoMEConvert"
00038         options.conditions = "FrontierConditions_GlobalTag,%s" % globalTag
00039         options.arguments = ""
00040         options.evt_type = ""
00041         options.filein = []
00042  
00043         process = cms.Process("HARVESTING")
00044         if args.get('newDQMIO', False):
00045             process.source = cms.Source("DQMRootSource")
00046         else:
00047             process.source = cms.Source("PoolSource")
00048         configBuilder = ConfigBuilder(options, process = process)
00049         configBuilder.prepare()
00050 
00051         #
00052         # customise process for particular job
00053         #
00054         process.source.processingMode = cms.untracked.string('RunsAndLumis')
00055         process.source.fileNames = cms.untracked(cms.vstring())
00056         process.maxEvents.input = -1
00057         process.dqmSaver.workflow = datasetName
00058         if args.has_key('referenceFile') and args.get('referenceFile', ''):
00059             process.DQMStore.referenceFileName = \
00060                                 cms.untracked.string(args['referenceFile'])
00061         
00062         return process