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

Use the original GEN module name for ExternalGeneratorFilter in recognizing generator types #34436

Merged

Conversation

colizz
Copy link
Contributor

@colizz colizz commented Jul 10, 2021

PR description:

When the generator type (Pythia8, Herwig7, ...) needs to be recognized from the GEN module name, the use of the ExternalGeneratorFilter module may confuse the code because it is a wrapper of the real generator module for use.

In such cases, we set the moduleName to the real generator module inside ExternalGeneratorFilter.

A backport to 10_6_X is also needed.

PR validation:

HadronAndPartonSelector is one module that detects the general type with the above method, and is in the sequence of producing NanoAOD/NanoGEN.

Below test produces the NanoGEN output for process BTV-RunIISummer20UL17GEN-00002, using ExternalGeneratorFilter as the GEN event module.

export SCRAM_ARCH=slc7_amd64_gcc900
cmsrel CMSSW_12_0_X_2021-07-09-1100
cd CMSSW_12_0_X_2021-07-09-1100/src
git cms-merge-topic colizz:dev-120X-fixModuleNameAsExternalGenFilter
curl -s -k https://cms-pdmv.cern.ch/mcm/public/restapi/requests/get_fragment/BTV-RunIISummer20UL17GEN-00002 --retry 3 --create-dirs -o Configuration/GenProduction/python/BTV-RunIISummer20UL17GEN-00002-fragment.py
scram b -j8
cd ../..

cmsDriver.py Configuration/GenProduction/python/BTV-RunIISummer20UL17GEN-00002-fragment.py --python_filename BTV-RunIISummer20UL17GEN-00002_1_cfg.py --eventcontent RAWSIM --customise Configuration/DataProcessing/Utils.addMonitoring --datatier GEN --fileout file:BTV-RunIISummer20UL17GEN-00002.root --conditions 112X_mcRun2_asymptotic_v2 --beamspot Realistic25ns13TeVEarly2017Collision --customise_commands='from GeneratorInterface.Core.ExternalGeneratorFilter import ExternalGeneratorFilter; process.generator = ExternalGeneratorFilter(process.generator)' --step GEN --geometry DB:Extended --era Run2_2017 --mc -n 10
cmsDriver.py --python_filename NanoGEN_cfg.py --eventcontent NANOAODSIM --customise Configuration/DataProcessing/Utils.addMonitoring --datatier NANOAODSIM --filein file:BTV-RunIISummer20UL17GEN-00002.root --fileout file:NanoGEN_output.root --conditions 112X_mcRun2_asymptotic_v2 --beamspot Realistic25ns13TeV2016Collision --customise_commands='from PhysicsTools.NanoAOD.nanogen_cff import customizeNanoGEN; process = customizeNanoGEN(process)\nprocess.MessageLogger.cerr.threshold = "INFO"\nprocess.MessageLogger.cerr.SpecialModule = dict()\n' --step NANOGEN --era Run2_2017,run2_nanoAOD_106Xv1 --mc -n -1

Checking %MSG-i SpecialModule and we validate that the moduleName is corrected.

@cmsbuild
Copy link
Contributor

-code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-34436/23856

  • This PR adds an extra 20KB to repository

Code check has found code style and quality issues which could be resolved by applying following patch(s)

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-34436/23857

  • This PR adds an extra 24KB to repository

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @colizz (Congqiao Li) for master.

It involves the following packages:

  • PhysicsTools/JetMCAlgos (analysis)
  • TopQuarkAnalysis/TopEventProducers (analysis)

@cmsbuild, @santocch can you please review it and eventually sign? Thanks.
@JyothsnaKomaragiri, @emilbols, @andrzejnovak this is something you requested to watch as well.
@silviodonato, @dpiparo, @qliphy, @perrotta you are the release manager for this.

cms-bot commands are listed here

…nizing generator types

set moduleName to its original module name as ExternalGeneratorFilter is a wrapper of a specific generator filter
@colizz
Copy link
Contributor Author

colizz commented Jul 10, 2021

also kindly ping generators @agrohsje, @GurpreetSinghChahal
as this is a relevant issue for the GEN modules

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-34436/23858

  • This PR adds an extra 20KB to repository

@cmsbuild
Copy link
Contributor

Pull request #34436 was updated. @cmsbuild, @santocch can you please check and sign again.

@agrohsje
Copy link

assign generators

@cmsbuild
Copy link
Contributor

New categories assigned: generators

@mkirsano,@SiewYan,@alberto-sanchez,@agrohsje,@GurpreetSinghChahal you have been requested to review this Pull request/Issue and eventually sign? Thanks

@agrohsje
Copy link

please test

@cmsbuild
Copy link
Contributor

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-56f3ad/16677/summary.html
COMMIT: 4c45163
CMSSW: CMSSW_12_0_X_2021-07-10-1100/slc7_amd64_gcc900
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/34436/16677/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: 6 differences found in the comparisons
  • DQMHistoTests: Total files compared: 38
  • DQMHistoTests: Total histograms compared: 0
  • DQMHistoTests: Total failures: 0
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 0
  • DQMHistoTests: Total skipped: 0
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 37 files compared)
  • Checked 160 log files, 37 edm output root files, 38 DQM output files
  • TriggerResults: no differences found

@qliphy
Copy link
Contributor

qliphy commented Jul 16, 2021

merge

@agrohsje
Copy link

+generators
back from vacation. thanks @colizz !

@santocch
Copy link

+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.

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.

5 participants