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

fix GEM inputs for L1REPACK:FullMC #40461

Merged
merged 1 commit into from
Jan 11, 2023

Conversation

missirol
Copy link
Contributor

@missirol missirol commented Jan 9, 2023

PR description:

It looks like L1REPACK:FullMC does not work as expected on EDM inputs without the DIGI data tier, as [1] returns [2].

(This would suggest that, up to now, users were simply reading the GEM digis from the EDM inputs when running L1REPACK:FullMC.)

This PR is a tentative fix (I'm not a domain expert). It is based on what is currently done for L1REPACK:Full (which is for real data, as opposed to L1REPACK:FullMC which is for MC), e.g.

_SimL1EmulatorTaskWithGEM = SimL1EmulatorTask.copy()
_SimL1EmulatorTaskWithGEM.add(unpackGEM)
(stage2L1Trigger & run3_GEM).toReplaceWith(SimL1EmulatorTask, _SimL1EmulatorTaskWithGEM)

(L1REPACK:Full was fixed in #36133, based on #36133 (comment))

[1]

cmsDriver.py step2 -s L1REPACK:FullMC --conditions auto:phase1_2022_realistic_postEE --era Run3 \
  --datatier RAW --eventcontent RAW --geometry DB:Extended --nThreads 1 --nStreams 0 -n 10 \
  --filein /store/mc/Run3Summer22EEDR/QCD_Pt-120To170_TuneCP5_13p6TeV-pythia8/GEN-SIM-RAW/Poisson70KeepRAW_124X_mcRun3_2022_realistic_postEE_v1-v1/80000/55194757-7f7a-4fac-83b2-fc6e0b5fe7f5.root

[2]

----- Begin Fatal Exception 09-Jan-2023 18:08:53 CET-----------------------
An exception of category 'ProductNotFound' occurred while
   [0] Processing  Event run: 1 lumi: 104 event: 103002 stream: 0
   [1] Running path 'RAWoutput_step'
   [2] Prefetching for module PoolOutputModule/'RAWoutput'
   [3] Prefetching for module RawDataCollectorByLabel/'rawDataCollector'
   [4] Prefetching for module L1TDigiToRaw/'packGmtStage2'
   [5] Prefetching for module L1TMuonOverlapPhase1TrackProducer/'simOmtfDigis'
   [6] Prefetching for module CSCTriggerPrimitivesProducer/'simCscTriggerPrimitiveDigis'
   [7] Prefetching for module GEMPadDigiClusterProducer/'simMuonGEMPadDigiClusters'
   [8] Calling method for module GEMPadDigiProducer/'simMuonGEMPadDigis'
Exception Message:
Principal::getByToken: Found zero products matching all criteria
Looking for type: MuonDigiCollection<GEMDetId,GEMDigi>
Looking for module label: simMuonGEMDigis
Looking for productInstanceName: 

   Additional Info:
      [a] If you wish to continue processing events after a ProductNotFound exception,
add "SkipEvent = cms.untracked.vstring('ProductNotFound')" to the "options" PSet in the configuration.

----- End Fatal Exception -------------------------------------------------

PR validation:

Nothing beyond the use case described in the PR description.

If this PR is a backport, please specify the original PR and why you need to backport that PR. If this PR will be backported, please specify to which release cycle the backport is meant for:

Plan to backport to (at least) 12_6_X to aid HLT studies.

CMSSW_12_4_X
CMSSW_12_5_X
CMSSW_12_6_X

@cmsbuild
Copy link
Contributor

cmsbuild commented Jan 9, 2023

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-40461/33624

  • This PR adds an extra 16KB to repository

@cmsbuild
Copy link
Contributor

cmsbuild commented Jan 9, 2023

A new Pull Request was created by @missirol (Marino Missiroli) for master.

It involves the following packages:

  • Configuration/StandardSequences (operations)

@cmsbuild, @perrotta, @rappoccio, @fabiocos, @davidlange6 can you please review it and eventually sign? Thanks.
@fabiocos, @VourMa, @makortel, @felicepantaleo, @GiacomoSguazzoni, @JanFSchulte, @rovere, @VinInn, @Martin-Grunewald, @lecriste, @mmusich, @sameasy, @mtosi, @dgulhan, @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

@missirol
Copy link
Contributor Author

missirol commented Jan 9, 2023

assign l1

@cmsbuild
Copy link
Contributor

cmsbuild commented Jan 9, 2023

New categories assigned: l1

@epalencia,@rekovic,@cecilecaillol you have been requested to review this Pull request/Issue and eventually sign? Thanks

@missirol
Copy link
Contributor Author

missirol commented Jan 9, 2023

please test

@cms-sw/l1-l2 , is there any wf testing L1REPACK:FullMC in CMSSW ?

@cmsbuild
Copy link
Contributor

cmsbuild commented Jan 9, 2023

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-1dd99c/29854/summary.html
COMMIT: e290d42
CMSSW: CMSSW_13_0_X_2023-01-09-1100/el8_amd64_gcc11
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week1/cms-sw/cmssw/40461/29854/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

  • No significant changes to the logs found
  • Reco comparison results: 12 differences found in the comparisons
  • DQMHistoTests: Total files compared: 49
  • DQMHistoTests: Total histograms compared: 3555538
  • DQMHistoTests: Total failures: 160
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 3555356
  • DQMHistoTests: Total skipped: 22
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 48 files compared)
  • Checked 211 log files, 162 edm output root files, 49 DQM output files
  • TriggerResults: no differences found

@missirol
Copy link
Contributor Author

@cms-sw/l1-l2

Could you please have a look, and check if this fix is correct? If so, it would be useful to have this in 13_0_0_pre3 (deadline: today), and it will have to be backported. Thanks!

@cecilecaillol
Copy link
Contributor

+l1

@missirol
Copy link
Contributor Author

type bugfix

@@ -60,6 +67,8 @@ def _print(ignored):
# CSC TPs
simCscTriggerPrimitiveDigis.CSCComparatorDigiProducer = 'unpackCSC:MuonCSCComparatorDigi'
simCscTriggerPrimitiveDigis.CSCWireDigiProducer = 'unpackCSC:MuonCSCWireDigi'
# GEM
run3_GEM.toModify(simMuonGEMPadDigis, InputCollection = 'unpackGEM')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the same as what currently in SimL1EmulatorRepack_Full_cff.py, therefore I imagine it may work and my question is probably silly...

But what happens if run3_GEM and not stage2L1Trigger? 'unpackGEM' is feed as InputCollection to simMuonGEMPadDigis [1], but the SimL1EmulatorTask is not updates with the unpackGEM module in it [2]

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, I can only guess as a non-L1T expert.

  • This file only really works for stage2L1Trigger, according to the comments up top ("only supports Stage 2 eras for now."), modulo the fact that the comments are mistakenly swapped (the first comment, "use a legacy version", should show for ~stage2L1Trigger, not for stage2L1Trigger)
  • In practise, I think stage2L1Trigger applies to nearly anything after 2015, so "run3_GEM and not stage2L1Trigger" should never happen (in principle..).

Let me fix the comments, since I would like to backport this..

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you Marino, this is also my understanding.
However, even if so, the clean way to implement I imagine it should be

Suggested change
run3_GEM.toModify(simMuonGEMPadDigis, InputCollection = 'unpackGEM')
(stage2L1Trigger & run3_GEM).toModify(simMuonGEMPadDigis, InputCollection = 'unpackGEM')

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Following what I see elsewhere, e.g.

(stage2L1Trigger & run3_GEM).toReplaceWith( SimL1TMuonTask, cms.Task(simMuonGEMPadTask,_run3_SimL1TMuonTask) )

I can change run3_GEM to (stage2L1Trigger & run3_GEM) also above (and in "Full").

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

However, even if so, the clean way to implement I imagine it should be

I cross-posted. Yes, will do (soon).

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-40461/33642

  • This PR adds an extra 16KB to repository

@missirol missirol force-pushed the devel_fixGEMRawToDigiInL1TFullMC branch from 7cb44b3 to 633c942 Compare January 10, 2023 16:51
@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-40461/33643

  • This PR adds an extra 16KB to repository

@cmsbuild
Copy link
Contributor

Pull request #40461 was updated. @perrotta, @rappoccio, @epalencia, @cecilecaillol, @cmsbuild, @rekovic, @fabiocos, @davidlange6 can you please check and sign again.

@perrotta
Copy link
Contributor

please test

@cmsbuild
Copy link
Contributor

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-1dd99c/29892/summary.html
COMMIT: 633c942
CMSSW: CMSSW_13_0_X_2023-01-10-1100/el8_amd64_gcc11
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week1/cms-sw/cmssw/40461/29892/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

  • No significant changes to the logs found
  • Reco comparison results: 35 differences found in the comparisons
  • DQMHistoTests: Total files compared: 49
  • DQMHistoTests: Total histograms compared: 3555538
  • DQMHistoTests: Total failures: 1194
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 3554322
  • DQMHistoTests: Total skipped: 22
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 48 files compared)
  • Checked 211 log files, 162 edm output root files, 49 DQM output files
  • TriggerResults: no differences found

@missirol
Copy link
Contributor Author

@cms-sw/l1-l2, could you please check again, and re-sign? Thanks!

The diff of this PR since your previous signature is below:
https://github.com/cms-sw/cmssw/compare/e290d429c270dae5dc61c0c2db06d311f3c18fb5..633c942bdab6a2318b7fda5bd266180520c0057b

@cecilecaillol
Copy link
Contributor

+l1

@perrotta
Copy link
Contributor

+1

@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 be automatically merged.

@cmsbuild cmsbuild merged commit fe42e8d into cms-sw:master Jan 11, 2023
@missirol missirol deleted the devel_fixGEMRawToDigiInL1TFullMC branch January 11, 2023 10:02
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.

4 participants