使用'conda install'代替'pip install'来安装setup.py软件包 [英] Use 'conda install' instead of 'pip install' for setup.py packages
问题描述
我想在项目中使用setup.py安装fastai.如果我有一个conda环境,最好的方法是使用conda安装命令 conda install -c pytorch -c fastai fastai
.不幸的是,如果我仅添加fastai作为要求,则可以使用pip来安装它,而我遇到了一些问题.
I want to install fastai using setup.py in a project. The nicest way, if I have a conda environment, is to use the conda install command conda install -c pytorch -c fastai fastai
. Unfortunately, if I just add fastai as a requirement, it gets installed using pip, which I have experienced issues with.
简而言之,有没有一种方法可以使用conda的setup.py文件(使用 conda install
命令)来安装fastai?
Simply, is there a way to install fastai using conda a setup.py file (using the conda install
command)?
推荐答案
据我所知, conda
程序包管理器不了解 setup.py
.结果,无法使用 conda
从 setup.py
安装软件包.
As far as I know, conda
package manager does not understand setup.py
. As a result, one cannot install packages from setup.py
with conda
.
但是,我们可以使用conda和 .yml
文件安装库.通常,它用于在计算机之间复制 conda环境
.有关创建环境文件和
However, we can install libraries using conda with a .yml
file. Typically, this is used to copy a conda environment
across machines. More information about creating environment file and using it.
这篇关于使用'conda install'代替'pip install'来安装setup.py软件包的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!