Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-06-23 03:27:32

0001 import FWCore.ParameterSet.Config as cms 
0002 
0003 from Configuration.Eras.Era_Phase2C9_cff import Phase2C9
0004 process = cms.Process('DIGI',Phase2C9)
0005 
0006 # import of standard configurations
0007 process.load('Configuration.StandardSequences.Services_cff')
0008 process.load('SimGeneral.HepPDTESSource.pythiapdt_cfi')
0009 process.load('FWCore.MessageService.MessageLogger_cfi')
0010 process.load('Configuration.EventContent.EventContent_cff')
0011 process.load('SimGeneral.MixingModule.mixNoPU_cfi')
0012 process.load('Configuration.Geometry.GeometryExtended2026D49Reco_cff')
0013 process.load('Configuration.Geometry.GeometryExtended2026D49_cff')
0014 process.load('Configuration.StandardSequences.MagneticField_cff')
0015 process.load('Configuration.StandardSequences.Generator_cff')
0016 process.load('IOMC.EventVertexGenerators.VtxSmearedHLLHC14TeV_cfi')
0017 process.load('GeneratorInterface.Core.genFilterSummary_cff')
0018 process.load('Configuration.StandardSequences.SimIdeal_cff')
0019 process.load('Configuration.StandardSequences.Digi_cff')
0020 process.load('Configuration.StandardSequences.SimL1Emulator_cff')
0021 process.load('Configuration.StandardSequences.DigiToRaw_cff')
0022 process.load('Configuration.StandardSequences.EndOfProcess_cff')
0023 process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff')
0024 
0025 
0026 process.maxEvents = cms.untracked.PSet(
0027     input = cms.untracked.int32(5)
0028 )
0029 
0030 # Input source
0031 process.source = cms.Source("PoolSource",
0032        fileNames = cms.untracked.vstring('/store/mc/Phase2HLTTDRWinter20DIGI/SingleElectron_PT2to200/GEN-SIM-DIGI-RAW/PU200_110X_mcRun4_realistic_v3_ext2-v2/40000/00582F93-5A2A-5847-8162-D81EE503500F.root'),
0033        inputCommands=cms.untracked.vstring(
0034            'keep *',
0035            'drop l1tEMTFHit2016Extras_simEmtfDigis_CSC_HLT',
0036            'drop l1tEMTFHit2016Extras_simEmtfDigis_RPC_HLT',
0037            'drop l1tEMTFHit2016s_simEmtfDigis__HLT',
0038            'drop l1tEMTFTrack2016Extras_simEmtfDigis__HLT',
0039            'drop l1tEMTFTrack2016s_simEmtfDigis__HLT',
0040            )
0041        )
0042 
0043 process.options = cms.untracked.PSet(
0044 
0045 )
0046 
0047 # Production Info
0048 process.configurationMetadata = cms.untracked.PSet(
0049     version = cms.untracked.string('$Revision: 1.20 $'),
0050     annotation = cms.untracked.string('SingleElectronPt10_cfi nevts:10'),
0051     name = cms.untracked.string('Applications')
0052 )
0053 
0054 # Output definition
0055 process.TFileService = cms.Service(
0056     "TFileService",
0057     fileName = cms.string("ntuple.root")
0058     )
0059 
0060 # Other statements
0061 from Configuration.AlCa.GlobalTag import GlobalTag
0062 process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:phase2_realistic_T15', '')
0063 
0064 # load HGCAL TPG simulation
0065 process.load('L1Trigger.L1THGCal.hgcalTriggerPrimitives_cff')
0066 process.load('L1Trigger.L1THGCalUtilities.HGC3DClusterGenMatchSelector_cff')
0067 process.load('L1Trigger.L1THGCalUtilities.hgcalTriggerNtuples_cff')
0068 from L1Trigger.L1THGCalUtilities.hgcalTriggerChains import HGCalTriggerChains
0069 import L1Trigger.L1THGCalUtilities.vfe as vfe
0070 import L1Trigger.L1THGCalUtilities.concentrator as concentrator
0071 import L1Trigger.L1THGCalUtilities.truth_prod as truth_prod
0072 import L1Trigger.L1THGCalUtilities.clustering2d as clustering2d
0073 import L1Trigger.L1THGCalUtilities.clustering3d as clustering3d
0074 import L1Trigger.L1THGCalUtilities.selectors as selectors
0075 import L1Trigger.L1THGCalUtilities.customNtuples as ntuple
0076 
0077 chains = HGCalTriggerChains()
0078 # Register algorithms
0079 ## VFE
0080 chains.register_vfe("Floatingpoint", vfe.create_vfe)
0081 ## TRUTH PRODUCER
0082 chains.register_truth_prod("TruthProd", truth_prod.create_truth_prod)
0083 ## BE1
0084 chains.register_backend1("TruthDummy", clustering2d.create_truth_dummy)
0085 ## BE2
0086 chains.register_backend2("Histomax", clustering3d.create_histoMax)
0087 # Register selector
0088 chains.register_selector("Genmatch", selectors.create_genmatch)
0089 # Register ntuples
0090 ntuple_list = ['event', 'gen', 'multiclusters']
0091 chains.register_ntuple("Genclustersntuple", lambda p,i : ntuple.create_ntuple(p,i, ntuple_list))
0092 
0093 # Register trigger chains
0094 backend_algos = ['Histomax']
0095 
0096 chains.register_truth_chain('Floatingpoint', 'TruthProd', '', '', '', 'Genclustersntuple')
0097 for be in backend_algos:
0098     chains.register_truth_chain('Floatingpoint', 'TruthProd', 'TruthDummy', be, 'Genmatch', 'Genclustersntuple')
0099 
0100 process = chains.create_truth_sequences(process)
0101 
0102 # Remove towers from sequence
0103 process.hgcalTriggerPrimitivesTruth.remove(process.hgcalTowerMap)
0104 process.hgcalTriggerPrimitivesTruth.remove(process.hgcalTower)
0105 
0106 process.hgcl1tpg_truth_step = cms.Path(process.hgcalTriggerPrimitivesTruth)
0107 process.selector_step = cms.Path(process.hgcalTriggerSelector)
0108 process.ntuple_step = cms.Path(process.hgcalTriggerNtuples)
0109 
0110 # Schedule definition
0111 process.schedule = cms.Schedule(process.hgcl1tpg_truth_step, process.selector_step, process.ntuple_step)
0112 
0113 # Add early deletion of temporary data products to reduce peak memory need
0114 from Configuration.StandardSequences.earlyDeleteSettings_cff import customiseEarlyDelete
0115 process = customiseEarlyDelete(process)
0116 # End adding early deletion
0117