Real-Time-Latent-Consistency-Model  by radames

App for real-time diffusion model pipelines using Diffusers

created 1 year ago
908 stars

Top 40.9% on sourcepulse

GitHubView on GitHub
Project Summary

This project provides a real-time demonstration of Latent Consistency Models (LCM) for image generation and manipulation, targeting users interested in live diffusion model applications. It enables rapid image-to-image and text-to-image generation with features like ControlNet and LoRA integration, offering a fast and interactive experience.

How It Works

The application leverages the Diffusers library to implement various LCM pipelines, including SD Turbo and ControlNet integrations. It utilizes a MJPEG stream server for real-time webcam input and displays generated images. The core advantage lies in LCM's ability to achieve high-quality results with significantly fewer inference steps (as low as 4), enabling near real-time performance.

Quick Start & Requirements

  • Install: uv venv --python=3.10, activate, uv pip install -r server/requirements.txt, cd frontend && npm install && npm run build && cd .., then python server/main.py --reload --pipeline img2imgSDTurbo.
  • Prerequisites: CUDA, Python 3.10, Node.js > 19, webcam. Mac with M1/M2/M3 or Intel Arc GPU is also supported.
  • Docker: docker build -t lcm-live . and docker run -ti -p 7860:7860 --gpus all lcm-live.
  • Docs: Hugging Face Spaces

Highlighted Details

  • Showcases multiple real-time diffusion model pipelines.
  • Supports LCM Image-to-Image, Text-to-Image, ControlNet (Canny), and LoRA integrations.
  • Offers pipelines for SDXL and SD Turbo for faster inference.
  • Includes options for Torch Compile, Tiny Autoencoder, and Stable Fast.

Maintenance & Community

The project is maintained by radames. Links to demos and related models are provided on the Hugging Face Hub.

Licensing & Compatibility

The repository does not explicitly state a license in the README. Compatibility for commercial use or closed-source linking is not specified.

Limitations & Caveats

The project is presented as a demo and may not be production-ready. Specific performance claims are not benchmarked. The README does not detail error handling or scalability for high-load scenarios.

Health Check
Last commit

3 months ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
0
Star History
16 stars in the last 90 days

Explore Similar Projects

Starred by Andrej Karpathy Andrej Karpathy(Founder of Eureka Labs; Formerly at Tesla, OpenAI; Author of CS 231n), Georgios Konstantopoulos Georgios Konstantopoulos(CTO, General Partner at Paradigm), and
2 more.

mflux by filipstrand

0.7%
2k
MLX port of FLUX for local image generation on Macs
created 11 months ago
updated 16 hours ago
Feedback? Help us improve.