Skip to content

Conversation

JohannesGaessler
Copy link
Collaborator

Fixes #15491.

I implemented the CPU and CUDA code in such a way that the results for the tests would be exact and unaffected by floating point rounding error. However, I have no control over what is being implemented e.g. in Vulkan. So this PR changes the tests to allow for slight inprecision.

helper_after_test_forward_backward(optim, __func__, high_level, shuffle, "weights_after_forward", subtest_ok, ntest, npass);
}
{
constexpr double atol = 1e-10;
Copy link
Collaborator

Choose a reason for hiding this comment

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

This variable name is slightly disturbing, can you find a better name? :)

Copy link
Collaborator

@netrunnereve netrunnereve left a comment

Choose a reason for hiding this comment

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

Looks good on my end and the tests are passing now!

@JohannesGaessler JohannesGaessler merged commit e92734d into ggml-org:master Aug 22, 2025
48 checks passed
qnixsynapse pushed a commit to menloresearch/llama.cpp that referenced this pull request Aug 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

testing Everything test related

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Misc. bug: Vulkan test-opt test_gradient_accumulation failures on AMD

3 participants