scikit-learn-contrib / scikit-learn-extra

scikit-learn contrib estimators
https://scikit-learn-extra.readthedocs.io
BSD 3-Clause "New" or "Revised" License
190 stars 43 forks source link

ERROR: Failed building wheel for scikit-learn-extra #164

Open 0x2b375 opened 1 year ago

0x2b375 commented 1 year ago

this is the error i get when I try to download package

Using cached scikit-learn-extra-0.2.0.tar.gz (813 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done Requirement already satisfied: numpy>=1.13.3 in c:\users\acer nitro 5\appdata\local\programs\python\python310\lib\site-packages (from scikit-learn-extra) (1.24.2) Requirement already satisfied: scipy>=0.19.1 in c:\users\acer nitro 5\appdata\local\programs\python\python310\lib\site-packages (from scikit-learn-extra) (1.10.1) Requirement already satisfied: scikit-learn>=0.23.0 in c:\users\acer nitro 5\appdata\local\programs\python\python310\lib\site-packages (from scikit-learn-extra) (1.2.2) Requirement already satisfied: joblib>=1.1.1 in c:\users\acer nitro 5\appdata\local\programs\python\python310\lib\site-packages (from scikit-learn>=0.23.0->scikit-learn-extra) (1.2.0) Requirement already satisfied: threadpoolctl>=2.0.0 in c:\users\acer nitro 5\appdata\local\programs\python\python310\lib\site-packages (from scikit-learn>=0.23.0->scikit-learn-extra) (3.1.0) Building wheels for collected packages: scikit-learn-extra Building wheel for scikit-learn-extra (pyproject.toml) ... error error: subprocess-exited-with-error

× Building wheel for scikit-learn-extra (pyproject.toml) did not run successfully. │ exit code: 1 ╰─> [49 lines of output] C:\Users\Acer Nitro 5\AppData\Local\Temp\pip-build-env-ig6kewu7\overlay\Lib\site-packages\setuptools\dist.py:788: UserWarning: Usage of dash-separated 'description-file' will not be supported in future versions. Please use the underscore name 'description_file' instead warnings.warn( running bdist_wheel running build running build_py creating build creating build\lib.win-amd64-cpython-310 creating build\lib.win-amd64-cpython-310\benchmarks copying benchmarks\bench_rbfsampler_fastfood.py -> build\lib.win-amd64-cpython-310\benchmarks copying benchmarks__init.py -> build\lib.win-amd64-cpython-310\benchmarks creating build\lib.win-amd64-cpython-310\sklearn_extra copying sklearn_extra_version.py -> build\lib.win-amd64-cpython-310\sklearn_extra copying sklearn_extra__init.py -> build\lib.win-amd64-cpython-310\sklearn_extra creating build\lib.win-amd64-cpython-310\benchmarks_bench copying benchmarks_bench\eigenpro_plot_mnist.py -> build\lib.win-amd64-cpython-310\benchmarks_bench copying benchmarks_bench\eigenpro_plot_noisy_mnist.py -> build\lib.win-amd64-cpython-310\benchmarks_bench copying benchmarks_bench\eigenpro_plot_synthetic.py -> build\lib.win-amd64-cpython-310\benchmarks_bench copying benchmarks_bench\robust_plot_synthetic.py -> build\lib.win-amd64-cpython-310\benchmarks_bench copying benchmarks_bench__init.py -> build\lib.win-amd64-cpython-310\benchmarks_bench creating build\lib.win-amd64-cpython-310\sklearn_extra\cluster copying sklearn_extra\cluster_commonnn.py -> build\lib.win-amd64-cpython-310\sklearn_extra\cluster copying sklearn_extra\cluster_k_medoids.py -> build\lib.win-amd64-cpython-310\sklearn_extra\cluster copying sklearn_extra\cluster__init.py -> build\lib.win-amd64-cpython-310\sklearn_extra\cluster creating build\lib.win-amd64-cpython-310\sklearn_extra\kernel_approximation copying sklearn_extra\kernel_approximation\test_fastfood.py -> build\lib.win-amd64-cpython-310\sklearn_extra\kernel_approximation copying sklearn_extra\kernel_approximation_fastfood.py -> build\lib.win-amd64-cpython-310\sklearn_extra\kernel_approximation copying sklearn_extra\kernel_approximation__init__.py -> build\lib.win-amd64-cpython-310\sklearn_extra\kernel_approximation creating build\lib.win-amd64-cpython-310\sklearn_extra\kernel_methods copying sklearn_extra\kernel_methods_eigenpro.py -> build\lib.win-amd64-cpython-310\sklearn_extra\kernel_methods copying sklearn_extra\kernel_methods\init__.py -> build\lib.win-amd64-cpython-310\sklearn_extra\kernel_methods creating build\lib.win-amd64-cpython-310\sklearn_extra\robust copying sklearn_extra\robust\mean_estimators.py -> build\lib.win-amd64-cpython-310\sklearn_extra\robust copying sklearn_extra\robust\robust_weighted_estimator.py -> build\lib.win-amd64-cpython-310\sklearn_extra\robust copying sklearn_extra\robust\init.py -> build\lib.win-amd64-cpython-310\sklearn_extra\robust creating build\lib.win-amd64-cpython-310\sklearn_extra\tests copying sklearn_extra\tests\test_common.py -> build\lib.win-amd64-cpython-310\sklearn_extra\tests copying sklearn_extra\tests\init.py -> build\lib.win-amd64-cpython-310\sklearn_extra\tests creating build\lib.win-amd64-cpython-310\sklearn_extra\cluster\tests copying sklearn_extra\cluster\tests\test_commonnn.py -> build\lib.win-amd64-cpython-310\sklearn_extra\cluster\tests copying sklearn_extra\cluster\tests\test_k_medoids.py -> build\lib.win-amd64-cpython-310\sklearn_extra\cluster\tests copying sklearn_extra\cluster\tests\init__.py -> build\lib.win-amd64-cpython-310\sklearn_extra\cluster\tests creating build\lib.win-amd64-cpython-310\sklearn_extra\kernel_approximation\tests copying sklearn_extra\kernel_approximation\tests\init__.py -> build\lib.win-amd64-cpython-310\sklearn_extra\kernel_approximation\tests creating build\lib.win-amd64-cpython-310\sklearn_extra\kernel_methods\tests copying sklearn_extra\kernel_methods\tests\test_eigenpro.py -> build\lib.win-amd64-cpython-310\sklearn_extra\kernel_methods\tests copying sklearn_extra\kernel_methods\tests\init__.py -> build\lib.win-amd64-cpython-310\sklearn_extra\kernel_methods\tests running build_ext building 'sklearn_extra.utils._cyfht' extension error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/ [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip. ERROR: Failed building wheel for scikit-learn-extra Failed to build scikit-learn-extra ERROR: Could not build wheels for scikit-learn-extra, which is required to install pyproject.toml-based projects


adrinjalali commented 1 year ago

This is probably because we haven't released in a long while and the binaries for python3.10 and 3.11 don't exist. @rth @TimotheeMathieu what's the release process here?

TimotheeMathieu commented 1 year ago

Yes sorry, the release was almost done (the binaries are artifacts of PR #156 ). I was busy at work and forgot the last step of uploading to pypi. I will do the upload now.

TimotheeMathieu commented 1 year ago

I did the upload. We have binaries for python 3.6 to python 3.9. Not yet for python 3.10.

@0xb39 could you retry pip install scikit-learn-extra now to see if it works ?

adrinjalali commented 1 year ago

The OP's environment is py=3.10, so it would still fail. We should add 3.10 and 3.11 here, any blockers for that?

TimotheeMathieu commented 1 year ago

I will try to build it.

rth commented 1 year ago

Thanks for managing it @TimotheeMathieu !

TimotheeMathieu commented 1 year ago

After some work (cibuildwheel is not easy to debug) I managed to have python 3.10 and 3.11 for 64bit. I uploaded them on pypi. This should be sufficient for now and I have no idea how to solve the problem for 32bits. 32bits work with the old version of the CI and hence I also uploaded 32bits binaries for 3.6 to 3.9. See details in PR #156 .

Now, could you can try to install @0xb39 ?

0x2b375 commented 1 year ago

o7

adrinjalali commented 1 year ago

@TimotheeMathieu it would be nice to streamline that and have maybe a github action which would upload to testpypi or pypi automatically, for all versions.

keyanxiaoma commented 7 months ago

用python3.6构建轮子好像不行

IsaacUtah1379 commented 3 months ago

I just ran into this error. I'm using python 3.12, so that might be why.

Tangme10 commented 2 months ago

i ran into the same error, how to solve this

TimotheeMathieu commented 2 months ago

For now you can try the method I suggest in issue #177, it is not ideal but at least on my computer it installs for python 3.12

MarkcoHK commented 2 weeks ago

Hi, I have followed above methods or even created new env of python 3.12 but it didn't work for me , with the ERROR: Failed to build installable wheels for some pyproject.toml based projects (scikit-learn-extra), i have no cue how to solve...

aaaimee000 commented 1 week ago

Hi, I have followed above methods or even created new env of python 3.12 but it didn't work for me , with the ERROR: Failed to build installable wheels for some pyproject.toml based projects (scikit-learn-extra), i have no cue how to solve...

Same here, and I am on windows.

TimotheeMathieu commented 1 week ago

Hi @aaaimee000, could you try the methods suggested in #177 ? In particular, try to download the wheel from the artifact in the action (https://github.com/scikit-learn-contrib/scikit-learn-extra/actions/runs/11686011469) and install directly from the wheel to see if it solves the problem.

MarkcoHK commented 1 week ago

I am using M-chips macbook and use create new env. with x64.

CONDA_SUBDIR=osx-64 conda create -n (ENV. NAME) python conda activate (ENV. NAME) conda config --env --set subdir osx-64

It works for me, hope that help