Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-08-30 02:11:00

0001 import FWCore.ParameterSet.Config as cms
0002 import os, sys, imp, re
0003 import FWCore.ParameterSet.VarParsing as VarParsing
0004 
0005 ####################################################################
0006 ### SETUP OPTIONS
0007 options = VarParsing.VarParsing('standard')
0008 options.register('type',
0009                  "V18",
0010                   VarParsing.VarParsing.multiplicity.singleton,
0011                   VarParsing.VarParsing.varType.string,
0012                   "type of operations: V16, V17, V17Shift, V18")
0013 
0014 ### get and parse the command line arguments
0015 options.parseArguments()
0016 print(options)
0017 
0018 from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9
0019 
0020 process = cms.Process("HGCalMouseBiteTest",Phase2C17I13M9)
0021 
0022 ####################################################################
0023 # Use the options
0024 if (options.type == "V18"):
0025     geomFile = "Configuration.Geometry.GeometryExtended2026D104_cff"
0026 elif (options.type == "V17Shift"):
0027     geomFile = "Geometry.HGCalCommonData.testHGCal" + options.type + "Reco_cff"
0028 elif (options.type == "V16"):
0029     geomFile = "Configuration.Geometry.GeometryExtended2026D100_cff"
0030 else:
0031     geomFile = "Configuration.Geometry.GeometryExtended2026D110_cff"
0032 
0033 print("Geometry file: ", geomFile)
0034 
0035 process.load("SimGeneral.HepPDTESSource.pdt_cfi")
0036 process.load(geomFile)
0037 process.load('FWCore.MessageService.MessageLogger_cfi')
0038 
0039 if hasattr(process,'MessageLogger'):
0040     process.MessageLogger.HGCalGeom=dict()
0041     process.MessageLogger.HGCSim=dict()
0042 
0043 process.load("IOMC.RandomEngine.IOMC_cff")
0044 process.RandomNumberGeneratorService.generator.initialSeed = 456789
0045 
0046 process.source = cms.Source("EmptySource")
0047 
0048 process.generator = cms.EDProducer("FlatRandomEGunProducer",
0049                                    PGunParameters = cms.PSet(
0050                                        PartID = cms.vint32(14),
0051                                        MinEta = cms.double(-3.5),
0052                                        MaxEta = cms.double(3.5),
0053                                        MinPhi = cms.double(-3.14159265359),
0054                                        MaxPhi = cms.double(3.14159265359),
0055                                        MinE   = cms.double(9.99),
0056                                        MaxE   = cms.double(10.01)
0057                                    ),
0058                                    AddAntiParticle = cms.bool(False),
0059                                    Verbosity       = cms.untracked.int32(0),
0060                                    firstRun        = cms.untracked.uint32(1)
0061                                )
0062 
0063 process.maxEvents = cms.untracked.PSet(
0064     input = cms.untracked.int32(1)
0065 )
0066 
0067 
0068 process.load("SimG4CMS.Calo.hgcalMouseBiteTester_cfi")
0069 
0070  
0071 process.p1 = cms.Path(process.generator*process.hgcalMouseBiteTester)