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

TestGeary::test_by_col[W] failure -- 312-numba-dev #338

Open
jGaboardi opened this issue Jul 20, 2024 · 0 comments
Open

TestGeary::test_by_col[W] failure -- 312-numba-dev #338

jGaboardi opened this issue Jul 20, 2024 · 0 comments
Assignees
Labels

Comments

@jGaboardi
Copy link
Member

jGaboardi commented Jul 20, 2024

FAILED esda/tests/test_geary.py::TestGeary::test_by_col[W] - AssertionError: 
Not equal to tolerance rtol=1e-07, atol=0

Mismatched elements: 1 / 1 (100%)
Max absolute difference among violations: 0.001
Max relative difference among violations: 1.
 ACTUAL: array([0.002])
 DESIRED: array(0.001)
= 1 failed, 149 passed, 9 skipped, 2 xpassed, 110 warnings in 95.26s (0:01:35) =

=================================== FAILURES ===================================
___________________________ TestGeary.test_by_col[W] ___________________________
[gw2] linux -- Python 3.12.4 /home/runner/micromamba/envs/test/bin/python3.12

self = <esda.tests.test_geary.TestGeary object at 0x7f7b019a87d0>
w = <libpysal.weights.contiguity.Rook object at 0x7f7b01b8ca40>

    @parametrize_w
    def test_by_col(self, w):
        import pandas as pd
    
        df = pd.DataFrame(self.y, columns=["y"])
        r1 = geary.Geary.by_col(df, ["y"], w=w, permutations=999)
        this_geary = np.unique(r1.y_geary.values)
        this_pval = np.unique(r1.y_p_sim.values)
        np.random.seed(12345)
        c = geary.Geary(self.y, w, permutations=999)
        np.testing.assert_allclose(this_geary, c.C)
>       np.testing.assert_allclose(this_pval, c.p_sim)

esda/tests/test_geary.py:74: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

args = (<function assert_allclose.<locals>.compare at 0x7f7b0195e2a0>, array([0.002]), array(0.001))
kwds = {'equal_nan': True, 'err_msg': '', 'header': 'Not equal to tolerance rtol=1e-07, atol=0', 'strict': False, ...}

    @wraps(func)
    def inner(*args, **kwds):
        with self._recreate_cm():
>           return func(*args, **kwds)
E           AssertionError: 
E           Not equal to tolerance rtol=1e-07, atol=0
E           
E           Mismatched elements: 1 / 1 (100%)
E           Max absolute difference among violations: 0.001
E           Max relative difference among violations: 1.
E            ACTUAL: array([0.002])
E            DESIRED: array(0.001)

../../../micromamba/envs/test/lib/python3.12/contextlib.py:81: AssertionError
@jGaboardi jGaboardi changed the title TestGeary::test_by_col[W] failure -- 312-numba-dev TestGeary::test_by_col[W] failure -- 312-numba-dev Jul 20, 2024
@martinfleis martinfleis removed their assignment Jul 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants