Skip to content

Commit

Permalink
Merge pull request #42296 from youyingli/CMSSW_13_2_X_skimUpdate_v2
Browse files Browse the repository at this point in the history
[13_2_X] Add HARVEST step to SKIM WF for Run3
  • Loading branch information
cmsbuild authored Jul 29, 2023
2 parents 7e80172 + 32885b5 commit 0bf2204
Show file tree
Hide file tree
Showing 3 changed files with 64 additions and 41 deletions.
55 changes: 27 additions & 28 deletions Configuration/PyReleaseValidation/python/relval_standard.py
Original file line number Diff line number Diff line change
Expand Up @@ -494,20 +494,19 @@
workflows[140.078] = ['',['RunMuonEG2022E','HLTDR3_2022','RECONANORUN3_reHLT_2022','HARVESTRUN3_2022']]

### run3 (2022) skims ###
workflows[140.104] = ['',['RunZeroBias2022D','HLTDR3_2022','RECONANORUN3_ZB_reHLT_2022','SKIMZEROBIASRUN3_reHLT']]
workflows[140.105] = ['',['RunBTagMu2022D','HLTDR3_2022','RECONANORUN3_reHLT_2022','SKIMBTAGMURUN3_reHLT']]
workflows[140.106] = ['',['RunJetMET2022D','HLTDR3_2022','RECONANORUN3_reHLT_2022','SKIMJETMET0RUN3_reHLT']]
workflows[140.107] = ['',['RunDisplacedJet2022D','HLTDR3_2022','RECONANORUN3_reHLT_2022','SKIMDISPLACEDJETRUN3_reHLT']]
workflows[140.109] = ['',['RunEGamma2022D','HLTDR3_2022','RECONANORUN3_reHLT_2022','SKIMEGAMMA0RUN3_reHLT']]
workflows[140.110] = ['',['RunTau2022D','HLTDR3_2022','RECONANORUN3_reHLT_2022','SKIMTAURUN3_reHLT']]
workflows[140.111] = ['',['RunMuon2022D','HLTDR3_2022','RECONANORUN3_reHLT_2022','SKIMMUON0RUN3_reHLT']]
workflows[140.112] = ['',['RunMuonEG2022D','HLTDR3_2022','RECONANORUN3_reHLT_2022','SKIMMUONEGRUN3_reHLT']]
workflows[140.113] = ['',['RunNoBPTX2022D','HLTDR3_2022','RECONANORUN3_reHLT_2022','SKIMNOBPTXRUN3_reHLT']]
workflows[140.114] = ['',['RunHcalNZS2022D','HLTDR3_2022','RECONANORUN3_reHLT_2022','SKIMHCALNZSRUN3_reHLT']]
workflows[140.115] = ['',['RunHLTPhysics2022D','HLTDR3_2022','RECONANORUN3_reHLT_2022','SKIMHLTPHYSICSRUN3_reHLT']]
workflows[140.116] = ['',['RunCommissioning2022D','HLTDR3_2022','RECONANORUN3_reHLT_2022','SKIMCOMMISSIONINGRUN3_reHLT']]
workflows[140.117] = ['',['RunCosmics2022D','HLTDR3_2022','RECOCOSMRUN3_reHLT_2022','SKIMCOSMICSRUN3_reHLT']]
#workflows[140.118] = ['',['RunParkingBPH2022B','HLTDR3_2022','RECONANORUN3_reHLT_2022','SKIMPARKINGBPHRUN3_reHLT']]
workflows[140.101] = ['',['RunZeroBias2022D','HLTDR3_2022','SKIMZEROBIASRUN3_reHLT_2022','HARVESTRUN3_ZB_2022']]
workflows[140.102] = ['',['RunBTagMu2022D','HLTDR3_2022','SKIMBTAGMURUN3_reHLT_2022','HARVESTRUN3_2022']]
workflows[140.103] = ['',['RunJetMET2022D','HLTDR3_2022','SKIMJETMET0RUN3_reHLT_2022','HARVESTRUN3_2022']]
workflows[140.104] = ['',['RunDisplacedJet2022D','HLTDR3_2022','SKIMDISPLACEDJETRUN3_reHLT_2022','HARVESTRUN3_2022']]
workflows[140.105] = ['',['RunEGamma2022D','HLTDR3_2022','SKIMEGAMMA0RUN3_reHLT_2022','HARVESTRUN3_2022']]
workflows[140.106] = ['',['RunTau2022D','HLTDR3_2022','SKIMTAURUN3_reHLT_2022','HARVESTRUN3_2022']]
workflows[140.107] = ['',['RunMuon2022D','HLTDR3_2022','SKIMMUON0RUN3_reHLT_2022','HARVESTRUN3_2022']]
workflows[140.108] = ['',['RunMuonEG2022D','HLTDR3_2022','SKIMMUONEGRUN3_reHLT_2022','HARVESTRUN3_2022']]
workflows[140.109] = ['',['RunNoBPTX2022D','HLTDR3_2022','SKIMNOBPTXRUN3_reHLT_2022','HARVESTRUN3_2022']]
workflows[140.110] = ['',['RunHcalNZS2022D','HLTDR3_2022','SKIMHCALNZSRUN3_reHLT_2022','HARVESTRUN3_2022']]
workflows[140.111] = ['',['RunHLTPhysics2022D','HLTDR3_2022','SKIMHLTPHYSICSRUN3_reHLT_2022','HARVESTRUN3_2022']]
workflows[140.112] = ['',['RunCommissioning2022D','HLTDR3_2022','SKIMCOMMISSIONINGRUN3_reHLT_2022','HARVESTRUN3_2022']]
workflows[140.113] = ['',['RunCosmics2022D','HLTDR3_2022','SKIMCOSMICSRUN3_reHLT_2022','HARVESTRUN3_COS_2022']]

