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

cannot use environment.yaml to install conda env #11

Open
yetiiil opened this issue Mar 20, 2024 · 2 comments
Open

cannot use environment.yaml to install conda env #11

yetiiil opened this issue Mar 20, 2024 · 2 comments

Comments

@yetiiil
Copy link

yetiiil commented Mar 20, 2024

Hello, I got the following message when installing conda with environment.yaml:

Pip subprocess error:
ERROR: Ignored the following versions that require a different python version: 1.6.2 Requires-Python >=3.7,<3.10; 1.6.3 Requires-Python >=3.7,<3.10; 1.7.0 Requires-Python >=3.7,<3.10; 1.7.1 Requires-Python >=3.7,<3.10
ERROR: Could not find a version that satisfies the requirement torch==1.13.1+cu116 (from versions: 1.11.0, 1.12.0, 1.12.1, 1.13.0, 1.13.1, 2.0.0, 2.0.1, 2.1.0, 2.1.1, 2.1.2, 2.2.0, 2.2.1)
ERROR: No matching distribution found for torch==1.13.1+cu116

failed

CondaEnvException: Pip failed

@PeterSchlenker
Copy link

Try adding --extra-index-url https://download.pytorch.org/whl/cu116 to your environment.yml file like this:

...
  - zstandard=0.19.0=py310h5eee18b_0
  - pip:
    - --extra-index-url https://download.pytorch.org/whl/cu116
    - absl-py==1.2.0
...

You can run conda env update --file environment.yml to re-download the dependencies in a conda environment you've already created.

I had the exact same issue, and this seemed to fix it for me. I'm basing what I did off of these two webpages:

@KunHan-KH
Copy link

Try adding --extra-index-url https://download.pytorch.org/whl/cu116 to your environment.yml file like this:

...
  - zstandard=0.19.0=py310h5eee18b_0
  - pip:
    - --extra-index-url https://download.pytorch.org/whl/cu116
    - absl-py==1.2.0
...

You can run conda env update --file environment.yml to re-download the dependencies in a conda environment you've already created.

I had the exact same issue, and this seemed to fix it for me. I'm basing what I did off of these two webpages:

Thanks Peter for you solution of solving the conda environment. Did you run the command pip install -r requirements.txt and do we need to run it? Thanks.

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

3 participants