File indexing completed on 2025-02-24 23:25:01
0001 import FWCore.ParameterSet.Config as cms
0002
0003 from RecoHGCal.TICL.iterativeTICL_cff import ticlIterLabels
0004
0005 trackstersIters = ['keep *_'+iteration+'_*_*' for iteration in ticlIterLabels]
0006
0007
0008 TICL_AOD = cms.PSet(
0009 outputCommands = cms.untracked.vstring()
0010 )
0011
0012
0013 TICL_RECO = cms.PSet(
0014 outputCommands = cms.untracked.vstring(
0015 trackstersIters +
0016 [
0017 'keep *_ticlTrackstersHFNoseTrkEM_*_*',
0018 'keep *_ticlTrackstersHFNoseEM_*_*',
0019 'keep *_ticlTrackstersHFNoseTrk_*_*',
0020 'keep *_ticlTrackstersHFNoseMIP_*_*',
0021 'keep *_ticlTrackstersHFNoseHAD_*_*',
0022 'keep *_ticlTrackstersHFNoseMerge_*_*',] +
0023 ['keep *_pfTICL_*_*'] +
0024 ['keep CaloParticles_mix_*_*', 'keep SimClusters_mix_*_*', 'keep *_SimClusterToCaloParticleAssociation*_*_*'] +
0025 ['keep *_SimClusterToCaloParticleAssociation*_*_*', 'keep *_layerClusterSimClusterAssociationProducer_*_*','keep *_layerClusterCaloParticleAssociationProducer_*_*', 'keep *_layerClusterSimTracksterAssociationProducer_*_*'] +
0026 ['keep *_allTrackstersToSimTrackstersAssociations*_*_*']
0027 )
0028 )
0029
0030 TICLv5_RECO = cms.PSet(
0031 outputCommands = cms.untracked.vstring(
0032 [
0033 'drop *_ticlTracksters*_*_*',
0034 'keep *_ticlTrackstersCLUE3DHigh_*_*',
0035 'keep *_ticlTracksterLinks*_*_*',
0036 'keep *_ticlTracksterLinksSuperclustering*_*_*',
0037 'keep *_ticlCandidate_*_*',
0038
0039 ]
0040 )
0041 )
0042
0043
0044 TICL_RECO.outputCommands.extend(TICL_AOD.outputCommands)
0045
0046
0047
0048 TICL_FEVT = cms.PSet(
0049 outputCommands = cms.untracked.vstring(
0050 'keep *_ticlSimTracksters_*_*',
0051 'keep *_ticlSimTICLCandidates_*_*',
0052 'keep *_ticlSimTrackstersFromCP_*_*',
0053 'keep *_SimTau*_*_*',
0054 'keep *_allTrackstersToSimTrackstersAssociations*_*_*'
0055 )
0056 )
0057 TICL_FEVT.outputCommands.extend(TICL_RECO.outputCommands)
0058 TICLv5_FEVT = cms.PSet(
0059 outputCommands = cms.untracked.vstring(
0060 'keep *_ticlSimTracksters_*_*',
0061 'keep *_ticlSimTICLCandidates_*_*',
0062 'keep *_ticlSimTrackstersFromCP_*_*',
0063 'keep CaloParticles_mix_*_*', 'keep SimClusters_mix_*_*', 'keep *_SimClusterToCaloParticleAssociation*_*_*',
0064 'keep *_SimClusterToCaloParticleAssociation*_*_*', 'keep *_layerClusterSimClusterAssociationProducer_*_*','keep *_layerClusterCaloParticleAssociationProducer_*_*', 'keep *_layerClusterSimTracksterAssociationProducer_*_*',
0065 'keep *_SimTau*_*_*',
0066 'keep *_allTrackstersToSimTrackstersAssociations*_*_*'
0067
0068 )
0069 )
0070
0071 TICLv5_FEVT.outputCommands.extend(TICLv5_RECO.outputCommands)
0072
0073 TICL_FEVTHLT = cms.PSet(
0074 outputCommands = cms.untracked.vstring(
0075 ['keep *_hltPfTICL_*_*',
0076 'keep *_hltTiclTracksters*_*_*',
0077 'keep *_hltTiclCandidate_*_*',
0078 'keep *_hltPfTICL_*_*',]
0079 )
0080 )
0081
0082 TICL_FEVTHLT.outputCommands.extend(TICL_FEVT.outputCommands)
0083
0084 TICLv5_FEVTHLT = cms.PSet(
0085 outputCommands = cms.untracked.vstring(
0086 [
0087 'drop *_hltTiclTracksters*_*_*',
0088 'keep *_hltTiclTrackstersCLUE3D*_*_*',
0089 'keep *_hltTiclTracksterLinks_*_*',
0090 'keep *_hltTiclCandidate_*_*',
0091 'keep *_hltPfTICL_*_*',
0092 ]
0093 )
0094 )
0095
0096 TICLv5_FEVTHLT.outputCommands.extend(TICLv5_FEVT.outputCommands)
0097
0098 def customiseHGCalOnlyEventContent(process):
0099 def cleanOutputAndSet(outputModule, ticl_outputCommads):
0100 outputModule.outputCommands = ['drop *_*_*_*']
0101 outputModule.outputCommands.extend(ticl_outputCommads)
0102 outputModule.outputCommands.extend(['keep *_HGCalRecHit_*_*',
0103 'keep *_hgcalMergeLayerClusters_*_*',
0104 'keep CaloParticles_mix_*_*',
0105 'keep SimClusters_mix_*_*',
0106 'keep recoTracks_generalTracks_*_*',
0107 'keep recoTrackExtras_generalTracks_*_*',
0108 'keep SimTracks_g4SimHits_*_*',
0109 'keep SimVertexs_g4SimHits_*_*',
0110 'keep *_layerClusterSimClusterAssociationProducer_*_*',
0111 'keep *_layerClusterCaloParticleAssociationProducer_*_*',
0112 'keep *_randomEngineStateProducer_*_*',
0113 'keep *_layerClusterSimTracksterAssociationProducer_*_*',
0114 'keep *_SimClusterToCaloParticleAssociation*_*_*',
0115 'keep *_simClusterToCaloParticleAssociator*_*_*',
0116 'keep *_SimTau*_*_*',
0117 'keep *_allTrackstersToSimTrackstersAssociations*_*_*'
0118 ])
0119
0120 if hasattr(process, 'FEVTDEBUGEventContent'):
0121 cleanOutputAndSet(process.FEVTDEBUGEventContent, TICL_FEVT.outputCommands)
0122 if hasattr(process, 'FEVTDEBUGHLToutput'):
0123 cleanOutputAndSet(process.FEVTDEBUGHLToutput, TICL_FEVTHLT.outputCommands)
0124
0125 return process
0126
0127
0128
0129 def customiseForTICLv5EventContent(process):
0130 def cleanOutputAndSet(outputModule, ticl_outputCommands):
0131 outputModule.outputCommands.extend(ticl_outputCommands)
0132
0133 if hasattr(process, 'FEVTDEBUGEventContent'):
0134 cleanOutputAndSet(process.FEVTDEBUGEventContent, TICLv5_FEVT.outputCommands)
0135 if hasattr(process, 'FEVTDEBUGHLToutput'):
0136 cleanOutputAndSet(process.FEVTDEBUGHLToutput, TICLv5_FEVTHLT.outputCommands)
0137 if hasattr(process, 'FEVTEventContent'):
0138 cleanOutputAndSet(process.FEVTEventContent, TICLv5_FEVT.outputCommands)
0139
0140 return process
0141