From 55e237f4e6011efbdab05bb240c40b15478bf79c Mon Sep 17 00:00:00 2001 From: Florian Damas Date: Fri, 18 Oct 2024 19:52:20 +0200 Subject: [PATCH 1/4] Update the PbPb skims for 2024 data taking --- .../Skimming/python/PbPb_EMuSkim_cff.py | 2 +- .../Skimming/python/PbPb_ZEESkim_cff.py | 2 +- .../Skimming/python/PbPb_ZMMSkim_cff.py | 4 +-- .../python/PbPb_ZMuSkimMuonDPG_cff.py | 26 ++++++++++++------- Configuration/Skimming/python/autoSkim.py | 2 +- 5 files changed, 22 insertions(+), 14 deletions(-) diff --git a/Configuration/Skimming/python/PbPb_EMuSkim_cff.py b/Configuration/Skimming/python/PbPb_EMuSkim_cff.py index 133824941cb0b..8fbfda2bebc96 100644 --- a/Configuration/Skimming/python/PbPb_EMuSkim_cff.py +++ b/Configuration/Skimming/python/PbPb_EMuSkim_cff.py @@ -3,7 +3,7 @@ # HLT dimuon trigger import HLTrigger.HLTfilters.hltHighLevel_cfi hltEMuHI = HLTrigger.HLTfilters.hltHighLevel_cfi.hltHighLevel.clone() -hltEMuHI.HLTPaths = ["HLT_HIEle*Gsf_v*","HLT_HIL3SingleMu*_v*"] +hltEMuHI.HLTPaths = ["HLT_HIEle*Gsf_v*","HLT_HIL2SingleMu12_v*"] hltEMuHI.throw = False hltEMuHI.andOr = True diff --git a/Configuration/Skimming/python/PbPb_ZEESkim_cff.py b/Configuration/Skimming/python/PbPb_ZEESkim_cff.py index b7d53ed183f28..f98a118a3bcd6 100644 --- a/Configuration/Skimming/python/PbPb_ZEESkim_cff.py +++ b/Configuration/Skimming/python/PbPb_ZEESkim_cff.py @@ -4,7 +4,7 @@ # HLT dimuon trigger import HLTrigger.HLTfilters.hltHighLevel_cfi hltZEEHI = HLTrigger.HLTfilters.hltHighLevel_cfi.hltHighLevel.clone() -hltZEEHI.HLTPaths = ["HLT_HIEle*Gsf_v*"] +hltZEEHI.HLTPaths = ["HLT_HIEle*Gsf_v*","HLT_HIDoubleEle*"] hltZEEHI.throw = False hltZEEHI.andOr = True diff --git a/Configuration/Skimming/python/PbPb_ZMMSkim_cff.py b/Configuration/Skimming/python/PbPb_ZMMSkim_cff.py index 81af55793d116..8a6ed681a16f4 100644 --- a/Configuration/Skimming/python/PbPb_ZMMSkim_cff.py +++ b/Configuration/Skimming/python/PbPb_ZMMSkim_cff.py @@ -3,7 +3,7 @@ # HLT dimuon trigger import HLTrigger.HLTfilters.hltHighLevel_cfi hltZMMPbPb = HLTrigger.HLTfilters.hltHighLevel_cfi.hltHighLevel.clone() -hltZMMPbPb.HLTPaths = ["HLT_HIL3SingleMu*_v*"] +hltZMMPbPb.HLTPaths = ["HLT_HIL2SingleMu7_v*"] hltZMMPbPb.throw = False hltZMMPbPb.andOr = True @@ -17,7 +17,7 @@ # selection of dimuons with mass in Z range muonSelectorForZMM = cms.EDFilter("MuonSelector", src = cms.InputTag("muons"), - cut = cms.string("(isPFMuon && isGlobalMuon) && pt > 20."), + cut = cms.string("(isPFMuon && isGlobalMuon) && pt > 15. && abs(eta) < 2.4"), filter = cms.bool(True) ) diff --git a/Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py b/Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py index 3f3427003e256..45bfb2c5a8b1e 100644 --- a/Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py +++ b/Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py @@ -7,7 +7,14 @@ PbPbZMuHLTFilter = copy.deepcopy(hltHighLevel) PbPbZMuHLTFilter.throw = cms.bool(False) -PbPbZMuHLTFilter.HLTPaths = ["HLT_HIL3Mu*"] +PbPbZMuHLTFilter.HLTPaths = ["HLT_HIL2SingleMu7*","HLT_HIL2SingleMu12*"] + +# selection of valid vertex +primaryVertexFilterForPbPbZMuSkim = cms.EDFilter("VertexSelector", + src = cms.InputTag("offlinePrimaryVertices"), + cut = cms.string("!isFake && abs(z) <= 25 && position.Rho <= 2"), + filter = cms.bool(True), + ) ### Z -> MuMu candidates # Get muons of needed quality for Zs @@ -15,7 +22,7 @@ ###create a track collection with generic kinematic cuts looseMuonsForPbPbZMuSkim = cms.EDFilter("TrackSelector", src = cms.InputTag("generalTracks"), - cut = cms.string('pt > 10 && abs(eta)<2.4 && (charge!=0)'), + cut = cms.string('pt > 5 && abs(eta)<2.4 && (charge!=0)'), filter = cms.bool(True) ) @@ -86,7 +93,7 @@ tightMuonsForPbPbZMuSkim = cms.EDFilter("MuonSelector", src = cms.InputTag("muons"), - cut = cms.string("(isGlobalMuon) && pt > 25. && (abs(eta)<2.4) && (isPFMuon>0) && (globalTrack().normalizedChi2() < 10) && (globalTrack().hitPattern().numberOfValidMuonHits()>0)&& (numberOfMatchedStations() > 1)&& (innerTrack().hitPattern().numberOfValidPixelHits() > 0)&& (innerTrack().hitPattern().trackerLayersWithMeasurement() > 5) && ((isolationR03().sumPt/pt)<0.1)"), + cut = cms.string("(isGlobalMuon) && pt > 15. && (abs(eta)<2.4) && (isPFMuon>0) && (globalTrack().normalizedChi2() < 10) && (globalTrack().hitPattern().numberOfValidMuonHits()>0) && (numberOfMatchedStations() > 1) && (innerTrack().hitPattern().numberOfValidPixelHits() > 0) && (innerTrack().hitPattern().trackerLayersWithMeasurement() > 5)"), filter = cms.bool(True) ) @@ -96,8 +103,8 @@ # build Z-> MuMu candidates dimuonsForPbPbZMuSkim = cms.EDProducer("CandViewShallowCloneCombiner", checkCharge = cms.bool(False), - cut = cms.string('(mass > 60) && (charge=0)'), - decay = cms.string("tightMuonsForPbPbZMuSkim looseIsoMuonsForPbPbZMuSkim") + cut = cms.string('(mass > 60) && (charge=0)'), + decay = cms.string("tightMuonsForPbPbZMuSkim looseMuonsForPbPbZMuSkim") ) @@ -111,11 +118,12 @@ diMuonSelSeqForPbPbZMuSkim = cms.Sequence( PbPbZMuHLTFilter * + primaryVertexFilterForPbPbZMuSkim * looseMuonsForPbPbZMuSkim * - ConcretelooseMuonsForPbPbZMuSkim * - tkIsoDepositTkForPbPbZMuSkim * - allPatTracksForPbPbZMuSkim * - looseIsoMuonsForPbPbZMuSkim * + #ConcretelooseMuonsForPbPbZMuSkim * + #tkIsoDepositTkForPbPbZMuSkim * + #allPatTracksForPbPbZMuSkim * + #looseIsoMuonsForPbPbZMuSkim * tightMuonsForPbPbZMuSkim * dimuonsForPbPbZMuSkim * dimuonsFilterForPbPbZMuSkim diff --git a/Configuration/Skimming/python/autoSkim.py b/Configuration/Skimming/python/autoSkim.py index 6828c21a7fe22..7b2919fc7846c 100644 --- a/Configuration/Skimming/python/autoSkim.py +++ b/Configuration/Skimming/python/autoSkim.py @@ -42,7 +42,7 @@ # For 2023 PbPb skims for i_split in range(32): - autoSkim[f'HIPhysicsRawPrime{i_split}'] = 'PbPbEMu+PbPbZEE+PbPbZMM+LogError+LogErrorMonitor' + autoSkim[f'HIPhysicsRawPrime{i_split}'] = 'PbPbEMu+PbPbZEE+PbPbZMu+LogError+LogErrorMonitor' autoSkimRunII = { 'BTagCSV' : 'LogError+LogErrorMonitor', From 6aef98cc15119c36ac11407fdb36fc8b36e3d271 Mon Sep 17 00:00:00 2001 From: Florian Damas Date: Fri, 25 Oct 2024 11:19:49 +0200 Subject: [PATCH 2/4] filter on L2 or L3 SingleMu triggers for easier skim maintenance over Run 3 --- Configuration/Skimming/python/PbPb_EMuSkim_cff.py | 2 +- Configuration/Skimming/python/PbPb_ZMMSkim_cff.py | 2 +- Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Configuration/Skimming/python/PbPb_EMuSkim_cff.py b/Configuration/Skimming/python/PbPb_EMuSkim_cff.py index 8fbfda2bebc96..d15ad6ef669f9 100644 --- a/Configuration/Skimming/python/PbPb_EMuSkim_cff.py +++ b/Configuration/Skimming/python/PbPb_EMuSkim_cff.py @@ -3,7 +3,7 @@ # HLT dimuon trigger import HLTrigger.HLTfilters.hltHighLevel_cfi hltEMuHI = HLTrigger.HLTfilters.hltHighLevel_cfi.hltHighLevel.clone() -hltEMuHI.HLTPaths = ["HLT_HIEle*Gsf_v*","HLT_HIL2SingleMu12_v*"] +hltEMuHI.HLTPaths = ["HLT_HIEle*Gsf_v*","HLT_HIL2SingleMu*_v*","HLT_HIL3SingleMu*_v*"] hltEMuHI.throw = False hltEMuHI.andOr = True diff --git a/Configuration/Skimming/python/PbPb_ZMMSkim_cff.py b/Configuration/Skimming/python/PbPb_ZMMSkim_cff.py index 8a6ed681a16f4..c5f02ac05db2c 100644 --- a/Configuration/Skimming/python/PbPb_ZMMSkim_cff.py +++ b/Configuration/Skimming/python/PbPb_ZMMSkim_cff.py @@ -3,7 +3,7 @@ # HLT dimuon trigger import HLTrigger.HLTfilters.hltHighLevel_cfi hltZMMPbPb = HLTrigger.HLTfilters.hltHighLevel_cfi.hltHighLevel.clone() -hltZMMPbPb.HLTPaths = ["HLT_HIL2SingleMu7_v*"] +hltZMMPbPb.HLTPaths = ["HLT_HIL2SingleMu*_v*","HLT_HIL3SingleMu*_v*"] hltZMMPbPb.throw = False hltZMMPbPb.andOr = True diff --git a/Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py b/Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py index 45bfb2c5a8b1e..e432bf72b6144 100644 --- a/Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py +++ b/Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py @@ -7,7 +7,7 @@ PbPbZMuHLTFilter = copy.deepcopy(hltHighLevel) PbPbZMuHLTFilter.throw = cms.bool(False) -PbPbZMuHLTFilter.HLTPaths = ["HLT_HIL2SingleMu7*","HLT_HIL2SingleMu12*"] +PbPbZMuHLTFilter.HLTPaths = ["HLT_HIL2SingleMu*","HLT_HIL3SingleMu*"] # selection of valid vertex primaryVertexFilterForPbPbZMuSkim = cms.EDFilter("VertexSelector", From da5d10df064b5784c6ab4cca0aefd883204f2c64 Mon Sep 17 00:00:00 2001 From: Florian Damas Date: Sat, 26 Oct 2024 10:25:01 +0200 Subject: [PATCH 3/4] tighter muon selection for a more efficient PbPb skimming --- Configuration/Skimming/python/PbPb_EMuSkim_cff.py | 4 ++-- Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Configuration/Skimming/python/PbPb_EMuSkim_cff.py b/Configuration/Skimming/python/PbPb_EMuSkim_cff.py index d15ad6ef669f9..c0f5c9f2eeead 100644 --- a/Configuration/Skimming/python/PbPb_EMuSkim_cff.py +++ b/Configuration/Skimming/python/PbPb_EMuSkim_cff.py @@ -1,6 +1,6 @@ import FWCore.ParameterSet.Config as cms -# HLT dimuon trigger +# Electron or muon HLT trigger import HLTrigger.HLTfilters.hltHighLevel_cfi hltEMuHI = HLTrigger.HLTfilters.hltHighLevel_cfi.hltHighLevel.clone() hltEMuHI.HLTPaths = ["HLT_HIEle*Gsf_v*","HLT_HIL2SingleMu*_v*","HLT_HIL3SingleMu*_v*"] @@ -22,7 +22,7 @@ muonSelectorForEMu = cms.EDFilter("MuonSelector", src = cms.InputTag("muons"), - cut = cms.string("isPFMuon && isGlobalMuon && pt > 20."), + cut = cms.string("isPFMuon && isGlobalMuon && pt > 20. && abs(eta)<2.4 && (globalTrack().normalizedChi2() < 10) && (globalTrack().hitPattern().numberOfValidMuonHits()>0) && (numberOfMatchedStations() > 1)"), filter = cms.bool(True) ) diff --git a/Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py b/Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py index e432bf72b6144..56715df715aa8 100644 --- a/Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py +++ b/Configuration/Skimming/python/PbPb_ZMuSkimMuonDPG_cff.py @@ -22,7 +22,7 @@ ###create a track collection with generic kinematic cuts looseMuonsForPbPbZMuSkim = cms.EDFilter("TrackSelector", src = cms.InputTag("generalTracks"), - cut = cms.string('pt > 5 && abs(eta)<2.4 && (charge!=0)'), + cut = cms.string('pt > 10 && abs(eta)<2.4 && (charge!=0)'), filter = cms.bool(True) ) @@ -103,7 +103,7 @@ # build Z-> MuMu candidates dimuonsForPbPbZMuSkim = cms.EDProducer("CandViewShallowCloneCombiner", checkCharge = cms.bool(False), - cut = cms.string('(mass > 60) && (charge=0)'), + cut = cms.string('(mass > 60)'), decay = cms.string("tightMuonsForPbPbZMuSkim looseMuonsForPbPbZMuSkim") ) From 60b49432760f2605b84b161808eeaa86d146ed90 Mon Sep 17 00:00:00 2001 From: Florian Damas Date: Tue, 29 Oct 2024 10:53:13 +0100 Subject: [PATCH 4/4] adjust the number of HIPhysicsRawPrime PDs for 2024 PbPb data taking --- Configuration/Skimming/python/autoSkim.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Configuration/Skimming/python/autoSkim.py b/Configuration/Skimming/python/autoSkim.py index 7b2919fc7846c..ae89d26682b50 100644 --- a/Configuration/Skimming/python/autoSkim.py +++ b/Configuration/Skimming/python/autoSkim.py @@ -40,8 +40,8 @@ #'SingleMuon': 'LogError+LogErrorMonitor', } -# For 2023 PbPb skims -for i_split in range(32): +# For 2024 PbPb skims +for i_split in range(60): autoSkim[f'HIPhysicsRawPrime{i_split}'] = 'PbPbEMu+PbPbZEE+PbPbZMu+LogError+LogErrorMonitor' autoSkimRunII = {