Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:30:38

0001 from __future__ import print_function
0002 import FWCore.ParameterSet.Config as cms
0003 
0004 # here we define part of the configuration of MixingModule
0005 # the rest, notably:
0006 #            "input","bunchspace","minBunch","maxBunch"
0007 # is to be retrieved from database
0008 # see: https://twiki.cern.ch/twiki/bin/viewauth/CMS/PdmVRunDependentMC
0009 
0010 # configuration to model pileup for initial physics phase
0011 from SimGeneral.MixingModule.mixObjects_cfi import theMixObjects 
0012 from SimGeneral.MixingModule.mixPoolSource_cfi import * 
0013 from SimGeneral.MixingModule.digitizers_cfi import *
0014 
0015 mix = cms.EDProducer("MixingModule",
0016 
0017     # this is where you activate reading from DB of: "input","bunchspace","minBunch","maxBunch"
0018     readDB = cms.bool(True),
0019 
0020     digitizers = cms.PSet(theDigitizers),                 
0021     LabelPlayback = cms.string(''),
0022     maxBunch = cms.int32(314159),    ## these three parameters are needed at instantiation time, BUT the actual value will NOT be used
0023     minBunch = cms.int32(-314159),   ## actual values will be retrieved from database
0024 
0025     bunchspace = cms.int32(314159),  ## [ditto] 
0026     mixProdStep1 = cms.bool(False),
0027     mixProdStep2 = cms.bool(False),
0028 
0029     playback = cms.untracked.bool(False),
0030     useCurrentProcessOnly = cms.bool(False),
0031 
0032     input = cms.SecSource("EmbeddedRootSource",
0033         type = cms.string('readDB'),
0034         sequential = cms.untracked.bool(False),                          
0035         fileNames = FileNames 
0036     ),
0037 
0038     mixObjects = cms.PSet(theMixObjects)                 
0039     #mixObjects = cms.PSet(
0040     #    mixCH = cms.PSet(
0041     #        mixCaloHits
0042     #    ),
0043     #    mixTracks = cms.PSet(
0044     #        mixSimTracks
0045     #    ),
0046     #    mixVertices = cms.PSet(
0047     #        mixSimVertices
0048     #    ),
0049     #    mixSH = cms.PSet(
0050     #        mixSimHits
0051     #    ),
0052     #    mixHepMC = cms.PSet(
0053     #        mixHepMCProducts
0054     #    )
0055     #)
0056 )
0057 
0058 
0059 
0060 if mix.readDB == cms.bool(True):
0061     print(' ')
0062     print('MixingModule will be configured from db; this is mix.readDB : ',mix.readDB)
0063 else :
0064     print(' ')
0065     print('MixingModule is NOT going to be configured from db; this is mix.readDB : ',mix.readDB)