[Doc] Add Z-Image Base support and fix Z-Image Turbo parameters#1229
[Doc] Add Z-Image Base support and fix Z-Image Turbo parameters#1229dougbtv wants to merge 1 commit intovllm-project:mainfrom
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 631ac72d14
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| OmniDiffusionSamplingParams( | ||
| height=1280, | ||
| width=720, | ||
| num_inference_steps=50, | ||
| guidance_scale=4.0, | ||
| negative_prompt="blurry, low quality, distorted, oversaturated", | ||
| seed=42, |
There was a problem hiding this comment.
Pass negative_prompt via prompt dict, not sampling params
This example passes negative_prompt into OmniDiffusionSamplingParams, but that dataclass does not define a negative_prompt field, so constructing it will raise TypeError: __init__() got an unexpected keyword argument 'negative_prompt' at runtime. The rest of the repo (e.g., text_to_image.py) passes negative_prompt in the prompt dict instead, which is what the pipelines read. As written, the base example in this script won’t run unless negative_prompt is moved into the prompt input.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
great, refactored it to correctly match being packed in a prompt dict.
255db64 to
ceb6da0
Compare
Add documentation and examples for Z-Image Base model alongside existing Z-Image Turbo support. Changes: - Add z_image_examples.py with Base vs Turbo comparison examples - Update quickstart.md with comments distinguishing Base and Turbo - Update supported_models.md to list both Z-Image variants - Update text_to_image README with usage examples and comparison table - Fix negative_prompt to be passed in prompt dict (not sampling params) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> Signed-off-by: dougbtv <dosmith@redhat.com>
|
add test result for speed&acc compared with diffusers |
congw729
left a comment
There was a problem hiding this comment.
Hi, if you edit a markdown document under ./examples/*, please also run mkdocs serve to sync those editions to ./docs/ before merging this PR.
|
|
||
| if __name__ == "__main__": | ||
| # Use Z-Image-Turbo for fast inference (8 steps) | ||
| # or Z-Image (Base) for higher quality (28-50 steps with CFG support) |
There was a problem hiding this comment.
I don't think we need to modify this file.
| --output outputs/coffee_turbo.png | ||
| ``` | ||
|
|
||
| ### Z-Image Base (High Quality with CFG) |
There was a problem hiding this comment.
If we add examples for every model, then it will blow up
tl;dr: I tried loading up and generating images with z-image base (released last week), but wound up looking at the docs to see if it matched.
Added some docs (assist by claude code)
Let me know if there's anything we want or don't want from it.
Thanks!
Added documentation for Z-Image Base model (Tongyi-MAI/Z-Image) alongside the existing Z-Image Turbo variant. The existing ZImagePipeline already supports both models - this change updates docs to reflect that.
Key changes:
Z-Image Base vs Turbo:
Tested Z-Image Base generation: 1280x720, 50 steps, CFG=4.0, negative prompts working.
PLEASE FILL IN THE PR DESCRIPTION HERE ENSURING ALL CHECKLIST ITEMS (AT THE BOTTOM) HAVE BEEN CONSIDERED.