File indexing completed on 2023-03-17 11:14:06
0001 from __future__ import print_function
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021 flat=False
0022
0023
0024
0025 import FWCore.ParameterSet.Config as cms
0026
0027 process = cms.Process('SIM')
0028
0029
0030 process.load('Configuration.StandardSequences.Services_cff')
0031 process.load('SimGeneral.HepPDTESSource.pythiapdt_cfi')
0032 process.load('FWCore.MessageService.MessageLogger_cfi')
0033 process.load('Configuration.EventContent.EventContent_cff')
0034 process.load('Configuration.StandardSequences.MagneticField_cff')
0035 process.load('Configuration.StandardSequences.Generator_cff')
0036 process.load('Configuration.StandardSequences.SimIdeal_cff')
0037 process.load('IOMC.EventVertexGenerators.VtxSmearedGauss_cfi')
0038 process.load('GeneratorInterface.Core.genFilterSummary_cff')
0039 process.load('Configuration.StandardSequences.EndOfProcess_cff')
0040 process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff')
0041
0042 from Configuration.Generator.Pythia8CommonSettings_cfi import *
0043 from Configuration.Generator.Pythia8CUEP8M1Settings_cfi import *
0044
0045 if flat:
0046 print('You choose the flat geometry')
0047 process.load('L1Trigger.TrackTrigger.TkOnlyFlatGeom_cff')
0048 else:
0049 print('You choose the tilted geometry')
0050 process.load('L1Trigger.TrackTrigger.TkOnlyTiltedGeom_cff')
0051
0052 process.maxEvents = cms.untracked.PSet(
0053 input = cms.untracked.int32(100)
0054 )
0055
0056
0057 process.source = cms.Source("EmptySource")
0058
0059
0060
0061
0062
0063 process.genstepfilter.triggerConditions=cms.vstring("generation_step")
0064 from Configuration.AlCa.GlobalTag import GlobalTag
0065 process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:phase2_realistic', '')
0066
0067
0068 process.RandomNumberGeneratorService.generator.initialSeed = 1
0069 process.RandomNumberGeneratorService.VtxSmeared.initialSeed = 2
0070 process.RandomNumberGeneratorService.g4SimHits.initialSeed = 3
0071
0072
0073
0074
0075
0076
0077
0078
0079 process.generator = cms.EDFilter("Pythia8GeneratorFilter",
0080 crossSection = cms.untracked.double(71.39e+09),
0081 maxEventsToPrint = cms.untracked.int32(0),
0082 pythiaPylistVerbosity = cms.untracked.int32(1),
0083 filterEfficiency = cms.untracked.double(1.0),
0084 pythiaHepMCVerbosity = cms.untracked.bool(False),
0085 comEnergy = cms.double(14000.0),
0086 PythiaParameters = cms.PSet(
0087 pythia8CommonSettingsBlock,
0088 pythia8CUEP8M1SettingsBlock,
0089 processParameters = cms.vstring(
0090 'SoftQCD:nonDiffractive = on',
0091 'SoftQCD:singleDiffractive = on',
0092 'SoftQCD:doubleDiffractive = on'),
0093 parameterSets = cms.vstring('pythia8CommonSettings',
0094 'pythia8CUEP8M1Settings',
0095 'processParameters',
0096 )
0097 )
0098 )
0099
0100
0101
0102
0103 process.RAWSIMoutput = cms.OutputModule("PoolOutputModule",
0104 splitLevel = cms.untracked.int32(0),
0105 eventAutoFlushCompressedSize = cms.untracked.int32(5242880),
0106 outputCommands = process.RAWSIMEventContent.outputCommands,
0107 fileName = cms.untracked.string('MBias_100_TkOnly.root'),
0108 dataset = cms.untracked.PSet(
0109 filterName = cms.untracked.string(''),
0110 dataTier = cms.untracked.string('GEN-SIM')
0111 ),
0112 SelectEvents = cms.untracked.PSet(
0113 SelectEvents = cms.vstring('generation_step')
0114 )
0115 )
0116
0117
0118 process.generation_step = cms.Path(process.pgen)
0119 process.simulation_step = cms.Path(process.psim)
0120 process.genfiltersummary_step= cms.EndPath(process.genFilterSummary)
0121 process.endjob_step = cms.EndPath(process.endOfProcess)
0122 process.RAWSIMoutput_step = cms.EndPath(process.RAWSIMoutput)
0123
0124 process.schedule = cms.Schedule(process.generation_step,process.genfiltersummary_step,process.simulation_step,process.endjob_step,process.RAWSIMoutput_step)
0125
0126
0127 for path in process.paths:
0128 getattr(process,path)._seq = process.generator * getattr(process,path)._seq
0129
0130
0131