### run3 (2023) ###
workflows[141.001] = ['',['RunMuon2023B','HLTDR3_2023B','RECONANORUN3_reHLT_2023B','HARVESTRUN3_2023B']]
Expand All @@ -534,20 +533,20 @@
workflows[141.038] = ['',['RunMuonEG2023C','HLTDR3_2023','RECONANORUN3_reHLT_2023','HARVESTRUN3_2023']]

### run3 (2023) skims ###
workflows[141.101] = ['',['RunZeroBias2023C','HLTDR3_2023','RECONANORUN3_ZB_reHLT_2023','SKIMZEROBIASRUN3_reHLT']]
workflows[141.102] = ['',['RunBTagMu2023C','HLTDR3_2023','RECONANORUN3_reHLT_2023','SKIMBTAGMURUN3_reHLT']]
workflows[141.103] = ['',['RunJetMET2023C','HLTDR3_2023','RECONANORUN3_reHLT_2023','SKIMJETMET0RUN3_reHLT']]
workflows[141.104] = ['',['RunDisplacedJet2023C','HLTDR3_2023','RECONANORUN3_reHLT_2023','SKIMDISPLACEDJETRUN3_reHLT']]
workflows[141.105] = ['',['RunEGamma2023C','HLTDR3_2023','RECONANORUN3_reHLT_2023','SKIMEGAMMA0RUN3_reHLT']]
workflows[141.106] = ['',['RunTau2023C','HLTDR3_2023','RECONANORUN3_reHLT_2023','SKIMTAURUN3_reHLT']]
workflows[141.107] = ['',['RunMuon2023C','HLTDR3_2023','RECONANORUN3_reHLT_2023','SKIMMUON0RUN3_reHLT']]
workflows[141.108] = ['',['RunMuonEG2023C','HLTDR3_2023','RECONANORUN3_reHLT_2023','SKIMMUONEGRUN3_reHLT']]
workflows[141.109] = ['',['RunNoBPTX2023C','HLTDR3_2023','RECONANORUN3_reHLT_2023','SKIMNOBPTXRUN3_reHLT']]
workflows[141.110] = ['',['RunHcalNZS2023C','HLTDR3_2023','RECONANORUN3_reHLT_2023','SKIMHCALNZSRUN3_reHLT']]
workflows[141.111] = ['',['RunHLTPhysics2023C','HLTDR3_2023','RECONANORUN3_reHLT_2023','SKIMHLTPHYSICSRUN3_reHLT']]
workflows[141.112] = ['',['RunCommissioning2023C','HLTDR3_2023','RECONANORUN3_reHLT_2023','SKIMCOMMISSIONINGRUN3_reHLT']]
workflows[141.113] = ['',['RunCosmics2023C','HLTDR3_2023','RECOCOSMRUN3_reHLT_2023','SKIMCOSMICSRUN3_reHLT']]
workflows[141.114] = ['',['RunParkingDoubleMuonLowMass2023C','HLTDR3_2023','RECONANORUN3_reHLT_2023','SKIMPARKINGDOUBLEMUONLOWMASS0RUN3_reHLT']]
workflows[141.101] = ['',['RunZeroBias2023C','HLTDR3_2023','SKIMZEROBIASRUN3_reHLT_2023','HARVESTRUN3_ZB_2023']]
workflows[141.102] = ['',['RunBTagMu2023C','HLTDR3_2023','SKIMBTAGMURUN3_reHLT_2023','HARVESTRUN3_2023']]
workflows[141.103] = ['',['RunJetMET2023C','HLTDR3_2023','SKIMJETMET0RUN3_reHLT_2023','HARVESTRUN3_2023']]
workflows[141.104] = ['',['RunDisplacedJet2023C','HLTDR3_2023','SKIMDISPLACEDJETRUN3_reHLT_2023','HARVESTRUN3_2023']]
workflows[141.105] = ['',['RunEGamma2023C','HLTDR3_2023','SKIMEGAMMA0RUN3_reHLT_2023','HARVESTRUN3_2023']]
workflows[141.106] = ['',['RunTau2023C','HLTDR3_2023','SKIMTAURUN3_reHLT_2023','HARVESTRUN3_2023']]
workflows[141.107] = ['',['RunMuon2023C','HLTDR3_2023','SKIMMUON0RUN3_reHLT_2023','HARVESTRUN3_2023']]
workflows[141.108] = ['',['RunMuonEG2023C','HLTDR3_2023','SKIMMUONEGRUN3_reHLT_2023','HARVESTRUN3_2023']]
workflows[141.109] = ['',['RunNoBPTX2023C','HLTDR3_2023','SKIMNOBPTXRUN3_reHLT_2023','HARVESTRUN3_2023']]
workflows[141.110] = ['',['RunHcalNZS2023C','HLTDR3_2023','SKIMHCALNZSRUN3_reHLT_2023','HARVESTRUN3_2023']]
workflows[141.111] = ['',['RunHLTPhysics2023C','HLTDR3_2023','SKIMHLTPHYSICSRUN3_reHLT_2023','HARVESTRUN3_2023']]
workflows[141.112] = ['',['RunCommissioning2023C','HLTDR3_2023','SKIMCOMMISSIONINGRUN3_reHLT_2023','HARVESTRUN3_2023']]
workflows[141.113] = ['',['RunCosmics2023C','HLTDR3_2023','SKIMCOSMICSRUN3_reHLT_2023','HARVESTRUN3_COS_2023']]
workflows[141.114] = ['',['RunParkingDoubleMuonLowMass2023C','HLTDR3_2023','SKIMPARKINGDOUBLEMUONLOWMASS0RUN3_reHLT_2023','HARVESTRUN3_2023']]

