问题描述
软件包的默认位置是我的主目录中的.conda文件夹.但是,在我使用的服务器上,我可以使用多少空间有非常严格的限制,这基本上避免了我将任何内容放置在主目录下的情况.如何为要创建的虚拟环境指定位置?谢谢!服务器正在运行Ubuntu.
the default location for packages is .conda folder in my home directory. however, on the server I am using, there is a very strict limit of how much space I can use, which basically avoids me from putting anything under my home directory. how can I specify the location for the virtual environment that I want to create? Thanks! server is running Ubuntu.
推荐答案
使用--prefix
或-p
选项指定将环境文件写入何处.例如:
Use the --prefix
or -p
option to specify where to write the environment files. For example:
conda create --prefix /tmp/test-env python=2.7
将创建一个名为/tmp/test-env
的环境,该环境位于/tmp/
中,而不是默认的.conda
中.
Will create the environment named /tmp/test-env
which resides in /tmp/
instead of the default .conda
.
这篇关于如何为conda创建指定新的环境位置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!