pixelClusterTag="displacedMuonReducedTrackExtras", stripClusterTag="displacedMuonReducedTrackExtras") # no clusters in fastsim from Configuration.Eras.Modifier_fastSim_cff import fastSim fastSim.toModify(slimmedMuonTrackExtras, outputClusters=False) # cluster collections are different in phase 2, so skip this for now from Configuration.Eras.Modifier_phase2_tracker_cff import phase2_tracker phase2_tracker.toModify(slimmedMuonTrackExtras, outputClusters=False) phase2_tracker.toModify(slimmedDisplacedMuonTrackExtras, outputClusters=False) # lower minimum pt for B-parking from Configuration.Eras.Modifier_bParking_cff import bParking bParking.toModify(slimmedMuonTrackExtras, cut="pt > 3.0") # full set of track extras not available in existing AOD from Configuration.Eras.Modifier_run2_miniAOD_80XLegacy_cff import run2_miniAOD_80XLegacy from Configuration.Eras.Modifier_run2_miniAOD_94XFall17_cff import run2_miniAOD_94XFall17 from Configuration.ProcessModifiers.pp_on_AA_cff import pp_on_AA from Configuration.ProcessModifiers.miniAOD_skip_trackExtras_cff import miniAOD_skip_trackExtras (run2_miniAOD_80XLegacy | run2_miniAOD_94XFall17 | pp_on_AA | miniAOD_skip_trackExtras).toModify(slimmedMuonTrackExtras, trackExtraTags=["standAloneMuons"], trackExtraAssocs=[], outputClusters=False)
ModelWeights = cms.vstring([ 'RecoEgamma/ElectronIdentification/data/LowPtElectrons/RunII_Fall17_LowPtElectrons_unbiased.xml.gz', 'RecoEgamma/ElectronIdentification/data/LowPtElectrons/RunII_Fall17_LowPtElectrons_displaced_pt_eta_biased.xml.gz', ]), ModelThresholds = thresholds("T"), PassThrough = cms.bool(False), UsePfTracks = cms.bool(True), MinPtThreshold = cms.double(1.0), MaxPtThreshold = cms.double(15.), ) # Modifiers for FastSim from Configuration.Eras.Modifier_fastSim_cff import fastSim lowPtGsfElectronSeedsTmp = lowPtGsfElectronSeeds.clone(tracks = cms.InputTag("generalTracksBeforeMixing")) import FastSimulation.Tracking.ElectronSeedTrackRefFix_cfi _fastSim_lowPtGsfElectronSeeds = FastSimulation.Tracking.ElectronSeedTrackRefFix_cfi.fixedTrackerDrivenElectronSeeds.clone() _fastSim_lowPtGsfElectronSeeds.seedCollection = cms.InputTag("lowPtGsfElectronSeedsTmp","") _fastSim_lowPtGsfElectronSeeds.idCollection = cms.VInputTag("lowPtGsfElectronSeedsTmp","lowPtGsfElectronSeedsTmp:HCAL") _fastSim_lowPtGsfElectronSeeds.PreIdLabel = cms.vstring("","HCAL") _fastSim_lowPtGsfElectronSeeds.PreGsfLabel = cms.string("") fastSim.toReplaceWith(lowPtGsfElectronSeeds,_fastSim_lowPtGsfElectronSeeds) # Modifiers for Phase2 from Configuration.Eras.Modifier_phase2_tracker_cff import phase2_tracker phase2_tracker.toModify(lowPtGsfElectronSeeds, TTRHBuilder = 'WithTrackAngle') # Modifiers for BParking from Configuration.Eras.Modifier_bParking_cff import bParking bParking.toModify(lowPtGsfElectronSeeds, ModelThresholds = thresholds("L") ) bParking.toModify(lowPtGsfElectronSeeds, MinPtThreshold = 0.5)
import FWCore.ParameterSet.Config as cms # module to select Electrons # See https://twiki.cern.ch/twiki/bin/view/CMS/SWGuidePhysicsCutParser # on how to use the cut-string # selectedPatLowPtElectrons = cms.EDFilter("PATElectronSelector", src = cms.InputTag("patLowPtElectrons"), cut = cms.string("pt > 1. && electronID('ID') > -0.25"), ) # Modifier for bParking (fully open selection) from Configuration.Eras.Modifier_bParking_cff import bParking bParking.toModify(selectedPatLowPtElectrons,cut = "") # Modifiers for legacy AOD from Configuration.Eras.Modifier_run2_miniAOD_80XLegacy_cff import run2_miniAOD_80XLegacy from Configuration.Eras.Modifier_run2_miniAOD_94XFall17_cff import run2_miniAOD_94XFall17 (run2_miniAOD_80XLegacy | run2_miniAOD_94XFall17).toModify(selectedPatLowPtElectrons, cut = "pt>99999." )
'RecoEgamma/ElectronIdentification/data/LowPtElectrons/RunII_Autumn18_LowPtElectrons_displaced_pt_eta_biased.root', ]), ModelThresholds=thresholds("T"), PassThrough=cms.bool(False), UsePfTracks=cms.bool(True), MinPtThreshold=cms.double(1.0), MaxPtThreshold=cms.double(15.), ) # Modifiers for FastSim from Configuration.Eras.Modifier_fastSim_cff import fastSim lowPtGsfElectronSeedsTmp = lowPtGsfElectronSeeds.clone( tracks="generalTracksBeforeMixing") import FastSimulation.Tracking.ElectronSeedTrackRefFix_cfi _fastSim_lowPtGsfElectronSeeds = FastSimulation.Tracking.ElectronSeedTrackRefFix_cfi.fixedTrackerDrivenElectronSeeds.clone( seedCollection="lowPtGsfElectronSeedsTmp:", idCollection=["lowPtGsfElectronSeedsTmp", "lowPtGsfElectronSeedsTmp:HCAL"], PreIdLabel=["", "HCAL"], PreGsfLabel="") fastSim.toReplaceWith(lowPtGsfElectronSeeds, _fastSim_lowPtGsfElectronSeeds) # Modifiers for BParking from Configuration.Eras.Modifier_bParking_cff import bParking bParking.toModify( lowPtGsfElectronSeeds, ModelThresholds=thresholds("VL"), )
) ) # Only add low pT electrons for bParking era from Configuration.Eras.Modifier_bParking_cff import bParking _bParking_extraCommands = ['keep *_slimmedLowPtElectrons_*_*', 'keep recoGsfElectronCores_lowPtGsfElectronCores_*_*', 'keep recoSuperClusters_lowPtGsfElectronSuperClusters_*_*', 'keep recoCaloClusters_lowPtGsfElectronSuperClusters_*_*', 'keep recoGsfTracks_lowPtGsfEleGsfTracks_*_*', 'keep floatedmValueMap_lowPtGsfElectronSeedValueMaps_*_*', 'keep floatedmValueMap_lowPtGsfElectronID_*_*', 'keep *_lowPtGsfLinks_*_*', 'keep *_gsfTracksOpenConversions_*_*', ] bParking.toModify(MicroEventContent, outputCommands = MicroEventContent.outputCommands + _bParking_extraCommands) # --- Only for 2018 data & MC _run2_HCAL_2018_extraCommands = ["keep *_packedPFCandidates_hcalDepthEnergyFractions_*"] from Configuration.Eras.Modifier_run2_HCAL_2018_cff import run2_HCAL_2018 run2_HCAL_2018.toModify(MicroEventContent, outputCommands = MicroEventContent.outputCommands + _run2_HCAL_2018_extraCommands) _run3_common_extraCommands = ["drop *_packedPFCandidates_hcalDepthEnergyFractions_*"] from Configuration.Eras.Modifier_run3_common_cff import run3_common run3_common.toModify(MicroEventContent, outputCommands = MicroEventContent.outputCommands + _run3_common_extraCommands) # --- _pp_on_AA_extraCommands = [ 'keep patPackedCandidates_hiPixelTracks_*_*', 'keep patPackedCandidates_packedPFCandidatesRemoved_*_*', 'keep *_packedCandidateMuonID_*_*',
ModelWeights=cms.vstring([ 'RecoEgamma/ElectronIdentification/data/LowPtElectrons/RunII_Autumn18_LowPtElectrons_unbiased.xml.gz', 'RecoEgamma/ElectronIdentification/data/LowPtElectrons/RunII_Autumn18_LowPtElectrons_displaced_pt_eta_biased.xml.gz', ]), ModelThresholds=thresholds("T"), PassThrough=cms.bool(False), UsePfTracks=cms.bool(True), MinPtThreshold=cms.double(1.0), MaxPtThreshold=cms.double(15.), ) # Modifiers for FastSim from Configuration.Eras.Modifier_fastSim_cff import fastSim lowPtGsfElectronSeedsTmp = lowPtGsfElectronSeeds.clone( tracks=cms.InputTag("generalTracksBeforeMixing")) import FastSimulation.Tracking.ElectronSeedTrackRefFix_cfi _fastSim_lowPtGsfElectronSeeds = FastSimulation.Tracking.ElectronSeedTrackRefFix_cfi.fixedTrackerDrivenElectronSeeds.clone( ) _fastSim_lowPtGsfElectronSeeds.seedCollection = cms.InputTag( "lowPtGsfElectronSeedsTmp", "") _fastSim_lowPtGsfElectronSeeds.idCollection = cms.VInputTag( "lowPtGsfElectronSeedsTmp", "lowPtGsfElectronSeedsTmp:HCAL") _fastSim_lowPtGsfElectronSeeds.PreIdLabel = cms.vstring("", "HCAL") _fastSim_lowPtGsfElectronSeeds.PreGsfLabel = cms.string("") fastSim.toReplaceWith(lowPtGsfElectronSeeds, _fastSim_lowPtGsfElectronSeeds) # Modifiers for BParking from Configuration.Eras.Modifier_bParking_cff import bParking bParking.toModify(lowPtGsfElectronSeeds, ModelThresholds=thresholds("VL")) bParking.toModify(lowPtGsfElectronSeeds, MinPtThreshold=0.5)
) ) # Only add low pT electrons for bParking era from Configuration.Eras.Modifier_bParking_cff import bParking _bParking_extraCommands = ['keep *_slimmedLowPtElectrons_*_*', 'keep recoGsfElectronCores_lowPtGsfElectronCores_*_*', 'keep recoSuperClusters_lowPtGsfElectronSuperClusters_*_*', 'keep recoCaloClusters_lowPtGsfElectronSuperClusters_*_*', 'keep recoGsfTracks_lowPtGsfEleGsfTracks_*_*', 'keep floatedmValueMap_lowPtGsfElectronSeedValueMaps_*_*', 'keep floatedmValueMap_lowPtGsfElectronID_*_*', 'keep *_lowPtGsfLinks_*_*', 'keep *_gsfTracksOpenConversions_*_*', ] bParking.toModify(MicroEventContent, outputCommands = MicroEventContent.outputCommands + _bParking_extraCommands) # --- Only for 2018 data & MC _run2_HCAL_2018_extraCommands = ["keep *_packedPFCandidates_hcalDepthEnergyFractions_*"] from Configuration.Eras.Modifier_run2_HCAL_2018_cff import run2_HCAL_2018 run2_HCAL_2018.toModify(MicroEventContent, outputCommands = MicroEventContent.outputCommands + _run2_HCAL_2018_extraCommands) _run3_common_extraCommands = ["drop *_packedPFCandidates_hcalDepthEnergyFractions_*"] from Configuration.Eras.Modifier_run3_common_cff import run3_common run3_common.toModify(MicroEventContent, outputCommands = MicroEventContent.outputCommands + _run3_common_extraCommands) # --- MicroEventContentMC = cms.PSet( outputCommands = cms.untracked.vstring(MicroEventContent.outputCommands) ) MicroEventContentMC.outputCommands += MicroEventContentGEN.outputCommands
import FWCore.ParameterSet.Config as cms from RecoEgamma.EgammaElectronProducers.defaultLowPtGsfElectronID_cfi import defaultLowPtGsfElectronID lowPtGsfElectronID = defaultLowPtGsfElectronID.clone() from Configuration.Eras.Modifier_bParking_cff import bParking bParking.toModify( lowPtGsfElectronID, ModelWeights=[ "RecoEgamma/ElectronIdentification/data/LowPtElectrons/LowPtElectrons_ID_2021May17.root" ], )
# AOD content RecoLocalMuonAOD = cms.PSet(outputCommands=cms.untracked.vstring( 'keep *_dt4DSegments_*_*', 'keep *_dt4DCosmicSegments_*_*', 'keep *_cscSegments_*_*', 'keep *_rpcRecHits_*_*')) from Configuration.Eras.Modifier_run2_GEM_2017_cff import run2_GEM_2017 from Configuration.Eras.Modifier_run3_GEM_cff import run3_GEM from Configuration.Eras.Modifier_phase2_muon_cff import phase2_muon from Configuration.Eras.Modifier_bParking_cff import bParking for e in [run2_GEM_2017, run3_GEM]: e.toModify(RecoLocalMuonAOD, outputCommands=RecoLocalMuonAOD.outputCommands + ['keep *_gemRecHits_*_*', 'keep *_gemSegments_*_*']) phase2_muon.toModify(RecoLocalMuonAOD, outputCommands=RecoLocalMuonAOD.outputCommands + ['keep *_me0RecHits_*_*', 'keep *_me0Segments_*_*']) bParking.toModify(RecoLocalMuonAOD, outputCommands=RecoLocalMuonAOD.outputCommands + ['keep *_dt1DRecHits_*_*', 'keep *_csc2DRecHits_*_*']) # RECO content RecoLocalMuonRECO = cms.PSet(outputCommands=cms.untracked.vstring( 'keep *_dt1DRecHits_*_*', 'keep *_dt1DCosmicRecHits_*_*', 'keep *_csc2DRecHits_*_*')) RecoLocalMuonRECO.outputCommands.extend(RecoLocalMuonAOD.outputCommands) # Full Event content RecoLocalMuonFEVT = cms.PSet(outputCommands=cms.untracked.vstring()) RecoLocalMuonFEVT.outputCommands.extend(RecoLocalMuonRECO.outputCommands)