Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add HARVEST step to SKIM WF for Run3 #42277

Merged
merged 3 commits into from
Jul 23, 2023

Conversation

youyingli
Copy link
Contributor

@youyingli youyingli commented Jul 16, 2023

PR description:

Move SKIM process to step3 from step4 in Run3 skim WF and add HARVEST step to step4 i.e. modify

from

step3 : -s RAW2DIGI,L1Reco,RECO,PAT,NANO,DQM
step4 : -s SKIM

to

step3 : -s RAW2DIGI,L1Reco,RECO,SKIM,PAT,NANO,DQM
step4 : -s HARVESTING

The PR tries to fix the HARVEST missing mentioned in #42229 (comment).
Backport of the PR will be prepared after tests approved.

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-42277/36302

  • This PR adds an extra 64KB to repository

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @youyingli (You-Ying Li) for master.

It involves the following packages:

  • Configuration/PyReleaseValidation (pdmv, upgrade)

@cmsbuild, @bbilin, @srimanob, @sunilUIET, @AdrianoDee can you please review it and eventually sign? Thanks.
@makortel, @kpedro88, @Martin-Grunewald, @missirol, @fabiocos, @slomeo this is something you requested to watch as well.
@perrotta, @dpiparo, @rappoccio you are the release manager for this.

cms-bot commands are listed here

@srimanob
Copy link
Contributor

test parameters:

  • workflows = 141.101,141.102,141.103,141.104,141.105,141.106,141.107,141.108,141.109,141.110,141.111,141.112,141.113,141.114
  • relvals_opt = --what cleanedupgrade,standard,highstats,pileup,generator,extendedgen,production,identity,ged,machine,premix,nano,gpu,2017,2026

@srimanob
Copy link
Contributor

@cmsbuild please test

@cmsbuild
Copy link
Contributor

-1

Failed Tests: RelVals
Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-8af22f/33712/summary.html
COMMIT: df959bb
CMSSW: CMSSW_13_2_X_2023-07-16-0000/el8_amd64_gcc11
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/42277/33712/install.sh to create a dev area with all the needed externals and cmssw changes.

RelVals

----- Begin Fatal Exception 16-Jul-2023 17:00:35 CEST-----------------------
An exception of category 'L1GtUtils::TooManyChoices' occurred while
   [0] Constructing the EventProcessor
   [1] Running 'callWhenNewProductRegistered' for module WElecTagHLT
Exception Message:
Found multiple preferred input tags for GlobalAlgBlkBxCollection product, 
with different instaces or processes.
Tag already found: InputTag:  label = gtStage2Digis, instance = , process = reRECO
Other tag: InputTag:  label = hltGtStage2Digis, instance = , process = reHLT
----- End Fatal Exception -------------------------------------------------

@youyingli
Copy link
Contributor Author

The error happens when running WElectron skim by

step3 : -s RAW2DIGI,L1Reco,RECO,SKIM:WElectron,PAT,NANO,DQM:@standardDQM+@miniAODDQM+@nanoAODDQM

However, this never happens when running "standard" and "skim" separately as original skim wf

step3 : -s RAW2DIGI,L1Reco,RECO,PAT,NANO,DQM:@standardDQM+@miniAODDQM+@nanoAODDQM
step4 : -s SKIM:WElectron

Strange! Any suggestion?

@missirol
Copy link
Contributor

