hdbscan
hdbscan copied to clipboard
ERROR: Failure: ValueError (numpy.ndarray size changed, may indicate binary incompatibility. Expected 88 from C header, got 80 from PyObject)
Running nose tests. This is the trace back
Traceback (most recent call last):
File "/home/kosimadukwe/PycharmProjects/untitled1/venv7/lib/python3.7/site-packages/nose/failure.py", line 39, in runTest
raise self.exc_val.with_traceback(self.tb)
File "/home/kosimadukwe/PycharmProjects/untitled1/venv7/lib/python3.7/site-packages/nose/loader.py", line 407, in loadTestsFromName
module = resolve_name(addr.module)
File "/home/kosimadukwe/PycharmProjects/untitled1/venv7/lib/python3.7/site-packages/nose/util.py", line 312, in resolve_name
module = __import__('.'.join(parts_copy))
File "/home/kosimadukwe/PycharmProjects/untitled1/venv7/lib/python3.7/site-packages/hdbscan/__init__.py", line 1, in <module>
from .hdbscan_ import HDBSCAN, hdbscan
File "/home/kosimadukwe/PycharmProjects/untitled1/venv7/lib/python3.7/site-packages/hdbscan/hdbscan_.py", line 21, in <module>
from ._hdbscan_linkage import (single_linkage,mst_linkage_core,
File "hdbscan/_hdbscan_linkage.pyx", line 1, in init hdbscan._hdbscan_linkage
ValueError: numpy.ndarray size changed, may indicate binary incompatibility. Expected 88 from C header, got 80 from PyObject
----------------------------------------------------------------------
Ran 1 test in 0.001s
FAILED (errors=1)
i have Python 3.7 numpy 1.19.x scikit-learn 0.24.x pandas 1.2.x scipy 1.6.0 networkx 2.5.0 matplotlib 3.3.0 hbdscan 0.8
the main aim is to use openensembles 2.0.0 which requires hbdscan and these specified libraries/version above. i installed via pip in a virtual environment
UPdate: I added
import cython
import pyximport
pyximport.install()
and got the error :
ImportError: Building module hdbscan._hdbscan_linkage failed: ["distutils.errors.CompileError: command 'gcc' failed with exit status 1\n"]
I had the same problem, just needed to update numpy to 1.20.x and it's solved.
I had the same problem, just needed to update numpy to 1.20.x and it's solved.
i tried that but since im using openensembles library, i got this
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
openensembles 2.0.0 requires numpy==1.19.*, but you have numpy 1.20.0 which is incompatible.
UPDATE: Even though openensmebles says it requires numpy 1.19.x, when i ignored that continued with the installation of 1.20.0, it worked.
Seems to be a duplicate of https://github.com/scikit-learn-contrib/hdbscan/issues/457 - which is fixed in master, but not yet released on PyPI