### run3-2023 (2023 data) - Pixel-only (triplets), ECAL-only and HCAL-only
workflows[141.008505] = ['Run3-2023_JetMET2023B_RecoPixelOnlyTripletsCPU',['RunJetMET2023B','HLTDR3_2023','RECODR3_reHLT_Patatrack_PixelOnlyTripletsCPU','HARVESTRUN3_pixelTrackingOnly']]
Expand Down
35 changes: 24 additions & 11 deletions Configuration/PyReleaseValidation/python/relval_steps.py
Original file line number Diff line number Diff line change
Expand Up @@ -2607,17 +2607,6 @@ def lhegensim2018ml(fragment,howMuch):
'-s':'RECO:bunchSpacingProducer+ecalMultiFitUncalibRecHitTask+ecalCalibratedRecHitTask',
'--customise':'Calibration/EcalCalibAlgos/EcalPhiSymRecoSequence_cff'},dataReco])

# Run-3 skims
for s in autoSkim.keys():
steps['SKIM'+s.upper()+'RUN3_reHLT'] = {'-s':'SKIM:%s'%(autoSkim[s]),
'--data':'',
'--era':'Run3',
'--scenario':'pp',
'--conditions':'auto:run3_data_prompt_relval',
'--hltProcess':'reHLT'}
if 'Cosmics' in s:
steps['SKIM'+s.upper()+'RUN3_reHLT']['--scenario'] = 'cosmics'

