Open Source
Explore the latest AI open-source projects from GitHub and HuggingFace.
Explore the latest AI open-source projects from GitHub and HuggingFace.
stable-diffusion.cpp is a pure C/C++ inference engine for diffusion models, built on the ggml library and following the same design approach as llama.cpp: super lightweight, with no external dependencies. It targets a wide and fast-growing range of image, image-editing, and video diffusion models rather than a single architecture, including SD1.x/SD2.x/SD-Turbo, SDXL/SDXL-Turbo, SD3/SD3.5, FLUX.1-dev/schnell, FLUX.2-dev/klein, Chroma and Chroma1-Radiance, Qwen Image and Qwen Image 2.1 (added as Day-0 support on 2026-09-20), LongCat Image, Z-Image, MiniT2I, SenseNova U1.5, Ovis-Image, ERNIE-Image, Krea2, HiDream-O1-Image, Ideogram4, LLaDA-Image, PixArt, and Lens; image-editing variants such as FLUX.1-Kontext-dev and the Qwen Image Edit series; and video models Wan2.1/Wan2.2 and Wan2.1 Vace, MiniMax-H3 (Day-1 support added 2026-08-04), LTX-2.3/2.5, HunyuanVideo 1.5, and LingBot-Video. It runs on CPU (with AVX/AVX2/AVX512 on x86), CUDA, Vulkan, Metal, OpenCL, and SYCL backends, loads Pytorch checkpoints, Safetensors, or GGUF weights, and includes a convert mode to write GGUF or Safetensors output. Other features include PhotoMaker, IP-Adapter for SD1.5 and SDXL (including Plus), ControlNet for SD1.5, ADetailer, LoRA support, LCM/LCM-LoRA sampling, TAESD for faster and more memory-efficient latent decoding, ESRGAN upscaling, flash attention for reduced memory use, VAE tiling to cut encode/decode memory, two selectable RNG modes for cross-platform reproducibility (--rng cuda, the default, matching stable-diffusion-webui's GPU RNG, and --rng cpu, matching ComfyUI's RNG), and PNG metadata embedding compatible with webui-style text strings. It runs on Linux, macOS, Windows, and Android (via Termux or the Local Diffusion app), and third-party bindings (Go, C#, Python, Rust, Flutter/Dart) and UIs such as LocalAI, KoboldCpp, sd.cpp-webui, and Jellybox use it as their backend. Development is very active: the repository publishes automated master-build releases multiple times a day alongside tagged versions, and the README warns the API and CLI options may change frequently. Licensed under the MIT License.