Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 13:29:44

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 process = cms.Process("TEST")
0004 process.load("FWCore.Framework.test.cmsExceptionsFatal_cff")
0005 process.load("Configuration.Generator.PythiaUESettings_cfi")
0006 
0007 process.RandomNumberGeneratorService = cms.Service("RandomNumberGeneratorService",
0008     generator = cms.PSet(
0009         initialSeed = cms.untracked.uint32(123456789),
0010         engineName = cms.untracked.string('HepJamesRandom')
0011     )
0012 )
0013 
0014 # The following three lines reduce the clutter of repeated printouts
0015 # of the same exception message.
0016 process.load("FWCore.MessageLogger.MessageLogger_cfi")
0017 
0018 process.MessageLogger.cerr.enableStatistics = False
0019 
0020 
0021 process.maxEvents = cms.untracked.PSet(input = cms.untracked.int32(500))
0022 
0023 process.source = cms.Source("EmptySource")
0024 
0025 from Configuration.Generator.PythiaUESettings_cfi import *
0026 
0027 process.generator = cms.EDFilter("Pythia6GeneratorFilter",
0028     pythiaHepMCVerbosity = cms.untracked.bool(True),
0029     maxEventsToPrint = cms.untracked.int32(5),
0030     pythiaPylistVerbosity = cms.untracked.int32(1),
0031     comEnergy = cms.double(7000.0),
0032     ExternalDecays = cms.PSet(
0033         EvtGen1 = cms.untracked.PSet(
0034              decay_table = cms.string('GeneratorInterface/EvtGenInterface/data/DECAY_2010.DEC'),
0035              particle_property_file = cms.FileInPath('GeneratorInterface/EvtGenInterface/data/evt.pdl'),
0036              #user_decay_files = cms.vstring('DECAY_2010.DEC'),
0037              user_decay_file = cms.vstring('GeneratorInterface/ExternalDecays/data/LambdaB_JPsiLambda_ppi.dec'),
0038              list_forced_decays = cms.vstring('MyLambda_b0','Myanti-Lambda_b0'),
0039              particles_to_polarize = cms.untracked.vint32(5122, -5122),
0040              particle_polarizations = cms.untracked.vdouble(-0.4, -0.4),
0041              operates_on_particles = cms.vint32(0), # 0 (zero) means default list (hardcoded), the list of PDG IDs can be put here
0042          use_default_decay = cms.untracked.bool(False)
0043              # decay_table = cms.FileInPath('GeneratorInterface/ExternalDecays/data/DECAY_NOLONGLIFE.DEC')
0044              # decay_table = cms.FileInPath('GeneratorInterface/ExternalDecays/data/DECAY.DEC')
0045              # user_decay_file = cms.FileInPath('GeneratorInterface/ExternalDecays/data/Bs_DsStarlnu_DsGamma.dec')
0046              ),
0047         parameterSets = cms.vstring('EvtGen1')
0048     ),
0049     PythiaParameters = cms.PSet(
0050 
0051         process.pythiaUESettingsBlock,
0052         bbbarSettings = cms.vstring('MSEL=5          ! bbbar '),
0053         # This is a vector of ParameterSet names to be read, in this order
0054         parameterSets = cms.vstring('pythiaUESettings','bbbarSettings')
0055     )
0056 )
0057 
0058 process.GEN = cms.OutputModule("PoolOutputModule",
0059     fileName = cms.untracked.string('/tmp/TestEvtGen.root')
0060 )
0061 
0062 process.p = cms.Path(process.generator)
0063 process.outpath = cms.EndPath(process.GEN)
0064 
0065 process.schedule = cms.Schedule(process.p, process.outpath)