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

Change in precision of stable entropy bins with NumPy>=1.25.0 #166

Open
rhugonnet opened this issue Oct 9, 2023 · 0 comments
Open

Change in precision of stable entropy bins with NumPy>=1.25.0 #166

rhugonnet opened this issue Oct 9, 2023 · 0 comments

Comments

@rhugonnet
Copy link
Contributor

Identified in #160. Tracked down that the change happens since NumPy 1.25.0 (CI fails for above, but not any of the 1.24.X or older), but we currently have no idea which function exactly triggers it... As only Python 3.9/3.10 use these most recent NumPy versions in CI, this is where tests fail with:

 =========================== short test summary info ============================
FAILED skgstat/tests/test_variogram.py::TestVariogramArguments::test_binning_method_stable - AssertionError: 
Arrays are not almost equal to 1 decimals

Mismatched elements: 5 / 10 (50%)
Max absolute difference: 0.21285498
Max relative difference: 0.03980185
 x: array([ 4.1,  8.6, 12.8, 17.2, 21.6, 25.2, 29.9, 33.1, 38.7, 43. ])
 y: array([ 4.3,  8.4, 12.8, 17.1, 21.4, 25.2, 29.9, 33.2, 38.5, 42.8])
FAILED skgstat/tests/test_variogram.py::TestVariogramArguments::test_binning_method_stable_fix_bins - AssertionError: 
Arrays are not almost equal to 1 decimals

Mismatched elements: 3 / 10 (30%)
Max absolute difference: 0.49334201
Max relative difference: 0.01147307
 x: array([ 4.2,  8.5, 12.8, 17.1, 21.3, 25.5, 29.6, 33.4, 37.4, 43.5])
 y: array([ 4.2,  8.6, 12.8, 17.1, 21.2, 25.5, 29.3, 33.2, 37.4, 43. ])
FAILED skgstat/tests/test_variogram.py::TestVariogramArguments::test_binning_method_stable_maxiter - AssertionError: 
Arrays are not almost equal to 1 decimals

Mismatched elements: 5 / 10 (50%)
Max absolute difference: 0.21285498
Max relative difference: 0.03980185
 x: array([ 4.1,  8.6, 12.8, 17.2, 21.6, 25.2, 29.9, 33.1, 38.7, 43. ])
 y: array([ 4.3,  8.4, 12.8, 17.1, 21.4, 25.2, 29.9, 33.2, 38.5, 42.8])

For now, the tests are temporarily fixed by changing test precision from 1 to 0 decimals.

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

1 participant