how to specify new environment location for conda create

后端 未结 6 1316
爱一瞬间的悲伤
爱一瞬间的悲伤 2020-12-04 05:33

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 b

6条回答
  •  离开以前
    2020-12-04 06:19

    like Paul said, use

    conda create --prefix=/users/.../yourEnvName python=x.x
    

    if you are located in the folder in which you want to create your virtual environment, just omit the path and use

    conda create --prefix=yourEnvName python=x.x
    

    conda only keep track of the environments included in the folder envs inside the anaconda folder. The next time you will need to activate your new env, move to the folder where you created it and activate it with

    source activate yourEnvName
    

提交回复
热议问题