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

refactor!: std::unique_ptr to std::optional in Acts::PropagatorResult #1622

Conversation

benjaminhuth
Copy link
Member

This changes the type that stores the parameters and covariance matrix in the Acts::PropagatorResult.

I'm not sure why we have std::unique_ptr here, maybe this is from pre-C++17 where std::optional was not available? However, both from usibility (not copy-able) and from performance perspective (heap allocation) this does not make sense to me, but maybe I forget something...

@benjaminhuth benjaminhuth added Component - Core Affects the Core module Improvement Changes to an existing feature Impact - Minor Nuissance bug and/or affects only a single module labels Oct 25, 2022
@benjaminhuth benjaminhuth added this to the next milestone Oct 25, 2022
@benjaminhuth benjaminhuth added the 🚧 WIP Work-in-progress label Oct 25, 2022
Copy link
Contributor

@andiwand andiwand left a comment

Choose a reason for hiding this comment

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

I guess the only advantage of std::unique_ptr is that the struct is more densely packed. but that doesn't look like a critical property here

Core/include/Acts/Propagator/Propagator.hpp Show resolved Hide resolved
@codecov
Copy link

codecov bot commented Oct 31, 2022

Codecov Report

Merging #1622 (3d18c3f) into main (5c07814) will decrease coverage by 0.04%.
The diff coverage is 18.75%.

❗ Current head 3d18c3f differs from pull request most recent head dfdd16d. Consider uploading reports for the commit dfdd16d to get more accurate results

@@            Coverage Diff             @@
##             main    #1622      +/-   ##
==========================================
- Coverage   48.65%   48.60%   -0.05%     
==========================================
  Files         381      381              
  Lines       20780    20826      +46     
  Branches     9518     9553      +35     
==========================================
+ Hits        10110    10122      +12     
- Misses       4099     4101       +2     
- Partials     6571     6603      +32     
Impacted Files Coverage Δ
Core/include/Acts/Propagator/Propagator.hpp 90.24% <ø> (ø)
Core/include/Acts/Propagator/Propagator.ipp 47.22% <0.00%> (-5.28%) ⬇️
...re/include/Acts/Vertexing/ImpactPointEstimator.hpp 100.00% <ø> (ø)
...re/include/Acts/Vertexing/ImpactPointEstimator.ipp 35.67% <0.00%> (-0.59%) ⬇️
.../include/Acts/Vertexing/HelicalTrackLinearizer.ipp 26.80% <14.28%> (-0.75%) ⬇️
...clude/Acts/Vertexing/AdaptiveMultiVertexFitter.ipp 46.00% <33.33%> (ø)
...re/include/Acts/TrackFitting/GaussianSumFitter.hpp 64.63% <100.00%> (ø)
Core/src/TrackFitting/GsfUtils.cpp 27.27% <0.00%> (-17.18%) ⬇️
Core/src/TrackFinding/MeasurementSelector.cpp 21.42% <0.00%> (-11.91%) ⬇️
Core/src/TrackFitting/GainMatrixUpdater.cpp 15.15% <0.00%> (-4.85%) ⬇️
... and 11 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@benjaminhuth
Copy link
Member Author

@andiwand After fixing the unittests etc, could you reapprove
@paulgessinger This should be good to go in now, so would be cool to wait with the next major release until this is in.

@github-actions
Copy link

github-actions bot commented Oct 31, 2022

📊 Physics performance monitoring for dfdd16d

Full report
CKF: seeded, truth smeared, truth estimated
IVF: seeded, truth smeared, truth estimated
Ambiguity resolution
Truth tracking

Vertexing

IVF seeded

IVF truth smeared

IVF truth estimated

CKF

seeded

truth smeared

truth estimated

Ambiguity resolution

seeded

Truth tracking

Truth tracking

@andiwand andiwand added automerge and removed 🚧 WIP Work-in-progress labels Oct 31, 2022
@paulgessinger paulgessinger merged commit ec15a62 into acts-project:main Nov 1, 2022
@github-actions github-actions bot removed the automerge label Nov 1, 2022
@paulgessinger paulgessinger modified the milestones: next, v21.0.0 Nov 3, 2022
@benjaminhuth benjaminhuth deleted the refactor/unique-ptr-in-prop-result branch November 9, 2022 13:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component - Core Affects the Core module Impact - Minor Nuissance bug and/or affects only a single module Improvement Changes to an existing feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants