Modular library of pretrained diffusion pipelines, schedulers, and models for inference and training. Load Hub checkpoints in a few lines of Python.
Overview
Diffusers is a Hugging Face library for working with pretrained diffusion models that generate images, video, audio, and related outputs in PyTorch. It targets both quick inference and custom training setups with an emphasis on modularity over heavy abstraction.
DiffusionPipeline wraps end-to-end generation tasks such as text-to-image, image-to-image, inpainting, upscaling, and video-oriented pipelines using checkpoints from the Hub. You can swap noise schedulers to trade speed and quality, and combine pretrained model blocks into your own systems.
Modular Diffusers adds composable pipeline components for builders who need more control than a single pipeline class. Documentation covers loading, optimization, training, and a CLI path to run packaged pipelines.
The project documents Apple Silicon guidance for running Stable Diffusion locally, and lists popular task-to-pipeline mappings tied to public Hub models.
Key features
- Pretrained diffusion pipelines
- Interchangeable noise schedulers
- Hub checkpoint loading
- Modular pipeline building blocks
- Training and fine-tuning guides
- Memory and speed optimizations
- Text, image, and video tasks
- Command-line pipeline runs
Use cases
- Text-to-image generation
- Image editing and inpainting
- Custom diffusion system design
- Fine-tuning diffusion adapters
- Research and prototyping in PyTorch