Skip to content

Conversation

@f3sch
Copy link
Collaborator

@f3sch f3sch commented Dec 1, 2025

@shahor02 this is the corresponding GPU adaptation of the refit with new linearisation point&reseeding.
Comparing 100 TFs GPU/CPU in deterministic mode shows 1:1 output.
Inward param:
ptRatioCN
Outward param:
paramOutRatioCN

Note to buildTrackSeed, I added a reverse option to account for the sign change in the curvature if the clusters are given in reverse order.

@github-actions
Copy link
Contributor

github-actions bot commented Dec 1, 2025

REQUEST FOR PRODUCTION RELEASES:
To request your PR to be included in production software, please add the corresponding labels called "async-" to your PR. Add the labels directly (if you have the permissions) or add a comment of the form (note that labels are separated by a ",")

+async-label <label1>, <label2>, !<label3> ...

This will add <label1> and <label2> and removes <label3>.

The following labels are available
async-2023-pbpb-apass4
async-2023-pp-apass4
async-2024-pp-apass1
async-2022-pp-apass7
async-2024-pp-cpass0
async-2024-PbPb-apass1
async-2024-ppRef-apass1
async-2024-PbPb-apass2
async-2023-PbPb-apass5

Copy link
Collaborator

@shahor02 shahor02 left a comment

Choose a reason for hiding this comment

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

Thanks! See some comments below.

const float tgl12 = math_utils::computeTanDipAngle(x1, y1, x2, y2, z1, z2);
const float tgl23 = math_utils::computeTanDipAngle(x2, y2, x3, y3, z2, z3);
const float q2pt = zeroField ? 1.f / o2::track::kMostProbablePt : crv / (bz * o2::constants::math::B2C);
const float q2pt = zeroField ? sign / o2::track::kMostProbablePt : crv / (bz * o2::constants::math::B2C);
Copy link
Collaborator

Choose a reason for hiding this comment

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

sign (in case of reverse) should be applied to the right if choice, to invert the curvature

Comment on lines 145 to 147
const float tgp = zeroField ? sign * o2::gpu::CAMath::ATan2(y3 - y1, x3 - x1) : 1.f;
const float crv = sign * (zeroField ? 1.f : math_utils::computeCurvature(x3, y3, x2, y2, x1, y1));
const float snp = (zeroField ? tgp / o2::gpu::CAMath::Sqrt(1.f + tgp * tgp) : crv * (x3 - math_utils::computeCurvatureCentreX(x3, y3, x2, y2, x1, y1)));
Copy link
Collaborator

Choose a reason for hiding this comment

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

The sign inversion should be applied to snp (and crv, see later) rather than to tgp.

Comment on lines 1265 to 1270
tgp = sign * o2::gpu::CAMath::ATan2(y3 - y1, x3 - x1);
snp = tgp / o2::gpu::CAMath::Sqrt(1.f + tgp * tgp);
q2pt *= sign;
} else {
crv = math_utils::computeCurvature(x3, y3, x2, y2, x1, y1);
crv = sign * math_utils::computeCurvature(x3, y3, x2, y2, x1, y1);
snp = crv * (x3 - math_utils::computeCurvatureCentreX(x3, y3, x2, y2, x1, y1));
Copy link
Collaborator

Choose a reason for hiding this comment

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

Here too:for the reverse clusters order the snp and crv signs should be inverted.

f3sch added 2 commits December 1, 2025 20:19
Signed-off-by: Felix Schlepper <felix.schlepper@cern.ch>
Signed-off-by: Felix Schlepper <felix.schlepper@cern.ch>
@davidrohr davidrohr merged commit e12ca36 into AliceO2Group:dev Dec 3, 2025
11 of 12 checks passed
@f3sch f3sch deleted the its/gpu/reseed branch December 3, 2025 10:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants