Skip to content

Commit

Permalink
refactor: move multipleScattering2 to seeding options (#2010)
Browse files Browse the repository at this point in the history
This PR moves the calculation of `m_config.maxScatteringAngle2 * m_config.sigmaScattering * m_config.sigmaScattering` to the seeding option since it can be done only once
  • Loading branch information
LuisFelipeCoelho committed Apr 4, 2023
1 parent 9cdd5e4 commit 01bbf1f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
4 changes: 1 addition & 3 deletions Core/include/Acts/Seeding/SeedFinder.ipp
Original file line number Diff line number Diff line change
Expand Up @@ -428,9 +428,7 @@ inline void SeedFinder<external_spacepoint_t, platform_t>::filterCandidates(
// resolving with pT to p scaling --> only divide by sin^2(theta)
// max approximation error for allowed scattering angles of 0.04 rad at
// eta=infinity: ~8.5%
float scatteringInRegion2 = m_config.maxScatteringAngle2 * iSinTheta2;
// multiply the squared sigma onto the squared scattering
scatteringInRegion2 *= m_config.sigmaScattering * m_config.sigmaScattering;
float scatteringInRegion2 = options.multipleScattering2 * iSinTheta2;

float sinTheta = 1 / std::sqrt(iSinTheta2);
float cosTheta = cotThetaB * sinTheta;
Expand Down
3 changes: 3 additions & 0 deletions Core/include/Acts/Seeding/SeedFinderConfig.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,7 @@ struct SeedFinderOptions {
float minHelixDiameter2 = std::numeric_limits<float>::quiet_NaN();
float pT2perRadius = std::numeric_limits<float>::quiet_NaN();
float sigmapT2perRadius = std::numeric_limits<float>::quiet_NaN();
float multipleScattering2 = std::numeric_limits<float>::quiet_NaN();

bool isInInternalUnits = false;

Expand Down Expand Up @@ -264,6 +265,8 @@ struct SeedFinderOptions {
std::pow(config.highland / options.pTPerHelixRadius, 2);
options.sigmapT2perRadius =
options.pT2perRadius * std::pow(2 * config.sigmaScattering, 2);
options.multipleScattering2 =
config.maxScatteringAngle2 * std::pow(config.sigmaScattering, 2);
return options;
}
};
Expand Down
4 changes: 1 addition & 3 deletions Core/include/Acts/Seeding/SeedFinderOrthogonal.ipp
Original file line number Diff line number Diff line change
Expand Up @@ -353,9 +353,7 @@ void SeedFinderOrthogonal<external_spacepoint_t>::filterCandidates(
// resolving with pT to p scaling --> only divide by sin^2(theta)
// max approximation error for allowed scattering angles of 0.04 rad at
// eta=infinity: ~8.5%
float scatteringInRegion2 = m_config.maxScatteringAngle2 * iSinTheta2;
// multiply the squared sigma onto the squared scattering
scatteringInRegion2 *= m_config.sigmaScattering * m_config.sigmaScattering;
float scatteringInRegion2 = options.multipleScattering2 * iSinTheta2;

// minimum number of compatible top SPs to trigger the filter for a certain
// middle bottom pair if seedConfirmation is false we always ask for at
Expand Down

0 comments on commit 01bbf1f

Please sign in to comment.