Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

precision errors on Mac #167

Open
dasergatskov opened this issue Nov 17, 2024 · 3 comments
Open

precision errors on Mac #167

dasergatskov opened this issue Nov 17, 2024 · 3 comments

Comments

@dasergatskov
Copy link

On Mac (Apple CPU) there are some test failures due to precision:

Failure Summary:

  ..e/octave/api-v59/packages/statistics-1.7.0/dist_fun/hygepdf.m  pass   20/25  
                                                                   FAIL    5
  ..re/octave/api-v59/packages/statistics-1.7.0/dist_fun/ncfinv.m  pass   18/19  
                                                                   FAIL    1
  ..e/octave/api-v59/packages/statistics-1.7.0/dist_fun/ncx2inv.m  pass   15/16  
                                                                   FAIL    1

(full log attached
fntests.log.gz
Most errors are about ~eps higher.

@Sonu0305
Copy link
Contributor

Hi @dasergatskov ,
You might try setting format long to increase numerical precision and help mitigate small discrepancies.

@pr0m1th3as
Copy link
Member

@dasergatskov Can you test with latest commit on Mac (Apple CPU) before closing this issue?

@dasergatskov
Copy link
Author

Those are fixed, but now I see two kstest failures:

 load examgrades
 [h, p] = kstest (grades(:,1));
 assert (h, true);
 assert (p, 7.58603305206105e-107, 1e-14);
 [h, p] = kstest (grades(:,1), "CDF", @(x) normcdf(x, 75, 10));
 assert (h, false);
 assert (p, 0.5612, 1e-4);
!!!!! test failed
ASSERT errors for:  assert (p,0.5612,1e-4)

  Location  |  Observed  |  Expected  |  Reason
     ()        0.98208       0.5612      Abs err 0.42088 exceeds tol 0.0001 by 0.4

And those are on both Apple and linux.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants