This guide will walk you through installing uv (the fast Python package installer and resolver) and creating a Python virtual environment for Evolution Gym and related packages.
Open PowerShell and run:
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"curl -LsSf https://astral.sh/uv/install.sh | shAfter installation, restart your terminal or reload your shell configuration to ensure the uv command is available.
uv initThis initializes uv in your current directory.
uv venv --python=python3.10This creates a virtual environment using Python 3.10.
Run the following commands to install all necessary packages:
uv add evogym
uv add ipykernel -U --force-reinstall
uv add torch
uv add matplotlib
uv add --upgrade setuptools
uv add tqdm
uv add imageio- evogym: Evolution Gym framework
- ipykernel: Kernel for Jupyter notebooks
- torch: PyTorch machine learning library
- matplotlib: Data visualization library
- setuptools: Package development tools
- tqdm: Progress bar utility
- imageio: Library for reading and writing image data
.venv\Scripts\activatesource .venv/bin/activateAfter activation, you can start using the installed packages in your Python scripts or Jupyter notebooks.
For any issues with the environment setup, check the uv documentation or package-specific resources.