-
Notifications
You must be signed in to change notification settings - Fork 123
Instalation Fails python3.8 #210
Comments
What are you trying to do here? Install the forked version of scikit-learn that's used for py-earth? Or are you trying to install py-earth itself? |
Same error here. I tried both:
I'd like to install py-earth but it fails whatever the method chosen to install it. Config. Python 3.8.6, GCC 10.2.0, sklearn 0.24.2 |
@shidingan Looks to be a cython issue. Ensure you have a version of cython installed that is compatible with Python 3.8 |
Should not be a problem of Cython version IMO because it is the version provided by my distrib with python3: cython 0.29.21 which is compatible with python3.8... |
If you believe all your dependencies are correct, you can try installing from from the issue 191 branch:
Alternatively, you can specify to build in-place:
|
I have this issue too. Here is a minimal reproducibile example: $ : conda create -n test-pyearth python=3.8.10 -y
$ : conda activate test-pyearth
$ : pip install sklearn-contrib-py-earth |
I also have this problem. Python 3.7, 3.8 and 3.9. Similar error message
|
I solved installing the |
Can you give the actual procedure. I do not see a dev branch. |
pip install sklearn-contrib-py-earth will not work on > python 3.6. Either use the solution outlined above or the solution outlined in the comments section of the article referenced above that uses the pip install method. |
Indeed, it works when cloning the repo and installing manually. What's the issue with |
I used the instructions in the last comment in here https://stackoverflow.com/questions/66503039/how-to-install-pyearth-in-google-colab pip install git+https://github.com/scikit-learn-contrib/[email protected] |
Would it be possible to make a release on PyPI? Currently a plain |
Thank you! it works. |
pip install sklearn-contrib-py-earth
Collecting sklearn-contrib-py-earth
Using cached sklearn-contrib-py-earth-0.1.0.tar.gz (1.0 MB)
Requirement already satisfied: scipy>=0.16 in /home/tnt/PycharmProjects/mars/lib/python3.8/site-packages (from sklearn-contrib-py-earth) (1.6.0)
Requirement already satisfied: scikit-learn>=0.16 in /home/tnt/PycharmProjects/mars/lib/python3.8/site-packages (from sklearn-contrib-py-earth) (0.24.1)
Requirement already satisfied: six in /home/tnt/PycharmProjects/mars/lib/python3.8/site-packages (from sklearn-contrib-py-earth) (1.15.0)
Requirement already satisfied: numpy>=1.13.3 in /home/tnt/PycharmProjects/mars/lib/python3.8/site-packages (from scikit-learn>=0.16->sklearn-contrib-py-earth) (1.20.1)
Requirement already satisfied: threadpoolctl>=2.0.0 in /home/tnt/PycharmProjects/mars/lib/python3.8/site-packages (from scikit-learn>=0.16->sklearn-contrib-py-earth) (2.1.0)
Requirement already satisfied: joblib>=0.11 in /home/tnt/PycharmProjects/mars/lib/python3.8/site-packages (from scikit-learn>=0.16->sklearn-contrib-py-earth) (1.0.1)
Using legacy 'setup.py install' for sklearn-contrib-py-earth, since package 'wheel' is not installed.
Installing collected packages: sklearn-contrib-py-earth
Running setup.py install for sklearn-contrib-py-earth ... error
ERROR: Command errored out with exit status 1:
command: /home/tnt/PycharmProjects/mars/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-tpbrbmff/sklearn-contrib-py-earth_55157342455949e0ab32713d54e2384c/setup.py'"'"'; file='"'"'/tmp/pip-install-tpbrbmff/sklearn-contrib-py-earth_55157342455949e0ab32713d54e2384c/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /tmp/pip-record-1nkxfk0o/install-record.txt --single-version-externally-managed --compile --install-headers /home/tnt/PycharmProjects/mars/include/site/python3.8/sklearn-contrib-py-earth
cwd: /tmp/pip-install-tpbrbmff/sklearn-contrib-py-earth_55157342455949e0ab32713d54e2384c/
Complete output (142 lines):
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.8
creating build/lib.linux-x86_64-3.8/pyearth
copying pyearth/earth.py -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/export.py -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_version.py -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/init.py -> build/lib.linux-x86_64-3.8/pyearth
creating build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/test_forward.py -> build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/test_util.py -> build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/test_qr.py -> build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/test_export.py -> build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/test_knot_search.py -> build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/testing_utils.py -> build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/test_pruning.py -> build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/test_earth.py -> build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/init.py -> build/lib.linux-x86_64-3.8/pyearth/test
creating build/lib.linux-x86_64-3.8/pyearth/test/record
copying pyearth/test/record/test_forward_pass.py -> build/lib.linux-x86_64-3.8/pyearth/test/record
copying pyearth/test/record/test_pruning_pass.py -> build/lib.linux-x86_64-3.8/pyearth/test/record
copying pyearth/test/record/init.py -> build/lib.linux-x86_64-3.8/pyearth/test/record
creating build/lib.linux-x86_64-3.8/pyearth/test/basis
copying pyearth/test/basis/test_missingness.py -> build/lib.linux-x86_64-3.8/pyearth/test/basis
copying pyearth/test/basis/test_hinge.py -> build/lib.linux-x86_64-3.8/pyearth/test/basis
copying pyearth/test/basis/base.py -> build/lib.linux-x86_64-3.8/pyearth/test/basis
copying pyearth/test/basis/test_smoothed_hinge.py -> build/lib.linux-x86_64-3.8/pyearth/test/basis
copying pyearth/test/basis/test_basis.py -> build/lib.linux-x86_64-3.8/pyearth/test/basis
copying pyearth/test/basis/test_linear.py -> build/lib.linux-x86_64-3.8/pyearth/test/basis
copying pyearth/test/basis/test_constant.py -> build/lib.linux-x86_64-3.8/pyearth/test/basis
copying pyearth/test/basis/init.py -> build/lib.linux-x86_64-3.8/pyearth/test/basis
running egg_info
writing sklearn_contrib_py_earth.egg-info/PKG-INFO
writing dependency_links to sklearn_contrib_py_earth.egg-info/dependency_links.txt
writing requirements to sklearn_contrib_py_earth.egg-info/requires.txt
writing top-level names to sklearn_contrib_py_earth.egg-info/top_level.txt
reading manifest file 'sklearn_contrib_py_earth.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching 'pyearth/test/pathological_data'
writing manifest file 'sklearn_contrib_py_earth.egg-info/SOURCES.txt'
copying pyearth/_basis.c -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_basis.pxd -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_forward.c -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_forward.pxd -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_knot_search.c -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_knot_search.pxd -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_pruning.c -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_pruning.pxd -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_qr.c -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_qr.pxd -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_record.c -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_record.pxd -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_types.c -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_types.pxd -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_util.c -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/_util.pxd -> build/lib.linux-x86_64-3.8/pyearth
copying pyearth/test/earth_linvars_regress.txt -> build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/earth_regress.txt -> build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/earth_regress_missing_data.txt -> build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/earth_regress_smooth.txt -> build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/forward_regress.txt -> build/lib.linux-x86_64-3.8/pyearth/test
copying pyearth/test/test_data.csv -> build/lib.linux-x86_64-3.8/pyearth/test
UPDATING build/lib.linux-x86_64-3.8/pyearth/_version.py
set build/lib.linux-x86_64-3.8/pyearth/_version.py to '0.1.0'
running build_ext
building 'pyearth._util' extension
creating build/temp.linux-x86_64-3.8
creating build/temp.linux-x86_64-3.8/pyearth
x86_64-linux-gnu-gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/home/tnt/PycharmProjects/mars/lib/python3.8/site-packages/numpy/core/include -I/home/tnt/PycharmProjects/mars/include -I/usr/include/python3.8 -c pyearth/_util.c -o build/temp.linux-x86_64-3.8/pyearth/_util.o
In file included from /home/tnt/PycharmProjects/mars/lib/python3.8/site-packages/numpy/core/include/numpy/ndarraytypes.h:1944,
from /home/tnt/PycharmProjects/mars/lib/python3.8/site-packages/numpy/core/include/numpy/ndarrayobject.h:12,
from /home/tnt/PycharmProjects/mars/lib/python3.8/site-packages/numpy/core/include/numpy/arrayobject.h:4,
from pyearth/_util.c:495:
/home/tnt/PycharmProjects/mars/lib/python3.8/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: #warning "Using deprecated NumPy API, disable it with " "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]
17 | #warning "Using deprecated NumPy API, disable it with "
| ^~~~~~~
pyearth/_util.c: In function ‘__Pyx__ExceptionSave’:
pyearth/_util.c:8071:21: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_type’; did you mean ‘curexc_type’?
8071 | *type = tstate->exc_type;
| ^~~~~~~~
| curexc_type
pyearth/_util.c:8072:22: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_value’; did you mean ‘curexc_value’?
8072 | *value = tstate->exc_value;
| ^~~~~~~~~
| curexc_value
pyearth/_util.c:8073:19: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_traceback’; did you mean ‘curexc_traceback’?
8073 | *tb = tstate->exc_traceback;
| ^~~~~~~~~~~~~
| curexc_traceback
pyearth/_util.c: In function ‘__Pyx__ExceptionReset’:
pyearth/_util.c:8080:24: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_type’; did you mean ‘curexc_type’?
8080 | tmp_type = tstate->exc_type;
| ^~~~~~~~
| curexc_type
pyearth/_util.c:8081:25: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_value’; did you mean ‘curexc_value’?
8081 | tmp_value = tstate->exc_value;
| ^~~~~~~~~
| curexc_value
pyearth/_util.c:8082:22: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_traceback’; did you mean ‘curexc_traceback’?
8082 | tmp_tb = tstate->exc_traceback;
| ^~~~~~~~~~~~~
| curexc_traceback
pyearth/_util.c:8083:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_type’; did you mean ‘curexc_type’?
8083 | tstate->exc_type = type;
| ^~~~~~~~
| curexc_type
pyearth/_util.c:8084:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_value’; did you mean ‘curexc_value’?
8084 | tstate->exc_value = value;
| ^~~~~~~~~
| curexc_value
pyearth/_util.c:8085:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_traceback’; did you mean ‘curexc_traceback’?
8085 | tstate->exc_traceback = tb;
| ^~~~~~~~~~~~~
| curexc_traceback
pyearth/_util.c: In function ‘__Pyx__GetException’:
pyearth/_util.c:8140:24: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_type’; did you mean ‘curexc_type’?
8140 | tmp_type = tstate->exc_type;
| ^~~~~~~~
| curexc_type
pyearth/_util.c:8141:25: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_value’; did you mean ‘curexc_value’?
8141 | tmp_value = tstate->exc_value;
| ^~~~~~~~~
| curexc_value
pyearth/_util.c:8142:22: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_traceback’; did you mean ‘curexc_traceback’?
8142 | tmp_tb = tstate->exc_traceback;
| ^~~~~~~~~~~~~
| curexc_traceback
pyearth/_util.c:8143:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_type’; did you mean ‘curexc_type’?
8143 | tstate->exc_type = local_type;
| ^~~~~~~~
| curexc_type
pyearth/_util.c:8144:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_value’; did you mean ‘curexc_value’?
8144 | tstate->exc_value = local_value;
| ^~~~~~~~~
| curexc_value
pyearth/_util.c:8145:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_traceback’; did you mean ‘curexc_traceback’?
8145 | tstate->exc_traceback = local_tb;
| ^~~~~~~~~~~~~
| curexc_traceback
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------
ERROR: Command errored out with exit status 1: /home/tnt/PycharmProjects/mars/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-tpbrbmff/sklearn-contrib-py-earth_55157342455949e0ab32713d54e2384c/setup.py'"'"'; file='"'"'/tmp/pip-install-tpbrbmff/sklearn-contrib-py-earth_55157342455949e0ab32713d54e2384c/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /tmp/pip-record-1nkxfk0o/install-record.txt --single-version-externally-managed --compile --install-headers /home/tnt/PycharmProjects/mars/include/site/python3.8/sklearn-contrib-py-earth Check the logs for full command output.
The text was updated successfully, but these errors were encountered: