Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 13:07:22

0001 # A script to produce Z events using pythia8 and with FSR added by Photos++
0002 # This script is to be used to compare with DYnorad_Tune4C_13TeV_pythia8.py to demonstrate/test
0003 # the additions of FSR by Photos++
0004 
0005 import FWCore.ParameterSet.Config as cms
0006 
0007 process = cms.Process('VALIDATION')
0008 
0009 # import of standard configurations
0010 process.load('Configuration.StandardSequences.Services_cff')
0011 process.load('SimGeneral.HepPDTESSource.pythiapdt_cfi')
0012 process.load('FWCore.MessageService.MessageLogger_cfi')
0013 process.load('Configuration.EventContent.EventContent_cff')
0014 process.load('SimGeneral.MixingModule.mixNoPU_cfi')
0015 process.load('Configuration.StandardSequences.GeometryRecoDB_cff')
0016 process.load('Configuration.StandardSequences.MagneticField_38T_cff')
0017 process.load('Configuration.StandardSequences.Generator_cff')
0018 process.load('IOMC.EventVertexGenerators.VtxSmearedRealistic8TeVCollision_cfi')
0019 process.load('GeneratorInterface.Core.genFilterSummary_cff')
0020 process.load('Configuration.StandardSequences.Validation_cff')
0021 process.load('Configuration.StandardSequences.EndOfProcess_cff')
0022 process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff')
0023 
0024 process.maxEvents = cms.untracked.PSet(
0025     input = cms.untracked.int32(3000)
0026 )
0027 
0028 # Input source
0029 process.source = cms.Source("EmptySource")
0030 
0031 process.options = cms.untracked.PSet(
0032 
0033 )
0034 
0035 # Production Info
0036 process.configurationMetadata = cms.untracked.PSet(
0037     version = cms.untracked.string('$Revision: 1.19 $'),
0038     annotation = cms.untracked.string('Configuration/Generator/python/ThirteenTeV/WToMuNu_M_500_Tune4C_13TeV_pythia8_cfi.py nevts:100000'),
0039     name = cms.untracked.string('Applications')
0040 )
0041 
0042 # Output definition
0043 
0044 process.RAWSIMoutput = cms.OutputModule("PoolOutputModule",
0045     splitLevel = cms.untracked.int32(0),
0046     eventAutoFlushCompressedSize = cms.untracked.int32(5242880),
0047     outputCommands = process.RAWSIMEventContent.outputCommands,
0048     fileName = cms.untracked.string('DYphotospp_Tune4C_13TeV_pythia8_cfi_py_GEN_VALIDATION.root'),
0049     dataset = cms.untracked.PSet(
0050         filterName = cms.untracked.string(''),
0051         dataTier = cms.untracked.string('GEN')
0052     ),
0053     SelectEvents = cms.untracked.PSet(
0054         SelectEvents = cms.vstring('generation_step')
0055     )
0056 )
0057 
0058 # Additional output definition
0059 
0060 # Other statements
0061 process.genstepfilter.triggerConditions=cms.vstring("generation_step")
0062 process.mix.playback = True
0063 process.mix.digitizers = cms.PSet()
0064 for a in process.aliases: delattr(process, a)
0065 from Configuration.AlCa.GlobalTag import GlobalTag
0066 process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:startup', '')
0067 
0068 process.generator = cms.EDFilter("Pythia8GeneratorFilter",
0069                                  ExternalDecays = cms.PSet(
0070     Photospp = cms.untracked.PSet(
0071     parameterSets = cms.vstring("setExponentiation","setInfraredCutOff","setMomentumConservationThreshold"),
0072     setExponentiation = cms.bool(True),
0073     setInfraredCutOff = cms.double(0.00011),
0074     setMomentumConservationThreshold = cms.double(20.0) # 0.5GeV
0075     ),
0076     parameterSets = cms.vstring( "Photospp")
0077     ),
0078                  
0079     UseExternalGenerators = cms.untracked.bool(True),
0080     pythiaPylistVerbosity = cms.untracked.int32(1),
0081     filterEfficiency = cms.untracked.double(1),
0082     pythiaHepMCVerbosity = cms.untracked.bool(False),
0083     comEnergy = cms.double(13000.0),
0084     crossSection = cms.untracked.double(0.2188),
0085     maxEventsToPrint = cms.untracked.int32(1),
0086     PythiaParameters = cms.PSet(
0087         processParameters = cms.vstring('Main:timesAllowErrors = 10000', 
0088                     'ParticleDecays:limitTau0 = on', 
0089                     'ParticleDecays:tauMax = 10', 
0090                     'Tune:ee 3', 
0091                     'Tune:pp 5',
0092                     'PartonLevel:FSR = off',
0093                     'WeakSingleBoson:ffbar2gmZ = on', 
0094                     '23:onMode = off', 
0095                     '23:onIfAny = 13', 
0096                     '23:mMin = 50.', 
0097                     '23:mMax = 120.'
0098                     ),
0099         parameterSets = cms.vstring('processParameters')
0100     )
0101 )
0102 
0103 process.genParticles = cms.EDProducer("GenParticleProducer",
0104     saveBarCodes = cms.untracked.bool(True),
0105     src = cms.InputTag("generator:unsmeared"),
0106     abortOnUnknownPDGCode = cms.untracked.bool(False)
0107 )
0108 process.printTree1 = cms.EDAnalyzer("ParticleListDrawer",
0109     src = cms.InputTag("genParticles"),
0110     maxEventsToPrint  = cms.untracked.int32(10)
0111 )
0112 
0113 process.ProductionFilterSequence = cms.Sequence(process.generator*process.genParticles*process.printTree1)
0114 
0115 # Path and EndPath definitions
0116 process.generation_step = cms.Path(process.pgen)
0117 process.genfiltersummary_step = cms.EndPath(process.genFilterSummary)
0118 process.validation_step = cms.EndPath(process.genstepfilter+process.genvalid_all)
0119 process.endjob_step = cms.EndPath(process.endOfProcess)
0120 process.RAWSIMoutput_step = cms.EndPath(process.RAWSIMoutput)
0121 
0122 # Schedule definition
0123 process.schedule = cms.Schedule(process.generation_step,process.genfiltersummary_step,process.validation_step,process.endjob_step,process.RAWSIMoutput_step)
0124 # filter all path with the production filter sequence
0125 for path in process.paths:
0126     getattr(process,path)._seq = process.ProductionFilterSequence * getattr(process,path)._seq 
0127 
0128 # customisation of the process.
0129 
0130 # Automatic addition of the customisation function from SimGeneral.MixingModule.fullMixCustomize_cff
0131 from SimGeneral.MixingModule.fullMixCustomize_cff import setCrossingFrameOn 
0132 
0133 #call to customisation function setCrossingFrameOn imported from SimGeneral.MixingModule.fullMixCustomize_cff
0134 process = setCrossingFrameOn(process)
0135 
0136 # End of customisation functions