diff --git a/source/cloud/gcp/vertex-ai.md b/source/cloud/gcp/vertex-ai.md index c29ce9a9..4382905a 100644 --- a/source/cloud/gcp/vertex-ai.md +++ b/source/cloud/gcp/vertex-ai.md @@ -33,6 +33,13 @@ You can find out your current system CUDA Toolkit version by running `ls -ld /us You can create a new RAPIDS conda environment and register it with `ipykernel` for use in Jupyter Lab. Open a new terminal in Jupyter and run the following commands. +```bash +# Use a user-writable location for environments and package caches +$ export MAMBA_ROOT_PREFIX="${HOME}/micromamba" +``` + +Setting `MAMBA_ROOT_PREFIX` keeps environments and package caches in a user-writable location. + ```bash # Create a new environment $ conda create -y -n rapids \ @@ -48,9 +55,11 @@ $ conda activate rapids ```bash # Register the environment with Jupyter -$ python -m ipykernel install --prefix "${DL_ANACONDA_HOME}/envs/rapids" --name rapids --display-name rapids +$ python -m ipykernel install --user --name rapids --display-name "rapids" ``` +Registering the kernel with `--user` installs the kernelspec in the Jupyter user's kernel directory, avoiding permissions errors from writing into the environment prefix. + Then refresh the Jupyter Lab page and open the launcher. You will see a new "rapids" kernel available. ![Screenshot of the Jupyter Lab launcher showing the RAPIDS kernel](../../images/vertex-ai-launcher.png)