# step1 gensim for HI mixing
step1Up2018HiMixDefaults = merge ([{'--beamspot':'MatchHI', '--pileup':'HiMixGEN', '--scenario':'HeavyIons'},hiDefaults2018_ppReco,PUHI,step1Up2018HiProdDefaults])
def gen2018HiMix(fragment,howMuch):
Expand Down Expand Up @@ -2916,6 +2905,27 @@ def gen2023HiMix(fragment,howMuch):
steps['RECONANORUN3_ZB_reHLT_2023']=merge([{'-s':'RAW2DIGI,L1Reco,RECO,PAT,NANO,DQM:@rerecoZeroBias+@miniAODDQM+@nanoAODDQM'},steps['RECONANORUN3_reHLT_2023']])
steps['RECOCOSMRUN3_reHLT_2023']=merge([{'--scenario':'cosmics','-s':'RAW2DIGI,L1Reco,RECO,DQM','--datatier':'RECO,DQMIO','--eventcontent':'RECO,DQM'},steps['RECONANORUN3_reHLT_2023']])

# Run-3 2022 skim
for s in autoSkim.keys():

if 'ZeroBias' in s:
steps['SKIM'+s.upper()+'RUN3_reHLT_2022'] = merge([{'-s':'RAW2DIGI,L1Reco,RECO,SKIM:%s,PAT,NANO,DQM:@rerecoZeroBiasFakeHLT+@miniAODDQM+@nanoAODDQM'%(autoSkim[s])},steps['RECONANORUN3_reHLT_2022']])
elif 'Cosmics' in s:
steps['SKIM'+s.upper()+'RUN3_reHLT_2022'] = merge([{'--scenario':'cosmics', '-s':'RAW2DIGI,L1Reco,RECO,SKIM:%s,DQM'%(autoSkim[s]), '--datatier':'RECO,DQMIO', '--eventcontent':'RECO,DQM'},steps['RECONANORUN3_reHLT_2022']])
else:
steps['SKIM'+s.upper()+'RUN3_reHLT_2022'] = merge([{'-s':'RAW2DIGI,L1Reco,RECO,SKIM:%s,PAT,NANO,DQM:@standardDQMFakeHLT+@miniAODDQM+@nanoAODDQM'%(autoSkim[s])},steps['RECONANORUN3_reHLT_2022']])

# Run-3 2023 skim
for s in autoSkim.keys():

if 'ZeroBias' in s:
steps['SKIM'+s.upper()+'RUN3_reHLT_2023'] = merge([{'-s':'RAW2DIGI,L1Reco,RECO,SKIM:%s,PAT,NANO,DQM:@rerecoZeroBias+@miniAODDQM+@nanoAODDQM'%(autoSkim[s])},steps['RECONANORUN3_reHLT_2023']])
elif 'Cosmics' in s:
steps['SKIM'+s.upper()+'RUN3_reHLT_2023'] = merge([{'--scenario':'cosmics', '-s':'RAW2DIGI,L1Reco,RECO,SKIM:%s,DQM'%(autoSkim[s]), '--datatier':'RECO,DQMIO', '--eventcontent':'RECO,DQM'},steps['RECONANORUN3_reHLT_2023']])
else:
steps['SKIM'+s.upper()+'RUN3_reHLT_2023'] = merge([{'-s':'RAW2DIGI,L1Reco,RECO,SKIM:%s,PAT,NANO,DQM:@standardDQM+@miniAODDQM+@nanoAODDQM'%(autoSkim[s])},steps['RECONANORUN3_reHLT_2023']])


# mask away - to be removed once we'll migrate the matrix to be fully unscheduled for RECO step
#steps['RECOmAOD']=merge([step3DefaultsUnsch])
#steps['RECOmAODUP15']=merge([step3Up2015DefaultsUnsch])
Expand Down Expand Up @@ -3552,14 +3562,17 @@ def gen2023HiMix(fragment,howMuch):

