Local Execution¶
This guide gets you running the pipeline locally in 10 minutes. No Google Cloud account is needed. For cloud deployment, see Cloud Deployment.
Prerequisites¶
Docker¶
The pipeline runs inside Docker containers. You need a Docker-compatible runtime installed and running.
We recommend OrbStack for a lightweight, fast Docker engine on macOS.
OrbStack ยท Fast, light, simple Docker & LinuxInstall via Homebrew or download the installer:
After installation, open OrbStack once to complete setup. It runs the Docker engine in the background.
Note
Docker Desktop also works if you have already installed it. However, note that the performance may not be as good as OrbStack.
Install Docker Engine following the official guide for your distribution.
Windows requires WSL2 with a Linux distribution. All commands in this guide should be run inside WSL2.
Install WSLInstall Windows Subsystem for Linux with the command, wsl --install. Use a Bash terminal on your Windows machine run by your preferred Linux distribution - Ubuntu, Debian, SUSE, Kali, Fedora, Pengwin, Alpine, and more are available.-
Install WSL2 and Ubuntu (from PowerShell as Administrator):
-
Install Docker Engine inside WSL2 following the Linux instructions, or install Docker Desktop for Windows with WSL2 backend enabled.
Verify Docker is running:
uv¶
We use uv for package management. It handles Python version resolution automatically.
Disk Space¶
Ensure at least 10 GB free for Docker images and build cache.
Step 1: Install epycloud¶
Follow the Installation Guide to install the epycloud CLI tool, then verify:
Step 2: Configure epycloud¶
Initialize the configuration directory:
This creates ~/.config/epymodelingsuite-cloud/ with default configuration files, a flu profile, and sets it as the active profile. The profile resolves the {profile} placeholder used in storage paths (e.g., pipeline/dev/flu/). See Configuration Guide for details.
Skip Cloud Configuration
You don't need to set project_id, bucket_name, or other Google Cloud settings for local runs. The defaults are sufficient.
Step 3: Build Docker image¶
Build the development image locally:
This builds the Docker image without pushing to any registry. First build takes 5-10 minutes due to downloading dependencies.
Step 4: Prepare test experiment¶
For local runs, we save experiment configurations in ./local/forecast/:
Option A: Copy from experiment repository (if you have access):
$ cp -r ~/Developer/my-flu-experiment-repo/experiments/test-sim ./local/forecast/experiments/
$ cp -r ~/Developer/my-flu-experiment-repo/common-data ./local/forecast/ 2>/dev/null || true
Option B: Create a minimal test configuration:
Create ./local/forecast/experiments/test-sim/config/basemodel_config.yaml with a simple configuration (see Configuration Guide for examples).
Step 5: Run workflow¶
Run the complete pipeline locally:
This executes all three stages:
- Stage A (Builder): Generates input configurations
- Stage B (Runner): Processes simulations in parallel
- Stage C (Output): Aggregates results and generates CSV outputs
Results are saved to ./local/bucket/pipeline/flu/test-sim/{RUN_ID}/
Local Execution Mode
The --local flag is required for local runs. Without it, epycloud will attempt to submit a cloud workflow.
Step 6: View results¶
Check the output directory:
View generated outputs:
Output files include: - *.csv.gz - Compressed CSV files with simulation results - Quantiles, trajectories, metadata, etc.
Common Local Commands¶
# Configuration
$ epycloud config show # View current configuration
$ epycloud config edit # Edit base configuration
# Building
$ epycloud build dev # Build local image
# Running individual stages
$ epycloud run job --local --stage builder --exp-id test-sim
$ epycloud run job --local --stage runner --exp-id test-sim --run-id <RUN_ID> --task-index 0
$ epycloud run job --local --stage output --exp-id test-sim --run-id <RUN_ID> --num-tasks 2
# View logs
$ docker compose logs builder
$ docker compose logs runner
$ docker compose logs output
Next Steps¶
-
Deploy infrastructure and run workflows on Google Cloud
-
Learn about profiles, environments, and advanced configuration
-
Common issues and solutions for local development
Troubleshooting¶
Configuration not found¶
If you see "Configuration file not found" errors:
Docker image build fails¶
Issue: Docker not running
- Solution: Start your Docker engine (OrbStack, Docker Desktop, etc.)
Issue: Insufficient disk space
- Solution: Clean up Docker:
docker system prune -a
Local run fails¶
Issue: Experiment config not found
- Solution: Verify
./local/forecast/experiments/{EXP_ID}/config/exists
Issue: Docker image doesn't exist
- Solution: Build the image first:
epycloud build dev
Issue: Docker Compose not found
- Solution: Install Docker Compose:
docker compose version
For more troubleshooting, see Troubleshooting Guide.