Comments (5)
Hi Karl, my solution is to download the source code from this repo and run python setup.py install
to build the package from scratch. Hope it works for you too :)
from deep-forest.
I also met another error:
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/numpy/init.py", line 320, in getattr
raise AttributeError("module {!r} has no attribute "
AttributeError: module 'numpy' has no attribute 'bool'
from deep-forest.
Hi, I've just encountered exactly the same error after pip install deep-forest
in a python=3.8 environment. I was able to fix the np.int
error manually but the np.bool
error seems to be hard to fix from user side.
I have also tried the following:
- downgrade numpy to 1.19 (<1.20), but the following error would occur:
ValueError: numpy.ndarray size changed, may indicate binary incompatibility. Expected 88 from C header, got 80 from PyObject
- build from scratch with
python setup.py install
, but the following error would occur:
Error compiling Cython file:
------------------------------------------------------------
...
if not is_samples_sorted[0]:
n_samples = end - start
memcpy(sorted_samples + start, samples + start,
n_samples * sizeof(SIZE_t))
qsort(sorted_samples + start, n_samples, sizeof(SIZE_t),
compare_SIZE_t)
^
------------------------------------------------------------
deepforest/tree/_splitter.pyx:1040:14: Cannot assign type 'int (const void *, const void *) except? -1 nogil' to 'int (*)(const void *, const void *) noexcept nogil'. Exception values are incompatible. Suggest adding 'noexcept' to type 'int (const void *, const void *) except? -1 nogil'.
Is there any way to solve this since this issue has been recently closed as completed? Thanks in advance!
from deep-forest.
Solved by reinstalling cpython==0.29.14
and building from scratch.
from deep-forest.
Hi, I've just encountered exactly the same error after
pip install deep-forest
in a python=3.8 environment. I was able to fix thenp.int
error manually but thenp.bool
error seems to be hard to fix from user side. I have also tried the following:
- downgrade numpy to 1.19 (<1.20), but the following error would occur:
ValueError: numpy.ndarray size changed, may indicate binary incompatibility. Expected 88 from C header, got 80 from PyObject
- build from scratch with
python setup.py install
, but the following error would occur:Error compiling Cython file: ------------------------------------------------------------ ... if not is_samples_sorted[0]: n_samples = end - start memcpy(sorted_samples + start, samples + start, n_samples * sizeof(SIZE_t)) qsort(sorted_samples + start, n_samples, sizeof(SIZE_t), compare_SIZE_t) ^ ------------------------------------------------------------ deepforest/tree/_splitter.pyx:1040:14: Cannot assign type 'int (const void *, const void *) except? -1 nogil' to 'int (*)(const void *, const void *) noexcept nogil'. Exception values are incompatible. Suggest adding 'noexcept' to type 'int (const void *, const void *) except? -1 nogil'.
Is there any way to solve this since this issue has been recently closed as completed? Thanks in advance!
could you please share your solution to the np.int error ? I'm getting the same issue:
AttributeError: module 'numpy' has no attribute 'int'.
`np.int` was a deprecated alias for the builtin `int`. To avoid this error in existing code, use `int` by itself. Doing this will not modify any behavior and is safe. When replacing `np.int`, you may wish to use e.g. `np.int64` or `np.int32` to specify the precision. If you wish to review your current use, check the release note link for additional information.
The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
from deep-forest.
Related Issues (20)
- cant import CascadeForestRegressor HOT 2
- pip install deep-forest didn't work in wsl2 HOT 8
- pip install deep-forest didn't work in python3.10 HOT 3
- question HOT 8
- Please consider support on py310 HOT 1
- pip install deep-forest ERROR: Could not find a version that satisfies the requirement deep-forest (from versions: none) HOT 2
- np.int has been removed in munpy 1.24 HOT 5
- pip install doesn't work HOT 4
- What is the `model.get_later_feature_importance(0)` for? HOT 7
- Cannot find deep-forest in PyPI HOT 2
- Request for permission to cite your figure in the DF document HOT 3
- Unable to import CascadeForestClassifier HOT 7
- 导入出现错误 HOT 1
- Installation issues on Macbook Pro 2022 (Apple Silicon) and Ubuntu HOT 12
- The method to resolve the "import _cutils" issue. HOT 1
- 安装了deep-forest 但是出现 报错 HOT 3
- Is the numpy version of the dependency specified? HOT 1
- cannot import name 'CascadeForestClassifier' from 'deepforest'
- Use `pip install deep-forest` will encounter an ERROR! HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from deep-forest.