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

Sklearn package depreciated #130

Closed
mplemay opened this issue Dec 2, 2022 · 2 comments
Closed

Sklearn package depreciated #130

mplemay opened this issue Dec 2, 2022 · 2 comments

Comments

@mplemay
Copy link

mplemay commented Dec 2, 2022

When installing qdax, sklearn package raises an exception due to the depreciation of sklearn in favor of scikit-learn (see details on pypi).

(.venv) matthewlemay@Matthews-MacBook-Air ~/G/yuyu> python3 -m pip install -U --no-cache-dir qdax
Collecting qdax
  Downloading qdax-0.2.0-py3-none-any.whl (155 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 155.3/155.3 kB 16.1 MB/s eta 0:00:00
Requirement already satisfied: jax>=0.3.16 in ./.venv/lib/python3.10/site-packages (from qdax) (0.3.25)
Requirement already satisfied: numpy>=1.22.3 in ./.venv/lib/python3.10/site-packages (from qdax) (1.23.5)
Requirement already satisfied: scipy>=1.8.0 in ./.venv/lib/python3.10/site-packages (from qdax) (1.9.3)
Requirement already satisfied: jaxlib>=0.3.15 in ./.venv/lib/python3.10/site-packages (from qdax) (0.3.25)
Collecting gym>=0.23.1
  Downloading gym-0.26.2.tar.gz (721 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 721.7/721.7 kB 15.9 MB/s eta 0:00:00
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... done
Collecting scikit-learn>=1.0.2
  Downloading scikit_learn-1.1.3-cp310-cp310-macosx_10_9_x86_64.whl (8.7 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 8.7/8.7 MB 21.3 MB/s eta 0:00:00
Collecting brax>=0.0.15
  Downloading brax-0.0.15-py3-none-any.whl (372 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 372.3/372.3 kB 31.0 MB/s eta 0:00:00
Collecting flax<0.6.2,>=0.6
  Downloading flax-0.6.1-py3-none-any.whl (185 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 185.6/185.6 kB 126.9 MB/s eta 0:00:00
Collecting sklearn
  Downloading sklearn-0.0.post1.tar.gz (3.6 kB)
  Preparing metadata (setup.py) ... error
  error: subprocess-exited-with-error

  × python setup.py egg_info did not run successfully.
  │ exit code: 1
  ╰─> [18 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

      If the previous advice does not cover your use case, feel free to report it at
      https://github.com/scikit-learn/sklearn-pypi-package/issues/new
      [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.
@felixchalumeau
Copy link
Collaborator

Hi @mplemay

Thank you very much for your issue and for the related PR. I'll have a look at it just now.

@felixchalumeau
Copy link
Collaborator

Thanks @mplemay for spotting this issue.
This has been fixed in #132.

Main branch is updated and @Lookatator is going to update the latest pypi version.

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