Skip to content

[Fix] l2_exp random fail in half-float32 mixed precision on self-neighboring#596

Merged
rapids-bot[bot] merged 2 commits intorapidsai:branch-25.02from
rhdong:rhdong/fix-mixed
Jan 22, 2025
Merged

[Fix] l2_exp random fail in half-float32 mixed precision on self-neighboring#596
rapids-bot[bot] merged 2 commits intorapidsai:branch-25.02from
rhdong:rhdong/fix-mixed

Conversation

@rhdong
Copy link
Copy Markdown
Member

@rhdong rhdong commented Jan 21, 2025

No description provided.

Copy link
Copy Markdown
Contributor

@benfred benfred left a comment

Choose a reason for hiding this comment

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

PR looks good to me - had a couple of minor questions though

from cuvs.distance import pairwise_distance


@pytest.mark.parametrize("times", range(20))
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Whats this times parameter used for? I don't see it used in the test it self -

Are you just trying to run this test multiple times here to stress test it?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Yeah, it's just for testing multiple times and to guarantee the reproducing on one going because the possibility is close to ~10% empirically.


tol = 1e-3
if np.issubdtype(dtype, np.float16):
tol = 1e-1
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I think I added this reduced tolerance because I was seeing failures - is this no longer needed?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Yeah, I tried it successfully at local machines. I think this change can help us block potential actual failures in the future, so I made it.

@bdice
Copy link
Copy Markdown
Contributor

bdice commented Jan 22, 2025

Looks like Python tests are now passing. We are waiting on one more C++ test job. I will go ahead and trigger a merge once CI finishes to unblock CI, since several PRs depend on this.

@bdice
Copy link
Copy Markdown
Contributor

bdice commented Jan 22, 2025

/merge

@rapids-bot rapids-bot bot merged commit 1c91e1f into rapidsai:branch-25.02 Jan 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working C++ cpp non-breaking Introduces a non-breaking change Python

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants