我正在尝试创建一个conda env
conda create --name sf-prj-final --file requirements.txt
但是我遇到了错误提示:
PackagesNotFoundError: The following packages are not available from current channels:
- grpcio==1.31.0=pypi_0
- idna==2.10=pypi_0
- google-auth==1.20.1=pypi_0
- requests-oauthlib==1.3.0=pypi_0
- pyasn1==0.4.8=pypi_0
- oauthlib==3.1.0=pypi_0
- pyasn1-modules==0.2.8=pypi_0
- tensorboard-plugin-wit==1.7.0=pypi_0
- pypng==0.0.18=pypi_0
- correlation-cuda==0.0.0=pypi_0
- werkzeug==1.0.1=pypi_0
- tensorboard==2.3.0=pypi_0
- torchvision==0.4.0=py37_cu100
- importlib-metadata==1.7.0=pypi_0
- zipp==3.1.0=pypi_0
- absl-py==0.9.0=pypi_0
- urllib3==1.25.10=pypi_0
- cachetools==4.1.1=pypi_0
- google-auth-oauthlib==0.4.1=pypi_0
- forward-warp-cuda==0.0.0=pypi_0
- chardet==3.0.4=pypi_0
- markdown==3.2.2=pypi_0
- rsa==4.6=pypi_0
- requests==2.24.0=pypi_0
- pytorch==1.2.0=py3.7_cuda10.0.130_cudnn7.6.2_0
- protobuf==3.12.4=pypi_0
Current channels:
- https://repo.anaconda.com/pkgs/main/linux-64
- https://repo.anaconda.com/pkgs/main/noarch
- https://repo.anaconda.com/pkgs/free/linux-64
- https://repo.anaconda.com/pkgs/free/noarch
- https://repo.anaconda.com/pkgs/r/linux-64
- https://repo.anaconda.com/pkgs/r/noarch
- https://repo.anaconda.com/pkgs/pro/linux-64
- https://repo.anaconda.com/pkgs/pro/noarch
- https://conda.anaconda.org/conda-forge/linux-64
- https://conda.anaconda.org/conda-forge/noarch
我了解问题所在。我必须从pip安装这些软件包,但是在创建conda环境时是否有任何conda解决方案来安装所有软件包?
谢谢。
答案 0 :(得分:0)
我假设您正在尝试将 txt 文件中的软件包安装到已创建的环境中 - 这就是您收到此错误的原因。错误消息中列出的文件是环境中存在的包(运行 conda list
,您可以看到它们已经存在)。
所以...您有两种可能的解决方案:
conda activate mypyenv
) 并删除错误消息 (conda remove somepackage
) 中列出的这些包。他们再次尝试应用这些要求。conda create --name mynewpythonenv --file requirements.txt