Implementing Stable Diffusion in Rust+Torch
sample image of a rusty robot holding a torch
As an example of how to use tch crate, I've put together an implementation of Stable Diffusion in Rust. It mostly follows the lines of huggingface's Python diffusers library and can reuse the original Python weights to generate images from Rust :) Details on GitHub with more rusty robots! Comments/questions are very welcome :)