Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Python

A easy/flexible way for using python is via Miniforge (a light weight version of conda-forge). This enables users to have a full fledged python environment under their own control. Here is the example of how to setup Miniforge inside user’s home directory.

Code Block
$ wget "https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-$(uname)-$(uname -m).sh"
$ bash Miniforge3-$(uname)-$(uname -m).sh

# During the installation, ***do NOT init***, as we will do it properly later.
You can undo this by running `conda init --reverse $SHELL`? [yes|no]
[no] >>> no

# To use the conda command, you need to add the ~/miniforge3/condabin directory to 
# the PATH environment variable. Some old guides use "conda init" but it seems to point
# conda not mamba. To setup mamba properly:
$ ~/miniforge3/condabin/mamba init

# Prevent auto activate the base env. True this is confusing, you need to use conda
# here.
$ conda config --set auto_activate_base false
Note

The use of Miniforge/Conda may consume lots of disk space (for installed packages and downloaded cache). Please watch out for your home directory space quota.

Managed Miniforge

A centrally managed Miniforge is also provided, its path is:

Code Block
/share/apps/z_install_tree/linux-generic/miniforge3/

It aims to centrally provide some of the popular/common environments, ready to be used by everyone straightaway, avoids duplications and wasting users' disk space.

Code Block
$ /share/apps/z_install_tree/linux-generic/miniforge3/bin/mamba env list
# conda environments:
#

base                     /share/apps/z_install_tree/linux-generic/miniforge3
pytorch_cu118            /share/apps/z_install_tree/linux-generic/miniforge3/envs/pytorch_cu118
pytorch_cu121            /share/apps/z_install_tree/linux-generic/miniforge3/envs/pytorch_cu121
Info

Please contact us if you want to share your environment, we can add it to the managed Miniforge. Its repository can be found here: miniforge3_env.git