If you wish to share an environment across a project’s users, you can append a -prefix env_path to the create and install commands to install packages into a central location you and others in your lab can use. Please see conda documentation for a very good description of managing environments and installing packages.Ĭonda commands are further described here. To deactivate the environment, type: source deactivateįinally, to delete the environment, type: conda remove -n myenv -all To use the activated environment, type: python The package installs into the currently activated environment, but you can also specify an explicit environment name. We’ll specify a specific version, although this can be omitted to get the latest one. Now, let’s add the SciPy package from the Anaconda repository to our environment. To activate the environment and use it, type: source activate myenv Now let’s create a local environment called “myenv”. To see all created environments, type: conda env list To see all available python packages on Kamiak, type: conda list -n root module load anaconda3 # or miniconda3įrom that point forward, you can load packages and manage environments using “conda” commands. To start using Anaconda, simply load its module. We recommend using Python from within Anaconda or Miniconda, rather than running Python standalone. Otherwise, by default you will use the system-wide “root” environment, which does not allow you to modify or install packages. It is recommended to always use environments, which are local to your home directory in. Environments are a useful way to put together a set of packages with specific versions and dependencies. Switching between environments is called activating the environment. With Conda, you can create and use environments that have different versions of Python and packages installed in them. Anaconda provides many bundled packages in addition to Python and Conda. Miniconda provides just Python and Conda.
0 Comments
Leave a Reply. |