Skip to content

Commit

Permalink
Merge branch 'main' into refactor/dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
kodiakhq[bot] authored Mar 21, 2022
2 parents 7804fa9 + c30bcf8 commit 048772c
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
4 changes: 4 additions & 0 deletions Core/include/Acts/Seeding/SeedFinderUtils.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ struct LinCircle {
float Er;
float U;
float V;
float x;
float y;
float z;
float r;
};

/// @brief Transform two spacepoints to a u-v space circle.
Expand Down
13 changes: 12 additions & 1 deletion Core/include/Acts/Seeding/SeedFinderUtils.ipp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ LinCircle transformCoordinates(InternalSpacePoint<external_spacepoint_t>& sp,

template <typename external_spacepoint_t>
void transformCoordinates(
const std::vector<InternalSpacePoint<external_spacepoint_t>*>& vec,
std::vector<InternalSpacePoint<external_spacepoint_t>*>& vec,
InternalSpacePoint<external_spacepoint_t>& spM, bool bottom,
bool enableCutsForSortedSP, std::vector<LinCircle>& linCircleVec) {
float xM = spM.x();
Expand Down Expand Up @@ -92,11 +92,22 @@ void transformCoordinates(
l.Er = ((varianceZM + sp->varianceZ()) +
(cot_theta * cot_theta) * (varianceRM + sp->varianceR())) *
iDeltaR2;

l.x = sp->x();
l.y = sp->y();
l.z = sp->z();
l.r = sp->radius();

linCircleVec.push_back(l);
sp->setCotTheta(cot_theta);
}
// sort the SP in order of cotTheta
if (enableCutsForSortedSP) {
std::sort(vec.begin(), vec.end(),
[](InternalSpacePoint<external_spacepoint_t>* a,
InternalSpacePoint<external_spacepoint_t>* b) -> bool {
return (a->cotTheta() < b->cotTheta());
});
std::sort(linCircleVec.begin(), linCircleVec.end(),
[](const LinCircle& a, const LinCircle& b) -> bool {
return (a.cotTheta < b.cotTheta);
Expand Down

0 comments on commit 048772c

Please sign in to comment.