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
Backport Puppi speedups [10_6_X] #37718
Conversation
A new Pull Request was created by @kpedro88 (Kevin Pedro) for CMSSW_10_6_X. It involves the following packages:
@jpata, @cmsbuild, @clacaputo, @slava77 can you please review it and eventually sign? Thanks. cms-bot commands are listed here |
please test |
+1 Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-6021ad/24287/summary.html Comparison SummarySummary:
|
type jetmet |
test parameters
|
@cmsbuild please test |
@jpata @kpedro88 , looks like the default workflow for profiling |
Actually we were not sure what will happen when profiling in this backport, good to know that it fails due to the missing Phase2 workflow. I guess it's not critical here, one can rely on the profiling in the master. |
To my recollection, none of the prodlike workflows used for profiling are available in 10_6_X. |
+1 Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-6021ad/24373/summary.html Comparison SummarySummary:
|
+reconstruction
|
This pull request is fully signed and it will be integrated in one of the next CMSSW_10_6_X IBs (tests are also fine) and once validation in the development release cycle CMSSW_12_4_X is complete. 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) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since you are cleaning and you are not verbatim backporting the three PRs, you can also consider:
@@ -287,33 +282,36 @@ void PuppiProducer::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) { | |||
const reco::PFCandidate *cand = dynamic_cast<const reco::PFCandidate*>(&aCand); | |||
pfCand.reset( new reco::PFCandidate( cand ? *cand : reco::PFCandidate(aCand.charge(), aCand.p4(), id) ) ); | |||
} | |||
LorentzVector pVec; | |||
|
|||
//get an index to a pup in lCandidates: either fUseExistingWeights with no skips or get from fPuppiContainer | |||
int iPuppiMatched = fUseExistingWeights ? val : fPuppiContainer->recoToPup()[val]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if ( fUseExistingWeights ) {
puppiP4s.emplace_back(lWeights[val]*aCand.px(), lWeights[val]*aCand.py(), lWeights[val]*aCand.pz(), lWeights[val]*aCand.energy());
}
else {
int iPuppiMatched = fPuppiContainer->recoToPup()[val];
if ( iPuppiMatched >= 0 ) {
@perrotta done in the latest commit |
Pull request #37718 was updated. @jpata, @cmsbuild, @clacaputo, @slava77 can you please check and sign again. |
please test |
+1 Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-6021ad/24630/summary.html Comparison SummarySummary:
|
+reconstruction |
This pull request is fully signed and it will be integrated in one of the next CMSSW_10_6_X IBs (tests are also fine) and once validation in the development release cycle CMSSW_12_4_X is complete. 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) |
+1
|
PR description:
This PR is a combined backport of three speedups for Puppi:
useExistingWeights
case (based on Simplify PUPPI Photon producer and change PUPPI isolation algo #27929)useExistingWeights
case (based on Fix a discrepancy in Puppi weights when running on MiniAOD w/ useExistingWeights=False #28033)In my test of the
useExistingWeights
case (on a UL17 ttbar sample), the combination of these three changes reduced the CPU usage ofPuppiProducer
by 50%.PR validation:
Code compiles and runs. CPU impact quantified with igprof. Compared AK8 jet pT in a ttbar workflow to confirm that no changes occurred.
if this PR is a backport please specify the original PR and why you need to backport that PR:
See above. Reason: to speed up ultra-legacy analysis processing.