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

Numpy version issue? #85

Open
arnicas opened this issue Aug 17, 2022 · 2 comments
Open

Numpy version issue? #85

arnicas opened this issue Aug 17, 2022 · 2 comments

Comments

@arnicas
Copy link

arnicas commented Aug 17, 2022

Something in string_grouper's pip install is removing numpy.1.23 and reverting to 1.22 but then there is an error with import saying the wrong version of numpy is in use. Any ideas?

@arnicas
Copy link
Author

arnicas commented Aug 17, 2022

Update on this --- it seems to be one of those "numpy compatibility issues" with versions of python, scipy, et al. Not your issue, I fixed it by fiddling my envs to get the right combo to work. sorry.

@aaronsnoswell
Copy link

Hello! I'm having the same error - can you elaborate on what version of Numpy / your env that you landed on to get this to work?

My error is below;

from string_grouper import (
    match_strings
)
---------------------------------------------------------------------------
ValueError                                Traceback (most recent call last)
Input In [3], in <cell line: 1>()
----> 1 from string_grouper import (
      2     match_strings
      3 )

File c:\development\string_grouper\string_grouper\__init__.py:1, in <module>
----> 1 from .string_grouper import compute_pairwise_similarities, group_similar_strings, match_most_similar, match_strings, \
      2     StringGrouperConfig, StringGrouper

File c:\development\string_grouper\string_grouper\string_grouper.py:12, in <module>
     10 from scipy.sparse.csgraph import connected_components
     11 from typing import Tuple, NamedTuple, List, Optional, Union
---> 12 from sparse_dot_topn_for_blocks import awesome_cossim_topn
     13 from topn import awesome_hstack_topn
     14 from functools import wraps

File ~\Miniconda3\envs\py38\lib\site-packages\sparse_dot_topn_for_blocks\__init__.py:5, in <module>
      2 import sys
      4 if sys.version_info[0] >= 3:
----> 5     from sparse_dot_topn_for_blocks.awesome_cossim_topn import awesome_cossim_topn
      6 else:
      7     from awesome_cossim_topn import awesome_cossim_topn

File ~\Miniconda3\envs\py38\lib\site-packages\sparse_dot_topn_for_blocks\awesome_cossim_topn.py:7, in <module>
      4 from scipy.sparse import isspmatrix_csr
      6 if sys.version_info[0] >= 3:
----> 7     from sparse_dot_topn_for_blocks import sparse_dot_topn as ct
      8     from sparse_dot_topn_for_blocks import sparse_dot_topn_threaded as ct_thread
      9 else:

File ~\Miniconda3\envs\py38\lib\site-packages\sparse_dot_topn_for_blocks\sparse_dot_topn.pyx:1, in init sparse_dot_topn_for_blocks.sparse_dot_topn()

ValueError: numpy.ndarray size changed, may indicate binary incompatibility. Expected 96 from C header, got 88 from PyObject

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

2 participants