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

Validate TF1 if requested in BTagEntry #35856

Merged
merged 1 commit into from Oct 27, 2021

Conversation

Dr15Jones
Copy link
Contributor

PR description:

Validating the BTagEntry everytime it was read from the CSV file was dominating the Nano jobs startup times. Converting that to be optional made the module's startup time > 25x faster.

During an earlier buggy version of this PR, I found that even with validation turned off, cmsRun will cause ROOT to generate an exception if an invalid string is passed to TF1.

PR validation:

Code compiles. Running RelVal 23434.21 step 5 did not generate any errors.

Validating the BTagEntry everytime it was read from the CSV file
was dominating the Nano jobs startup times. Converting that to be
optional made the module's startup time > 25x faster.
@Dr15Jones
Copy link
Contributor Author

From the IB RelVal IgProf report for Nano step, we used to have
https://cmssdt.cern.ch/SDT/cgi-bin/igprof-navigator/CMSSW_12_1_X_2021-10-25-2300/slc7_amd64_gcc900/pp/23434.21_TTbar_14TeV+2026D49PU_ProdLike+TTbar_14TeV_TuneCP5_GenSimHLBeamSpot14+DigiTriggerPU+RecoGlobalPU+MiniAODPU+NanoPU/step5___dce6e29f4983ff43b2f3c2f7cef0ced5___10_EndOfJob/19

Rank | % total | Counts | Paths | Symbol name
-- | -- | -- | -- | --

     | 29.29 | 21.58 | 31.73 | 1 | 2 | edm::Maker::makeModule(edm::MakeModuleParams const&, edm::signalslot::Signal<void (edm::ModuleDescription const&)>&, edm::signalslot::Signal<void (edm::ModuleDescription const&)>&) const
[19] | 29.29 | 0.00 | 21.58 | 1 | 1 | edm::stream::ProducingModuleAdaptorBase<edm::stream::EDProducerBase>::doPreallocate(edm::PreallocationConfiguration const&)
     | 25.10 | 18.49 | 18.49 | 1 | 1 | edm::stream::ProducingModuleAdaptor<BTagSFProducer, edm::stream::EDProducerBase, edm::stream::EDProducerAdaptorBase>::setupStreamModules()
     | 0.81 | 0.59 | 0.59 | 1 | 1 | edm::stream::ProducingModuleAdaptor<VersionedIdProducer<edm::Ptr<reco::GsfElectron>, VersionedSelector<edm::Ptr<reco::GsfElectron> > >, edm::stream::EDProducerBase, edm::stream::EDProducerAdaptorBase>::setupStreamModules()
     | 0.69 | 0.51 | 0.51 | 1 | 1 | edm::stream::ProducingModuleAdaptor<BJetEnergyRegressionMVA, edm::stream::EDProducerBase, edm::stream::EDProducerAdaptorBase>::setupStreamModules()

Where the full startup is

Rank | % total | Counts | Paths | Symbol name
-- | -- | -- | -- | --

    | 64.56 | 47.55 | 47.55 | 1 | 1 | edm::EventProcessor::EventProcessor(std::shared_ptr<edm::ProcessDesc>, edm::ServiceToken const&, edm::serviceregistry::ServiceLegacy)
[9] | 64.56 | 0.00 | 47.55 | 1 | 1 | edm::EventProcessor::init(std::shared_ptr<edm::ProcessDesc>&, edm::ServiceToken const&, edm::serviceregistry::ServiceLegacy)
    | 50.19 | 36.98 | 36.98 | 1 | 1 | edm::ScheduleItems::initSchedule(edm::ParameterSet&, bool, edm::PreallocationConfiguration const&, edm::ProcessContext const*, edm::ProcessBlockHelperBase&)
    | 9.61 | 7.08 | 7.08 | 1 | 1 | edm::makeInput(edm::ParameterSet&, edm::CommonParams const&, std::shared_ptr<edm::ProductRegistry>, std::shared_ptr<edm::BranchIDListHelper>, std::shared_ptr<edm::ProcessBlockHelper> const&, std::shared_ptr<edm::ThinnedAssociationsHelper>, std::shared_ptr<edm::ActivityRegistry>, std::shared_ptr<edm::ProcessConfiguration const>, edm::PreallocationConfiguration const&)
    | 3.35 | 2.47 | 2.47 | 1 | 1 | edm::eventsetup::EventSetupsController::makeProvider(edm::ParameterSet&, edm::ActivityRegistry*, edm::ParameterSet const*, unsigned int, bool)

So BTagSFProducer was taking 39% of the startup time.

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-35856/26234

  • This PR adds an extra 24KB to repository

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @Dr15Jones (Chris Jones) for master.

It involves the following packages:

  • CondFormats/BTauObjects (db, alca)
  • CondTools/BTau (db)
  • PhysicsTools/NanoAOD (xpog)

@malbouis, @yuanchao, @cmsbuild, @gouskos, @fgolf, @ggovi, @mariadalfonso, @tvami, @francescobrivio can you please review it and eventually sign? Thanks.
@AlexDeMoor, @emilbols, @swertz, @tocheng, @JyothsnaKomaragiri, @gpetruc, @mmusich, @demuller, @andrzejnovak, @seemasharmafnal this is something you requested to watch as well.
@perrotta, @dpiparo, @qliphy you are the release manager for this.

cms-bot commands are listed here

@Dr15Jones
Copy link
Contributor Author

please test

@cmsbuild
Copy link
Contributor

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-ce0f02/19969/summary.html
COMMIT: 281253c
CMSSW: CMSSW_12_1_X_2021-10-26-1100/slc7_amd64_gcc900
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/35856/19969/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: 0 differences found in the comparisons
  • DQMHistoTests: Total files compared: 41
  • DQMHistoTests: Total histograms compared: 2797338
  • DQMHistoTests: Total failures: 0
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 2797316
  • DQMHistoTests: Total skipped: 22
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 40 files compared)
  • Checked 173 log files, 37 edm output root files, 41 DQM output files
  • TriggerResults: no differences found

@ggovi
Copy link
Contributor

ggovi commented Oct 27, 2021

+1

@tvami
Copy link
Contributor

tvami commented Oct 27, 2021

+alca

@mariadalfonso
Copy link
Contributor

+xpog

@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, @qliphy (and backports should be raised in the release meeting by the corresponding L2)

@perrotta
Copy link
Contributor

+1

@cmsbuild cmsbuild merged commit b5bccbf into cms-sw:master Oct 27, 2021
@Dr15Jones Dr15Jones deleted the fasterNanoStartup branch October 28, 2021 13:57
@mariadalfonso
Copy link
Contributor

@Dr15Jones
can you make a backport to the 10_6_X ?
this will help the UL analyses

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.

None yet

6 participants