Add from_single_file support for HunyuanImage and Ideogram4 transformers#13942
Open
HaozheZhang6 wants to merge 2 commits into
Open
Add from_single_file support for HunyuanImage and Ideogram4 transformers#13942HaozheZhang6 wants to merge 2 commits into
HaozheZhang6 wants to merge 2 commits into
Conversation
Adds a single_file conversion so community HunyuanImage-2.1 GGUF checkpoints load directly. Closely based on convert_hunyuan_video_transformer_to_diffusers (shared DiT lineage), with HunyuanImage deltas: time_in -> time_guidance_embed, single-block hidden size 3584, and the ByT5 glyph encoder byt5_in -> context_embedder_2. Verified: exact key/shape match vs hunyuanvideo-community/HunyuanImage-2.1-Diffusers (1264->1264, 0 missing/unexpected), and a real from_single_file load of the 6.5GB Q2_K. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
from_single_file / GGUF support for HunyuanImageTransformer2DModel
6 tasks
Contributor
|
Hi @HaozheZhang6, thanks for the PR! It does not appear to link an issue it fixes. If this PR addresses an existing issue, please add a closing keyword (e.g. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds
from_single_filesupport for two transformers that were missing it:HunyuanImageTransformer2DModel(incl. GGUF) andIdeogram4Transformer2DModel. Each registers the model insingle_file_model.pyand adds a checkpoint converter insingle_file_utils.py.Combined here (was #13933) since both touch the same two files — one review instead of two, and avoids a registry conflict between them.