From f2011aabe0bda540b35004af66055b795424c2ea Mon Sep 17 00:00:00 2001 From: James Kingsley <jkingsley@wpi.edu> Date: Wed, 23 Oct 2024 14:05:43 +0000 Subject: [PATCH] Update python.md --- docs/software/python.md | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/docs/software/python.md b/docs/software/python.md index 63f3223..10597cc 100644 --- a/docs/software/python.md +++ b/docs/software/python.md @@ -1,12 +1,12 @@ # Python -## Using Python virtual environments with venv or conda +## Using Python virtual environments with venv For Python specifically, you can set up a virtual environment, which acts similarly to a personal module but for using Python packages. In these virtual environments, you can install whichever Python packages you want using pip, and the result exists as a directory that you can load into sessions. See the -following example for how you can create the virtual environment myenv: +following example for how you can create the virtual environment `myenv` (you may use any name): ```bash $ module load python # (1)! @@ -21,6 +21,9 @@ $ pip install <my-python-package> Once the virtual environment is created, you can now run the source command to load it into a new session and use your Python packages such as NumPy or SciPy. + ## Using Python virtual environments with conda + + A similar process can be used with miniconda to create and activate a conda environment ```bash $ module load miniconda3 -- GitLab