Navigation Menu

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

Speedups to HGCal clustering #16997

Merged
merged 3 commits into from Dec 22, 2016
Merged

Conversation

lgray
Copy link
Contributor

@lgray lgray commented Dec 13, 2016

Addressing comments made at the end of: #16909

This PR significantly decreases the number of calls to sqrt() in tight loops and uses vdt where useful in the HGCal layer and multiclusters.

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @lgray (Lindsey Gray) for CMSSW_9_0_X.

It involves the following packages:

RecoLocalCalo/HGCalRecAlgos

@cmsbuild, @cvuosalo, @slava77, @davidlange6 can you please review it and eventually sign? Thanks.
@vandreev11, @sethzenz, @kpedro88, @argiro, @cseez, @pfs this is something you requested to watch as well.
@slava77, @smuzaffar you are the release manager for this.

cms-bot commands are listed here #13028

@slava77
Copy link
Contributor

slava77 commented Dec 13, 2016

@cmsbuild please test

@cmsbuild
Copy link
Contributor

The tests are being triggered in jenkins.

@slava77
Copy link
Contributor

slava77 commented Dec 13, 2016

@cmsbuild please abort

better start with a new IB present
This PR is supposedly technical

@cmsbuild
Copy link
Contributor

Jenkins tests are aborted.

@lgray
Copy link
Contributor Author

lgray commented Dec 13, 2016

@cmsbuild please test

@cmsbuild
Copy link
Contributor

The tests are being triggered in jenkins.

@slava77
Copy link
Contributor

slava77 commented Dec 13, 2016

this is still too early
there is no working baseline with multicluster PR included.

@lgray
Copy link
Contributor Author

lgray commented Dec 13, 2016 via email

@cmsbuild
Copy link
Contributor

Jenkins tests are aborted.

@lgray
Copy link
Contributor Author

lgray commented Dec 13, 2016

@cmsbuild please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Dec 13, 2016

The tests are being triggered in jenkins.
https://cmssdt.cern.ch/jenkins/job/ib-any-integration/17014/console Started: 2016/12/14 02:36

@cmsbuild
Copy link
Contributor

-1

Tested at: 6e45d59

You can see the results of the tests here:
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-16997/17014/summary.html

I found follow errors while testing this PR

Failed tests: UnitTests

  • Unit Tests:

I found errors in the following unit tests:

---> test runtestRecoLocalCaloHGCalRecProducers had ERRORS

@@ -83,14 +85,16 @@ math::XYZPoint ClusterTools::getMultiClusterPosition(const reco::HGCalMultiClust
for( const auto& ptr : clu.clusters() ) {
const double x = ptr->x();
const double y = ptr->y();
const float point_r = std::sqrt(x*x + y*y);
const double point_r2 = (x*x + y*y);
Copy link
Contributor

Choose a reason for hiding this comment

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

is double-precision well justifiable for the math here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

everything else is already in double, repeated conversion from double to float costs time.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

and this is in a tight loop

Copy link
Contributor

Choose a reason for hiding this comment

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

the reason for x,y,z and energy to be in double is debatable on the storage side.
there is nothing else inside this loop that requires double.

OK for now

return std::sqrt(distance2(pt1,pt2));
}

double HGCalImagingAlgo::distance2(const Hexel &pt1, const Hexel &pt2){
Copy link
Contributor

Choose a reason for hiding this comment

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

can this be inlined?

@lgray
Copy link
Contributor Author

lgray commented Dec 20, 2016

@cmsbuild please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Dec 20, 2016

The tests are being triggered in jenkins.
https://cmssdt.cern.ch/jenkins/job/ib-any-integration/17128/console Started: 2016/12/20 17:30

@cmsbuild
Copy link
Contributor

Pull request #16997 was updated. @cmsbuild, @cvuosalo, @slava77, @davidlange6 can you please check and sign again.

@cmsbuild
Copy link
Contributor

@cmsbuild
Copy link
Contributor

Comparison job queued.

@cmsbuild
Copy link
Contributor

@slava77
Copy link
Contributor

slava77 commented Dec 20, 2016

+1

for #16997 f921ac6

  • code optimization to speedup hgcalLayerClusters HGCalClusterTestProducer
  • jenkins tests pass and comparisons with baseline show no differences
  • local tests with ttbar with D4Timing PU200, running just RECO:hgcalLocalRecoSequence show moderate speedup: hgcalLayerClusters time changes from 31.6 s to 25.4 s per event. Comparisons for this tests show no differences in monitored persisted products (hgcal clusters and hits).

@cmsbuild
Copy link
Contributor

This pull request is fully signed and it will be integrated in one of the next CMSSW_9_0_X IBs (tests are also fine). This pull request requires discussion in the ORP meeting before it's merged. @slava77, @davidlange6, @smuzaffar

@davidlange6
Copy link
Contributor

+1

@cmsbuild cmsbuild merged commit 8fcd7e1 into cms-sw:CMSSW_9_0_X Dec 22, 2016
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

4 participants