diff --git a/doc.zih.tu-dresden.de/docs/software/python_virtual_environments.md b/doc.zih.tu-dresden.de/docs/software/python_virtual_environments.md index 71bec747c81853bc21cbe74fc12e1d12fe86cfa5..bfd9e0e0d22c0e867a932fb39a23aba7fb518769 100644 --- a/doc.zih.tu-dresden.de/docs/software/python_virtual_environments.md +++ b/doc.zih.tu-dresden.de/docs/software/python_virtual_environments.md @@ -50,11 +50,11 @@ Then create the virtual environment and activate it. ```console marie@compute$ ws_allocate python_virtual_environment 1 Info: creating workspace. -/horse/ws/marie-python_virtual_environment +/data/horse/ws/marie-python_virtual_environment [...] -marie@compute$ virtualenv --system-site-packages /horse/ws/marie-python_virtual_environment/env #Create virtual environment +marie@compute$ virtualenv --system-site-packages /data/horse/ws/marie-python_virtual_environment/env #Create virtual environment [...] -marie@compute$ source /horse/ws/marie-python_virtual_environment/env/bin/activate #Activate virtual environment. Example output: (env) bash-4.2$ +marie@compute$ source /data/horse/ws/marie-python_virtual_environment/env/bin/activate #Activate virtual environment. Example output: (env) bash-4.2$ ``` Now you can work in this isolated environment, without interfering with other @@ -73,7 +73,7 @@ the environment as follows: ```console marie@login.alpha$ srun --nodes=1 --gres=gpu:1 --time=01:00:00 --pty bash marie@alpha$ ws_allocate my_python_virtualenv 100 # use a workspace for the environment - marie@alpha$ cd /horse/ws/marie-my_python_virtualenv + marie@alpha$ cd /data/horse/ws/marie-my_python_virtualenv marie@alpha$ module load modenv/hiera GCC/10.2.0 CUDA/11.1.1 OpenMPI/4.0.5 PyTorch/1.9.0 Module GCC/10.2.0, CUDA/11.1.1, OpenMPI/4.0.5, PyTorch/1.9.0 and 54 dependencies loaded. marie@alpha$ which python @@ -113,9 +113,9 @@ packages from the file: ```console marie@compute$ module load Python #Load default Python [...] -marie@compute$ virtualenv --system-site-packages /horse/ws/marie-python_virtual_environment/env_post #Create virtual environment +marie@compute$ virtualenv --system-site-packages /data/horse/ws/marie-python_virtual_environment/env_post #Create virtual environment [...] -marie@compute$ source /horse/ws/marie-python_virtual_environment/env/bin/activate #Activate virtual environment. Example output: (env_post) bash-4.2$ +marie@compute$ source /data/horse/ws/marie-python_virtual_environment/env/bin/activate #Activate virtual environment. Example output: (env_post) bash-4.2$ (env_post) marie@compute$ pip install -r requirements.txt #Install packages from the created requirements.txt file ``` @@ -147,7 +147,7 @@ directory for the conda virtual environment: ```console marie@compute$ ws_allocate conda_virtual_environment 1 Info: creating workspace. -/horse/ws/marie-conda_virtual_environment +/data/horse/ws/marie-conda_virtual_environment [...] ``` @@ -156,8 +156,8 @@ environment: ```console marie@compute$ module load Anaconda3 #load Anaconda module -marie@compute$ conda create --prefix /horse/ws/marie-conda_virtual_environment/conda-env python=3.6 #create virtual environment with Python version 3.6 -marie@compute$ conda activate /horse/ws/marie-conda_virtual_environment/conda-env #activate conda-env virtual environment +marie@compute$ conda create --prefix /data/horse/ws/marie-conda_virtual_environment/conda-env python=3.6 #create virtual environment with Python version 3.6 +marie@compute$ conda activate /data/horse/ws/marie-conda_virtual_environment/conda-env #activate conda-env virtual environment ``` Now you can work in this isolated environment, without interfering with other @@ -185,7 +185,7 @@ can deactivate the conda environment as follows: ```console marie@login.alpha$ srun --nodes=1 --gres=gpu:1 --time=01:00:00 --pty bash marie@alpha$ ws_allocate my_conda_virtualenv 100 # use a workspace for the environment - marie@alpha$ cd /horse/ws/marie-my_conda_virtualenv + marie@alpha$ cd /data/horse/ws/marie-my_conda_virtualenv marie@alpha$ module load Anaconda3 Module Anaconda3/2021.11 loaded. marie@alpha$ conda create --prefix my-torch-env python=3.8 @@ -250,8 +250,8 @@ Recreate the conda virtual environment with the packages from the created `environment.yml` file: ```console -marie@compute$ mkdir /horse/ws/marie-conda_virtual_environment/conda-env #Create directory for environment +marie@compute$ mkdir /data/horse/ws/marie-conda_virtual_environment/conda-env #Create directory for environment marie@compute$ module load Anaconda3 #Load Anaconda marie@compute$ conda config --set channel_priority strict -marie@compute$ conda env create --prefix /horse/ws/marie-conda_virtual_environment/conda-env --file environment.yml #Create conda env in directory with packages from environment.yml file +marie@compute$ conda env create --prefix /data/horse/ws/marie-conda_virtual_environment/conda-env --file environment.yml #Create conda env in directory with packages from environment.yml file ```