My understanding is the following.

  • The issue is related to the fact that trgMatchGsfElectronProducer internally uses L1TGlobalUtilHelper (or L1GtUtilsHelper) via HLTPrescaleProvider, and those L1T classes try to automatically discover the L1T products they should consume. When there is ambiguity in this choice, an exception is thrown (Consumes failure in BPHMonitor #39017 contains a few more details).
  • One way to solve this is to specify the correct input products in the python configuration. I would try [*]. @cms-sw/l1-l2 might have a better suggestion, since these are L1T collections.

[*]

diff --git a/DPGAnalysis/Skims/python/WElectronSkim_cff.py b/DPGAnalysis/Skims/python/WElectronSkim_cff.py
index 1d31286b028..139c6fb9e48 100644
--- a/DPGAnalysis/Skims/python/WElectronSkim_cff.py
+++ b/DPGAnalysis/Skims/python/WElectronSkim_cff.py
@@ -104,10 +104,21 @@ PassingHLT = cms.EDProducer("trgMatchGsfElectronProducer",
     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,
+)
 
 ##    _____             ____        __ _       _ _   _             
 ##   |_   _|_ _  __ _  |  _ \  ___ / _(_)_ __ (_) |_(_) ___  _ __  

@srimanob
Copy link
Contributor

@youyingli
Just to clarify, when we do reprocessing with skimming, we do it in the same cmsDriver as in this PR, or we do it separately?
Anyway, we can specify the proper input as @missirol suggests. Thx.

@aloeliger
Copy link
Contributor

My understanding is the following.

  • The issue is related to the fact that trgMatchGsfElectronProducer internally uses L1TGlobalUtilHelper (or L1GtUtilsHelper) via HLTPrescaleProvider, and those L1T classes try to automatically discover the L1T products they should consume. When there is ambiguity in this choice, an exception is thrown (Consumes failure in BPHMonitor #39017 contains a few more details).
  • One way to solve this is to specify the correct input products in the python configuration. I would try [*]. @cms-sw/l1-l2 might have a better suggestion, since these are L1T collections.

[*]

diff --git a/DPGAnalysis/Skims/python/WElectronSkim_cff.py b/DPGAnalysis/Skims/python/WElectronSkim_cff.py
index 1d31286b028..139c6fb9e48 100644
--- a/DPGAnalysis/Skims/python/WElectronSkim_cff.py
+++ b/DPGAnalysis/Skims/python/WElectronSkim_cff.py
@@ -104,10 +104,21 @@ PassingHLT = cms.EDProducer("trgMatchGsfElectronProducer",
     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,
+)
 
 ##    _____             ____        __ _       _ _   _             
 ##   |_   _|_ _  __ _  |  _ \  ___ / _(_)_ __ (_) |_(_) ___  _ __  

If I'm understanding the problem as stated correctly (the presence of gtDigis and gtStage2Digis is causing automatic discovery of the necessary collection to fail) then I would try this as well, it seems the most straightforward simple solution, i.e. just spell out what to use and where.

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-42277/36305

  • This PR adds an extra 72KB to repository

@srimanob
Copy link
Contributor

@cmsbuild please test

@cmsbuild
Copy link
Contributor

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-8af22f/33720/summary.html
COMMIT: 32885b5
CMSSW: CMSSW_13_2_X_2023-07-17-1100/el8_amd64_gcc11
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/42277/33720/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

  • You potentially removed 866 lines from the logs
  • Reco comparison results: 3 differences found in the comparisons
  • DQMHistoTests: Total files compared: 48
  • DQMHistoTests: Total histograms compared: 3195634
  • DQMHistoTests: Total failures: 3
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 3195609
  • DQMHistoTests: Total skipped: 22
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 47 files compared)
  • Checked 263 log files, 213 edm output root files, 48 DQM output files
  • TriggerResults: no differences found

@youyingli
Copy link
Contributor Author

@srimanob @sunilUIET please consider signing this PR

@sunilUIET
Copy link
Contributor

+pdmv

@srimanob
Copy link
Contributor

+Upgrade

@cmsbuild
Copy link
Contributor

This pull request is fully signed and it will be integrated in one of the next master IBs (tests are also fine). This pull request will now be reviewed by the release team before it's merged. @perrotta, @dpiparo, @rappoccio (and backports should be raised in the release meeting by the corresponding L2)

This was referenced Jul 21, 2023
@perrotta
Copy link
Contributor

+1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants