TL;DR
Prompt in, picture out, nothing leaves the laptop.
generate.py
$ python generate.py \
"a lone astronaut standing
on the edge of a massive
crater on Mars, Earth visible
in the pink sky, cinematic
lighting, hyper detailed" \
--steps 50 --guidance 9
Using MPS (Apple Silicon)
Generating (50 steps)...
✓ Saved to output/
The prompt

The output
- What it is
- A Python script that runs Stable Diffusion on the MacBook. Pass a prompt, wait about 30 seconds, get an image.
- Local
- No cloud API, no subscription. The M3's GPU does the work through Metal Performance Shaders, in about 4GB of memory.
- Why
- A guinea pig for this site's
/add-workand/log-workcommands. About a tenth of the time went on the CLI, the rest on the work tracker. - Stack
- Python, PyTorch and Hugging Face Diffusers.
Started August 2025.