Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:14:14

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 process = cms.Process("TEST")
0004 process.load("FWCore.Framework.test.cmsExceptionsFatal_cff")
0005 process.load("SimGeneral.HepPDTESSource.pythiapdt_cfi")
0006 #process.load("SimGeneral.HepPDTESSource.pdt_cfi")
0007 process.load("GeneratorInterface.TauolaInterface.TauSpinner_cfi")
0008 
0009 process.RandomNumberGeneratorService = cms.Service("RandomNumberGeneratorService",
0010                                                    generator = cms.PSet(initialSeed = cms.untracked.uint32(123456789),
0011                                                                         engineName = cms.untracked.string('HepJamesRandom')
0012                                                                         ),
0013                                                    TauSpinnerGen  = cms.PSet(initialSeed = cms.untracked.uint32(123456789),
0014                                                                              engineName = cms.untracked.string('HepJamesRandom')
0015                                                                              
0016                                                                              )
0017                                                    )
0018 process.randomEngineStateProducer = cms.EDProducer("RandomEngineStateProducer")
0019 
0020 process.Timing=cms.Service("Timing",
0021                            summaryOnly=cms.untracked.bool(True))
0022 
0023 
0024 # The following three lines reduce the clutter of repeated printouts
0025 # of the same exception message.
0026 process.load("FWCore.MessageLogger.MessageLogger_cfi")
0027 
0028 
0029 
0030 
0031 process.maxEvents = cms.untracked.PSet(input = cms.untracked.int32(100))
0032 
0033 process.source = cms.Source("EmptySource")
0034 
0035 from Configuration.Generator.PythiaUESettings_cfi import *
0036 process.generator = cms.EDFilter("Pythia6GeneratorFilter",
0037                                  pythiaHepMCVerbosity = cms.untracked.bool(True),
0038                                  maxEventsToPrint = cms.untracked.int32(0),
0039                                  pythiaPylistVerbosity = cms.untracked.int32(1),
0040                                      # this shows how to turn ON some of the general Py6 printouts, like banner...
0041                                  ## --> displayPythiaBanner = cms.untracked.bool(True),
0042                                  ## --> displayPythiaCards = cms.untracked.bool(True),
0043                                  comEnergy = cms.double(7000.0),
0044                                  
0045                                  ExternalDecays = cms.PSet(
0046     Tauola = cms.untracked.PSet(
0047     # these settings below exemplfy how to use "native" Tauola approach:
0048     # one MUST set mdtau=1 !!! then pjak1 & pjak2 will translate into
0049     # native variables jak1 & jak2 (jak1/jak2=4 means that both tau's
0050     # decay into the rho-mode
0051     #
0052     UseTauolaPolarization = cms.bool(True),
0053     InputCards = cms.PSet
0054     (
0055     pjak1 = cms.int32(0),
0056     pjak2 = cms.int32(0),
0057     mdtau = cms.int32(0) # generic tau decays
0058     ## mdtau = cms.int32(240) # (any) tau -> nu pi+-
0059     )
0060     #           TauolaDefaultInputCards,
0061     #          TauolaPolar
0062     ),
0063     parameterSets = cms.vstring('Tauola')
0064     ),
0065                                  PythiaParameters = cms.PSet(
0066     pythiaUESettingsBlock,
0067     processParameters = cms.vstring('MSEL        = 0    !User defined processes',
0068                                     'MSUB(2)     = 1    !W production',
0069                                     'MDME(190,1) = 0    !W decay into dbar u',
0070                                     'MDME(191,1) = 0    !W decay into dbar c',
0071                                     'MDME(192,1) = 0    !W decay into dbar t',
0072                                     'MDME(194,1) = 0    !W decay into sbar u',
0073                                     'MDME(195,1) = 0    !W decay into sbar c',
0074                                     'MDME(196,1) = 0    !W decay into sbar t',
0075                                     'MDME(198,1) = 0    !W decay into bbar u',
0076                                     'MDME(199,1) = 0    !W decay into bbar c',
0077                                     'MDME(200,1) = 0    !W decay into bbar t',
0078                                     'MDME(205,1) = 0    !W decay into bbar tp',
0079                                     'MDME(206,1) = 0    !W decay into e+ nu_e',
0080                                     'MDME(207,1) = 0    !W decay into mu+ nu_mu',
0081                                     'MDME(208,1) = 1    !W decay into tau+ nu_tau'),
0082     # This is a vector of ParameterSet names to be read, in this order
0083     parameterSets = cms.vstring('pythiaUESettings',
0084                                 'processParameters')
0085     )
0086                                  )
0087 
0088 # Produce PDF weights (maximum is 3)
0089 process.pdfWeights = cms.EDProducer("PdfWeightProducer",
0090                                     # Fix POWHEG if buggy (this PDF set will also appear on output,
0091                                     # so only two more PDF sets can be added in PdfSetNames if not "")
0092                                     #FixPOWHEG = cms.untracked.string("cteq66.LHgrid"),
0093                                     #GenTag = cms.untracked.InputTag("genParticles"),
0094                                     PdfInfoTag = cms.untracked.InputTag("VtxSmeared"),
0095                                     PdfSetNames = cms.untracked.vstring(
0096     #    "cteq66.LHgrid"
0097     #    , "MRST2006nnlo.LHgrid" ,
0098         "MSTW2008nnlo90cl.LHgrid"
0099         )
0100                                     )
0101 
0102 
0103 process.p1 = cms.Path( process.TauSpinnerGen )
0104 
0105 process.GEN = cms.OutputModule("PoolOutputModule",
0106                                fileName = cms.untracked.string('Test_Py6_W2TauNu_Tauola.root')
0107                                )
0108 
0109 process.p = cms.Path(process.generator)
0110 
0111 process.outpath = cms.EndPath(process.GEN)
0112 process.p1 = cms.Path(process.randomEngineStateProducer*process.TauSpinnerGen)
0113 process.schedule = cms.Schedule(process.p, process.p1, process.outpath)
0114