Setup via uv¶
uv (by Astral) is a modern, Rust‑powered replacement for both pip and
virtualenv.
- Up to 10 × faster installs & upgrades (parallel resolver + global cache)
- One tool for creating environments and installing packages
- Drop‑in syntax – just say
uv pip …where you would normally usepip
If you have never used a Python package manager before, uv combines the jobs of Conda and pip. See the official uv documentation for all options.
1. Install uv (one‑time)¶
Install via pipx (recommended):
pipx install uv
If pipx is not available, install directly with pip:
python -m pip install --upgrade uv
2. Create an environment & install Particula¶
In the folder or git repo you want to work in create a new virtual environment called .venv:
uv venv .venv
Activate it on Linux / macOS:
source .venv/bin/activate
Activate it on Windows (CMD or PowerShell):
.\.venv\Scripts\activate
Install Particula into the active environment:
uv pip install particula
Need the tutorial extras (plots, progress‑bars, etc.)? Install them with:
uv pip install "particula[extra]"
3. Upgrade / Uninstall¶
Upgrade Particula:
uv pip install -U particula
Uninstall Particula:
uv pip uninstall particula
Use a specific Python version¶
If you want to use a specific Python version, you can specify it with the --python flag:
uv venv .venv --python=python3.12
4. Install Editable with Contributing¶
If you want to contribute to Particula, see the Contributor Setup section for details on setting up a development environment and workflow.
Once in your forked repo, create the same .venv as above, then you can install Particula in editable mode with the required dev dependencies:
uv pip install -e ".[dev,extra]"