Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
habrok:software_environment:python [2026/04/07 12:52] pedrohabrok:software_environment:python [2026/04/07 16:10] (current) – [Quick links] pedro
Line 6: Line 6:
 ===== What is different about Python on the cluster? ===== ===== What is different about Python on the cluster? =====
  
-On your own laptop, you might install Python packages directly with ''pip install'' or ''conda install'' , but on the cluster things work a little differently:+On your own laptop, you might install Python packages directly with ''pip install'' or ''mamba install'' , but on the cluster things work a little differently:
    
   * Python is provided through the **[[habrok:software_environment:module_system|module system]]**, which gives you access to several different versions of Python as well as a number of pre-built, performance-optimised libraries. You should always start by loading a Python module rather than relying on any system Python.   * Python is provided through the **[[habrok:software_environment:module_system|module system]]**, which gives you access to several different versions of Python as well as a number of pre-built, performance-optimised libraries. You should always start by loading a Python module rather than relying on any system Python.
Line 20: Line 20:
 How to find and load Python versions on Hábrók using the module system. Also covers the pre-installed optimised libraries (numpy, scipy, TensorFlow, PyTorch, etc.) and how to check what is already available before installing anything yourself. How to find and load Python versions on Hábrók using the module system. Also covers the pre-installed optimised libraries (numpy, scipy, TensorFlow, PyTorch, etc.) and how to check what is already available before installing anything yourself.
    
-**[[habrok_internal:drafts:python:environments|Python Environments]]**\\+**[[.:python:environments]]**\\
 On the cluster you work in isolated Python environments. This subsection covers the three main tools for creating and managing these environments: On the cluster you work in isolated Python environments. This subsection covers the three main tools for creating and managing these environments:
    
-  * **[[habroks:software_environment:python:environments#pip_venv|pip + venv]]** — The standard Python approach. Built into Python itself, no extra installation needed. Recommended for most users who just need to install a set of Python packages. +  * **[[.:python:environments#pip_venv|pip + venv]]** — The standard Python approach. Built into Python itself, no extra installation needed. Recommended for most users who just need to install a set of Python packages. 
-  * **[[habroks:software_environment:python:uv|uv]]** — A modern, fast alternative to pip + venv that also handles project management. +  * **[[.:python:uv|uv]]** — A modern, fast alternative to pip + venv that also handles project management. 
-  * **[[habroks:software_environment:python:mamba|Mamba]]** — separate environment and package manager that can also manage non-Python dependencies. While installation instructions are available, we generally discourage its use on Hábrók and recommend using pip + venv or uv instead.+  * **[[.:python:mamba|Mamba]]** — An alternative to Anaconda, which itself is a separate environment and package manager that can also manage non-Python dependencies. While installation instructions are available, we generally discourage its use on Hábrók and recommend using pip + venv or uv instead.
      
    
-**[[habroks:software_environment:python:running_jobs|Running Python Jobs]]**\\+**[[.:python:running_jobs]]**\\
 How to write job scripts that use your Python environment on the cluster. Covers single-CPU jobs, multi-CPU jobs using multiprocessing, GPU jobs, and multi-node MPI jobs. How to write job scripts that use your Python environment on the cluster. Covers single-CPU jobs, multi-CPU jobs using multiprocessing, GPU jobs, and multi-node MPI jobs.
    
 +**[[habrok:examples:vscode_python|Python in VSCode]]**\\
 +How to use Python modules in VScode.
 +
 **[[habrok:examples:jupyter|Jupyter Notebooks]]**\\ **[[habrok:examples:jupyter|Jupyter Notebooks]]**\\
 How to run Jupyter notebooks on Hábrók, either through the web portal or via an SSH tunnel to a compute node running a batch job. How to run Jupyter notebooks on Hábrók, either through the web portal or via an SSH tunnel to a compute node running a batch job.
Line 36: Line 39:
 **[[habrok:examples:spyder|Spyder]]**\\ **[[habrok:examples:spyder|Spyder]]**\\
 How to install and run Spyder, a graphical Python IDE for scientific work, using a remote desktop session on the web portal. How to install and run Spyder, a graphical Python IDE for scientific work, using a remote desktop session on the web portal.
-  
-**[[habrok:examples:vscode_python|Python in VSCode]]**\\ 
-How to use Python modules in VScode. 
  
 ===== Python FAQs ===== ===== Python FAQs =====