-
Notifications
You must be signed in to change notification settings - Fork 6.4k
HunyuanImage21 #12333
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
HunyuanImage21 #12333
Changes from 39 commits
Commits
Show all changes
61 commits
Select commit
Hold shift + click to select a range
415805b
initial model
yiyixuxu feb29c3
add vae
yiyixuxu bb8f753
style
yiyixuxu a9def70
add pipeline
yiyixuxu 3287f4b
style
yiyixuxu 7e0311d
add import
yiyixuxu 9938cbb
add
yiyixuxu cceae4a
add refiner vae
yiyixuxu 419c99d
remove more rearrange
yiyixuxu 02864b5
remove einops
yiyixuxu 790aeff
make style
yiyixuxu aef133d
add refiner pipeline, not tested yet
yiyixuxu 9e8b94a
up
yiyixuxu 58514f5
fix a bug in vae
yiyixuxu a9b8b8c
remove more eiops
yiyixuxu fd5c8b1
ffactor_spatial -> spatial_compression_ratio
yiyixuxu d30dc2a
work with distilled
yiyixuxu 062c21c
fix imports
yiyixuxu fb6d99e
add conversion script
yiyixuxu 75ed404
Merge branch 'main' into hunyuan21
yiyixuxu 45da288
copies
yiyixuxu f9500a5
Merge branch 'hunyuan21' of github.com:huggingface/diffusers into hun…
yiyixuxu 894f148
add guider support
yiyixuxu 5d96356
add apg_mix
yiyixuxu 55ac631
style
yiyixuxu cf93a8b
up up
yiyixuxu 3499bbf
Update src/diffusers/models/autoencoders/autoencoder_kl_hunyuanimage_…
yiyixuxu 46cda84
update transformer: name, maybe_allow_in_graph
yiyixuxu 4e22f0f
style
yiyixuxu 64cb88d
copies
yiyixuxu 184d312
Merge branch 'hunyuan21' of github.com:huggingface/diffusers into hun…
yiyixuxu 67a721c
remove rearrange
yiyixuxu 69b0fc0
style
yiyixuxu 689566d
Merge branch 'main' into hunyuan21
yiyixuxu 0a2f56b
up
yiyixuxu 1e045af
Merge branch 'hunyuan21' of github.com:huggingface/diffusers into hun…
yiyixuxu b9fd002
add distilled_guidance_scale to adp
yiyixuxu 012b40d
style
yiyixuxu ec3290d
fix
yiyixuxu 1792aab
update guider: remove distilled guidannce scale, simplify prepare_inputs
yiyixuxu 3e12970
update pipeline, remove true_cfg_scale etc
yiyixuxu 81d3247
update docstring example
yiyixuxu 02ad165
add doc!
yiyixuxu b9de16b
style
yiyixuxu 0ca5320
dispatch_attention_fn
yiyixuxu a36a8c2
Merge branch 'main' into hunyuan21
yiyixuxu 9dc67a0
MomentumBuffer copied from
yiyixuxu 0dbab1f
Update docs/source/en/api/pipelines/hunyuanimage21.md
yiyixuxu de92bb1
register hyimage
yiyixuxu 8c140cb
remove a hadrcoded 1472
yiyixuxu f47a855
fix vae_tiling 5d -> 4d
yiyixuxu 8f98b9b
add tests
yiyixuxu f12ca4f
style
yiyixuxu ddae49b
Merge branch 'hunyuan21' of github.com:huggingface/diffusers into hun…
yiyixuxu 95fabd1
Apply suggestions from code review
yiyixuxu bfebde3
fix doc toctree and style
yiyixuxu f1e8296
update modular x guider
yiyixuxu 6336c19
update tests
yiyixuxu bd6b3d3
fix
yiyixuxu e7a8a0c
fix
yiyixuxu 8764ca3
up
yiyixuxu File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -65,8 +65,9 @@ def __init__( | |
| use_original_formulation: bool = False, | ||
| start: float = 0.0, | ||
| stop: float = 1.0, | ||
| enabled: bool = True, | ||
| ): | ||
| super().__init__(start, stop) | ||
| super().__init__(start, stop, enabled) | ||
|
|
||
| self.guidance_scale = guidance_scale | ||
| self.adaptive_projected_guidance_momentum = adaptive_projected_guidance_momentum | ||
|
|
@@ -85,10 +86,10 @@ def prepare_inputs( | |
| if self._step == 0: | ||
| if self.adaptive_projected_guidance_momentum is not None: | ||
| self.momentum_buffer = MomentumBuffer(self.adaptive_projected_guidance_momentum) | ||
| tuple_indices = [0] if self.num_conditions == 1 else [0, 1] | ||
| tuple_indices = [0] if self.num_conditions == 1 or not self._is_apg_enabled() else [0, 1] | ||
|
||
| data_batches = [] | ||
| for i in range(self.num_conditions): | ||
| data_batch = self._prepare_batch(input_fields, data, tuple_indices[i], self._input_predictions[i]) | ||
| for tuple_idx, input_prediction in zip(tuple_indices, self._input_predictions): | ||
| data_batch = self._prepare_batch(input_fields, data, tuple_idx, input_prediction) | ||
| data_batches.append(data_batch) | ||
| return data_batches | ||
|
|
||
|
|
||
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.