File indexing completed on 2024-06-22 02:23:46
0001
0002
0003
0004
0005
0006
0007
0008 import FWCore.ParameterSet.Config as cms
0009 import os, sys, imp, re
0010 import FWCore.ParameterSet.VarParsing as VarParsing
0011
0012
0013
0014 options = VarParsing.VarParsing('standard')
0015 options.register('type',
0016 "V17",
0017 VarParsing.VarParsing.multiplicity.singleton,
0018 VarParsing.VarParsing.varType.string,
0019 "type of operations: V16, V17, V17n, V17ng, V18, V18n, V18ng")
0020
0021
0022 options.parseArguments()
0023 print(options)
0024
0025 if (options.type == "V18"):
0026 from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
0027 process = cms.Process("HGCalTest",Phase2C22I13M9)
0028 elif (options.type == "V18n"):
0029 from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
0030 process = cms.Process("HGCalTest",Phase2C22I13M9)
0031 elif (options.type == "V18ng"):
0032 from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
0033 process = cms.Process("HGCalTest",Phase2C22I13M9)
0034 else:
0035 from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9
0036 process = cms.Process("HGCalTest",Phase2C17I13M9)
0037
0038 geomFile = "Geometry.HGCalCommonData.testHGCal" + options.type + "XML_cfi"
0039 outFile = "file:step1" + options.type + "DDD.root"
0040 print("Geometry file: ", geomFile)
0041 print("Output file: ", outFile)
0042
0043
0044 process.load(geomFile)
0045 process.load('Configuration.StandardSequences.Services_cff')
0046 process.load('SimGeneral.HepPDTESSource.pythiapdt_cfi')
0047 process.load('FWCore.MessageService.MessageLogger_cfi')
0048 process.load('Configuration.EventContent.EventContent_cff')
0049 process.load('SimGeneral.MixingModule.mixNoPU_cfi')
0050 process.load('Geometry.EcalCommonData.ecalSimulationParameters_cff')
0051 process.load('Geometry.HcalCommonData.hcalDDDSimConstants_cff')
0052 process.load('Geometry.HGCalCommonData.hgcalParametersInitialization_cfi')
0053 process.load('Geometry.HGCalCommonData.hgcalNumberingInitialization_cfi')
0054 process.load('Geometry.TrackerNumberingBuilder.trackerNumberingGeometry_cff')
0055 process.load('SLHCUpgradeSimulations.Geometry.fakePhase2OuterTrackerConditions_cff')
0056 process.load('Geometry.MuonNumbering.muonGeometryConstants_cff')
0057 process.load('Geometry.MuonNumbering.muonOffsetESProducer_cff')
0058 process.load('Geometry.MTDNumberingBuilder.mtdNumberingGeometry_cff')
0059 process.load('Configuration.StandardSequences.MagneticField_cff')
0060 process.load('Configuration.StandardSequences.Generator_cff')
0061 process.load('IOMC.EventVertexGenerators.VtxSmearedHLLHC14TeV_cfi')
0062 process.load('GeneratorInterface.Core.genFilterSummary_cff')
0063 process.load('Configuration.StandardSequences.SimIdeal_cff')
0064 process.load('Configuration.StandardSequences.EndOfProcess_cff')
0065 process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff')
0066
0067 if 'MessageLogger' in process.__dict__:
0068 process.MessageLogger.HGCalGeom=dict()
0069 process.MessageLogger.HGCSim=dict()
0070
0071
0072 process.maxEvents = cms.untracked.PSet(
0073 input = cms.untracked.int32(100),
0074 output = cms.optional.untracked.allowed(cms.int32,cms.PSet)
0075 )
0076
0077 process.Timing = cms.Service("Timing")
0078
0079
0080 process.source = cms.Source("EmptySource")
0081
0082 process.options = cms.untracked.PSet(
0083 IgnoreCompletely = cms.untracked.vstring(),
0084 Rethrow = cms.untracked.vstring(),
0085 TryToContinue = cms.untracked.vstring(),
0086 allowUnscheduled = cms.obsolete.untracked.bool,
0087 canDeleteEarly = cms.untracked.vstring(),
0088 deleteNonConsumedUnscheduledModules = cms.untracked.bool(True),
0089 emptyRunLumiMode = cms.obsolete.untracked.string,
0090 eventSetup = cms.untracked.PSet(
0091 forceNumberOfConcurrentIOVs = cms.untracked.PSet(
0092 allowAnyLabel_=cms.required.untracked.uint32
0093 ),
0094 numberOfConcurrentIOVs = cms.untracked.uint32(1)
0095 ),
0096 fileMode = cms.untracked.string('FULLMERGE'),
0097 forceEventSetupCacheClearOnNewRun = cms.untracked.bool(False),
0098 makeTriggerResults = cms.obsolete.untracked.bool,
0099 numberOfConcurrentLuminosityBlocks = cms.untracked.uint32(1),
0100 numberOfConcurrentRuns = cms.untracked.uint32(1),
0101 numberOfStreams = cms.untracked.uint32(0),
0102 numberOfThreads = cms.untracked.uint32(1),
0103 printDependencies = cms.untracked.bool(False),
0104 sizeOfStackForThreadsInKB = cms.optional.untracked.uint32,
0105 throwIfIllegalParameter = cms.untracked.bool(True),
0106 wantSummary = cms.untracked.bool(False)
0107 )
0108
0109
0110 process.configurationMetadata = cms.untracked.PSet(
0111 annotation = cms.untracked.string('single pi E 1000'),
0112 name = cms.untracked.string('Applications'),
0113 version = cms.untracked.string('$Revision: 1.19 $')
0114 )
0115
0116
0117
0118 process.FEVTDEBUGoutput = cms.OutputModule("PoolOutputModule",
0119 SelectEvents = cms.untracked.PSet(
0120 SelectEvents = cms.vstring('generation_step')
0121 ),
0122 dataset = cms.untracked.PSet(
0123 dataTier = cms.untracked.string('GEN-SIM'),
0124 filterName = cms.untracked.string('')
0125 ),
0126 fileName = cms.untracked.string(outFile),
0127 outputCommands = process.FEVTDEBUGEventContent.outputCommands,
0128 splitLevel = cms.untracked.int32(0)
0129 )
0130
0131
0132
0133
0134 process.genstepfilter.triggerConditions=cms.vstring("generation_step")
0135 from Configuration.AlCa.GlobalTag import GlobalTag
0136 process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:phase2_realistic_T21', '')
0137
0138 process.generator = cms.EDProducer("FlatRandomEGunProducer",
0139 PGunParameters = cms.PSet(
0140 PartID = cms.vint32(211),
0141 MinEta = cms.double(1.48),
0142 MaxEta = cms.double(3.01),
0143 MinPhi = cms.double(-3.14159265359),
0144 MaxPhi = cms.double(3.14159265359),
0145 MinE = cms.double(999.99),
0146 MaxE = cms.double(1000.01)
0147 ),
0148 Verbosity = cms.untracked.int32(0),
0149 psethack = cms.string('single pi E 1000'),
0150 AddAntiParticle = cms.bool(True),
0151 firstRun = cms.untracked.uint32(1)
0152 )
0153
0154 process.ProductionFilterSequence = cms.Sequence(process.generator)
0155
0156
0157 process.generation_step = cms.Path(process.pgen)
0158 process.simulation_step = cms.Path(process.psim)
0159 process.genfiltersummary_step = cms.EndPath(process.genFilterSummary)
0160 process.endjob_step = cms.EndPath(process.endOfProcess)
0161 process.FEVTDEBUGoutput_step = cms.EndPath(process.FEVTDEBUGoutput)
0162
0163
0164 process.schedule = cms.Schedule(process.generation_step,process.genfiltersummary_step,process.simulation_step,process.endjob_step,process.FEVTDEBUGoutput_step)
0165 from PhysicsTools.PatAlgos.tools.helpers import associatePatAlgosToolsTask
0166 associatePatAlgosToolsTask(process)
0167
0168 for path in process.paths:
0169 getattr(process,path).insert(0, process.ProductionFilterSequence)
0170
0171
0172
0173
0174
0175
0176 from Configuration.StandardSequences.earlyDeleteSettings_cff import customiseEarlyDelete
0177 process = customiseEarlyDelete(process)
0178