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

hgboost library uses a deprecated version of scikit-learn #36

Closed
prasannakrish97 opened this issue Feb 18, 2024 · 1 comment
Closed

Comments

@prasannakrish97
Copy link

I am currently trying to "pip install hgboost" in my conda environment python version 3.11.8.
However, I've noticed that whatever the version of the library hgboost, it uses the deprecated version of scikit-learn : sklearn (For extra details, please check details below) :

"""
Collecting hgboost
Using cached hgboost-1.1.5-py3-none-any.whl.metadata (10 kB)
Collecting datazets (from hgboost)
Using cached datazets-0.1.9-py3-none-any.whl.metadata (4.7 kB)
Collecting pypickle (from hgboost)
Using cached pypickle-1.1.0-py3-none-any.whl (5.1 kB)
Collecting matplotlib (from hgboost)
Using cached matplotlib-3.8.3-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (5.8 kB)
Requirement already satisfied: numpy in /home/raj/anaconda3/envs/mots-interdits-311/lib/python3.11/site-packages (from hgboost) (1.26.4)
Requirement already satisfied: pandas in /home/raj/anaconda3/envs/mots-interdits-311/lib/python3.11/site-packages (from hgboost) (2.2.0)
Requirement already satisfied: tqdm in /home/raj/anaconda3/envs/mots-interdits-311/lib/python3.11/site-packages (from hgboost) (4.66.2)
Collecting hyperopt (from hgboost)
Using cached hyperopt-0.2.7-py2.py3-none-any.whl (1.6 MB)
Requirement already satisfied: lightgbm>=4.1.0 in /home/raj/anaconda3/envs/mots-interdits-311/lib/python3.11/site-packages (from hgboost) (4.3.0)
Collecting catboost (from hgboost)
Using cached catboost-1.2.2-cp311-cp311-manylinux2014_x86_64.whl.metadata (1.2 kB)
Collecting xgboost (from hgboost)
Using cached xgboost-2.0.3-py3-none-manylinux2014_x86_64.whl.metadata (2.0 kB)
Collecting classeval (from hgboost)
Using cached classeval-0.2.2-py3-none-any.whl.metadata (5.4 kB)
Collecting treeplot (from hgboost)
Using cached treeplot-0.1.16-py3-none-any.whl (8.7 kB)
Collecting df2onehot (from hgboost)
Using cached df2onehot-1.0.6-py3-none-any.whl.metadata (3.3 kB)
Collecting colourmap (from hgboost)
Using cached colourmap-1.1.16-py3-none-any.whl.metadata (4.1 kB)
Collecting seaborn (from hgboost)
Using cached seaborn-0.13.2-py3-none-any.whl.metadata (5.4 kB)
Requirement already satisfied: scipy in /home/raj/anaconda3/envs/mots-interdits-311/lib/python3.11/site-packages (from lightgbm>=4.1.0->hgboost) (1.12.0)
Collecting graphviz (from catboost->hgboost)
Using cached graphviz-0.20.1-py3-none-any.whl (47 kB)
Collecting plotly (from catboost->hgboost)
Using cached plotly-5.19.0-py3-none-any.whl.metadata (7.0 kB)
Requirement already satisfied: six in /home/raj/anaconda3/envs/mots-interdits-311/lib/python3.11/site-packages (from catboost->hgboost) (1.16.0)
Requirement already satisfied: python-dateutil>=2.8.2 in /home/raj/anaconda3/envs/mots-interdits-311/lib/python3.11/site-packages (from pandas->hgboost) (2.8.2)
Requirement already satisfied: pytz>=2020.1 in /home/raj/anaconda3/envs/mots-interdits-311/lib/python3.11/site-packages (from pandas->hgboost) (2024.1)
Requirement already satisfied: tzdata>=2022.7 in /home/raj/anaconda3/envs/mots-interdits-311/lib/python3.11/site-packages (from pandas->hgboost) (2024.1)
Collecting funcsigs (from classeval->hgboost)
Using cached funcsigs-1.0.2-py2.py3-none-any.whl (17 kB)
Requirement already satisfied: scikit-learn in /home/raj/anaconda3/envs/mots-interdits-311/lib/python3.11/site-packages (from classeval->hgboost) (1.4.0)
Requirement already satisfied: requests in /home/raj/anaconda3/envs/mots-interdits-311/lib/python3.11/site-packages (from datazets->hgboost) (2.31.0)
Collecting networkx>=2.2 (from hyperopt->hgboost)
Using cached networkx-3.2.1-py3-none-any.whl.metadata (5.2 kB)
Collecting future (from hyperopt->hgboost)
Using cached future-0.18.3.tar.gz (840 kB)
Preparing metadata (setup.py) ... done
Collecting cloudpickle (from hyperopt->hgboost)
Using cached cloudpickle-3.0.0-py3-none-any.whl.metadata (7.0 kB)
Collecting py4j (from hyperopt->hgboost)
Using cached py4j-0.10.9.7-py2.py3-none-any.whl (200 kB)
Collecting contourpy>=1.0.1 (from matplotlib->hgboost)
Using cached contourpy-1.2.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (5.8 kB)
Collecting cycler>=0.10 (from matplotlib->hgboost)
Using cached cycler-0.12.1-py3-none-any.whl.metadata (3.8 kB)
Collecting fonttools>=4.22.0 (from matplotlib->hgboost)
Using cached fonttools-4.49.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (159 kB)
Collecting kiwisolver>=1.3.1 (from matplotlib->hgboost)
Using cached kiwisolver-1.4.5-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (6.4 kB)
Requirement already satisfied: packaging>=20.0 in /home/raj/anaconda3/envs/mots-interdits-311/lib/python3.11/site-packages (from matplotlib->hgboost) (23.2)
Requirement already satisfied: pillow>=8 in /home/raj/anaconda3/envs/mots-interdits-311/lib/python3.11/site-packages (from matplotlib->hgboost) (10.2.0)
Collecting pyparsing>=2.3.1 (from matplotlib->hgboost)
Using cached pyparsing-3.1.1-py3-none-any.whl.metadata (5.1 kB)
Collecting sklearn (from treeplot->hgboost)
Using cached sklearn-0.0.post12.tar.gz (2.6 kB)
Preparing metadata (setup.py) ... error
error: subprocess-exited-with-error

× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> [15 lines of output]
The 'sklearn' PyPI package is deprecated, use 'scikit-learn'
rather than 'sklearn' for pip commands.

  Here is how to fix this error in the main use cases:
  - use 'pip install scikit-learn' rather than 'pip install sklearn'
  - replace 'sklearn' by 'scikit-learn' in your pip requirements files
    (requirements.txt, setup.py, setup.cfg, Pipfile, etc ...)
  - if the 'sklearn' package is used by one of your dependencies,
    it would be great if you take some time to track which package uses
    'sklearn' instead of 'scikit-learn' and report it to their issue tracker
  - as a last resort, set the environment variable
    SKLEARN_ALLOW_DEPRECATED_SKLEARN_PACKAGE_INSTALL=True to avoid this error
  
  More information is available at
  https://github.com/scikit-learn/sklearn-pypi-package
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
"""

@adrinjalali
Copy link
Member

You need to report this to hgboost, not here.

@adrinjalali adrinjalali closed this as not planned Won't fix, can't repro, duplicate, stale Feb 19, 2024
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