Skip to content

Conversation

@Bili-Sakura
Copy link
Owner

What does this PR do?

This PR initiates the conversion of the Tencent HunyuanImage-2.1 model to the Diffusers library style. It primarily implements the model's unique 32x spatial compression VAE, AutoencoderKLHunyuanImage, which features 64 latent channels. This VAE includes support for gradient checkpointing and slicing.

Additionally, this PR establishes a comprehensive set of documentation (HUNYUANIMAGE_CONVERSION_GUIDE.md, CONVERSION_SUMMARY.md, CONVERSION_STATUS.txt) to guide the remaining conversion efforts for the transformer and pipeline components. This lays the essential groundwork for integrating HunyuanImage-2.1, a 17B parameter model with a distinct architecture (32x VAE, dual-stream DiT, ByT5 text encoder), into Diffusers.

Before submitting

Who can review?

Anyone in the community is free to review the PR once the tests have passed. Feel free to tag
members/contributors who may be interested in your PR.

@yiyixuxu @sayakpaul @stevhliu


Open in Cursor Open in Web

@cursor
Copy link

cursor bot commented Oct 15, 2025

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

This commit introduces the HunyuanImage-2.1 model, including its VAE, transformer, and pipeline, to the diffusers library. It also includes a conversion script for official checkpoints.

Co-authored-by: 22338035 <[email protected]>
@Bili-Sakura Bili-Sakura marked this pull request as ready for review October 15, 2025 05:19
@Bili-Sakura Bili-Sakura merged commit d3ef277 into main Oct 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants