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

Comparison in test_index.py::IndexSerialization::test_interleaving sometimes fails #228

Closed
mwtoews opened this issue Feb 24, 2022 · 1 comment · Fixed by #273
Closed

Comments

@mwtoews
Copy link
Member

mwtoews commented Feb 24, 2022

It seems that tests/test_index.py::IndexSerialization::test_interleaving sometimes fails:

  >       assert all(
              all(np.allclose(a, b) for a, b in zip(L, E))
              for L, E in zip(leaves, expected)
          )
...
  x = array([ 2, 92, 51, 55, 26, 95,  7, 81, 38, 22, 58, 89, 91, 83, 98, 37, 70,
         31, 49, 34, 11,  6, 13,  3, 23, 57, ... 54, 88, 72, 97, 60, 62, 48, 19,
         25, 76, 59, 66, 64, 79, 94, 40, 32, 46, 47, 15, 68, 10,  0, 80, 56,
         50])
  y = array([ 2., 92., 51., 55., 26., 95.,  7., 81., 38., 22., 58., 89., 91.,
         83., 98., 37., 70., 31., 49., 34., 11.,...48., 19., 25.,
         76., 59., 66., 64., 79., 94., 40., 32., 46., 47., 15., 68., 10.,
          0., 80., 56., 50., 30.])
  Error: Command ['sh', '-c', 'pytest -v /project/tests'] failed with code 1. 
  atol = 1e-08, rtol = 1e-05
  
  
      def within_tol(x, y, atol, rtol):
          with errstate(invalid='ignore'):
  >           return less_equal(abs(x-y), atol + rtol * abs(y))
  E           ValueError: operands could not be broadcast together with shapes (69,) (70,)

looking at the test data, it should have size 70, so for some reason leaves misses the last element 30. Curious to see if this this issue is valid or intermittent. I can't replicate it locally.

Originally posted by @mwtoews in #227 (comment)

@mwtoews
Copy link
Member Author

mwtoews commented Feb 25, 2022

I suspect this is a 32-bit issue, as this only happens with "CPython 3.7 manylinux i686"

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

Successfully merging a pull request may close this issue.

1 participant