steps['HARVESTRUN3_2022']=merge([{'--data':'', '-s':'HARVESTING:@standardDQMFakeHLT+@miniAODDQM+@nanoAODDQM','--era':'Run3'},steps['HARVESTDRUN3']])
steps['HARVESTRUN3_ZB_2022']=merge([{'--data':'', '-s':'HARVESTING:@rerecoZeroBiasFakeHLT+@miniAODDQM+@nanoAODDQM','--era':'Run3'},steps['HARVESTDRUN3']])
steps['HARVESTRUN3_COS_2022']=merge([{'--data':'', '--scenario':'cosmics', '--era':'Run3', '-s':'HARVESTING:dqmHarvesting'},steps['HARVESTDRUN3']])
steps['HARVESTRUN3_2023']=merge([{'--era':'Run3_2023', '-s':'HARVESTING:@standardDQM+@miniAODDQM+@nanoAODDQM'},steps['HARVESTRUN3_2022']])
steps['HARVESTRUN3_2023B']=merge([{'--era':'Run3', '-s':'HARVESTING:@standardDQM+@miniAODDQM+@nanoAODDQM'},steps['HARVESTRUN3_2022']])
steps['HARVESTRUN3_ZB_2023B']=merge([{'--era':'Run3', '-s':'HARVESTING:@rerecoZeroBias+@miniAODDQM+@nanoAODDQM'},steps['HARVESTRUN3_2022']])
steps['HARVESTRUN3_ZB_2023']=merge([{'--era':'Run3_2023', '-s':'HARVESTING:@rerecoZeroBias+@miniAODDQM+@nanoAODDQM'},steps['HARVESTRUN3_2022']])
steps['HARVESTRUN3_COS_2023']=merge([{'--scenario':'cosmics', '--era':'Run3_2023', '-s':'HARVESTING:dqmHarvesting'},steps['HARVESTRUN3_2022']])
steps['HARVESTRUN3_pixelTrackingOnly'] = merge([ {'-s':'HARVESTING:@pixelTrackingOnlyDQM'}, steps['HARVESTRUN3_2023'] ])
steps['HARVESTRUN3_ECALOnly'] = merge([ {'-s':'HARVESTING:@ecal'}, steps['HARVESTRUN3_2023'] ])
steps['HARVESTRUN3_HCALOnly'] = merge([ {'-s':'HARVESTING:@hcalOnly'}, steps['HARVESTRUN3_2023'] ])


#MC
steps['HARVEST']={'-s':'HARVESTING:validationHarvestingNoHLT+dqmHarvestingFakeHLT',
'--conditions':'auto:run1_mc',
Expand Down
15 changes: 13 additions & 2 deletions DPGAnalysis/Skims/python/WElectronSkim_cff.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,21 @@
hltTags = cms.untracked.string( HLTPath ),
triggerEventTag = cms.untracked.InputTag("hltTriggerSummaryAOD","",HLTProcessName),
triggerResultsTag = cms.untracked.InputTag("TriggerResults","",HLTProcessName),
stageL1Trigger = cms.uint32(1)
stageL1Trigger = cms.uint32(1),
# Stage-1 L1T inputs
l1GtRecordInputTag = cms.InputTag('gtDigis'),
l1GtReadoutRecordInputTag = cms.InputTag('gtDigis'),
)
from Configuration.Eras.Modifier_stage2L1Trigger_cff import stage2L1Trigger
stage2L1Trigger.toModify(PassingHLT, stageL1Trigger = 2)
stage2L1Trigger.toModify(PassingHLT,
stageL1Trigger = 2,
# Stage-2 L1T inputs
l1tAlgBlkInputTag = cms.InputTag('gtStage2Digis'),
l1tExtBlkInputTag = cms.InputTag('gtStage2Digis'),
# remove Stage-1 L1T inputs
l1GtRecordInputTag = None,
l1GtReadoutRecordInputTag = None,
)

## _____ ____ __ _ _ _ _
## |_ _|_ _ __ _ | _ \ ___ / _(_)_ __ (_) |_(_) ___ _ __
Expand Down

0 comments on commit 0bf2204

Please sign in to comment.