[Diffusion] Bump up cache-dit & support quant for diffusers backend#20361
[Diffusion] Bump up cache-dit & support quant for diffusers backend#20361mickqian merged 9 commits intosgl-project:mainfrom
Conversation
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request focuses on significantly improving the performance of the diffusers backend by integrating advanced optimization techniques. It updates the Highlights
🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console. Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request bumps up the cache-dit version and adds support for quantization for the diffusers backend, resulting in a reported speedup. The changes primarily involve updating the pyproject.toml file and modifying the cache_dit.md documentation to include examples of quantization configurations. I have added a review comment to address a potential issue.
Note: Security Review has been skipped due to the limited scope of the PR.
|
/tag-and-rerun-ci |
|
/tag-and-rerun-ci |
|
diffusion affected only, lint passed, bypassign |
Bump up cache-dit & support quant for diffusers backend (~48% speedup for FLUX.1-dev on L20). Need #20338 ready.
Cache-DiT v1.3.0 is a major release after v.1.2.0, the major changes incude:
enable_cacheAPI and load from config yamlThe major changes related to SGLang Diffusion are that Cache-DiT v1.3.0 has improved its configs loading functions, enabling support for nearly all optimizations configured in the YAML file. These optimizations include:
Please refer to LOAD_CONFIGS for more details. This allows all optimizations in cache-dit to be used in SGLang Diffusion, greatly optimizing diffusers backend inference performance.
Benchmarking and Profiling
NVIDIA L20 x 1, FLUX.1-dev, 28 steps, 1024 x 1024
NVIDIA H200 x 1, FLUX.1-dev, 28 steps, 1024 x 1024
pip install -U torchao # >= 0.16.0https://github.com/vipshop/cache-dit/tree/main/examples/configs
Warmed-up request processed in
20.46secondsWarmed-up request processed in
13.81secondsFor NVIDIA H200 (Hopper): 3.73s -> 2.77s
Checklist
Review Process
/tag-run-ci-label,/rerun-failed-ci,/tag-and-rerun-cicc @mickqian @RubiaCx