Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
renzhc
diffusers_dcu
Commits
799adf4a
Unverified
Commit
799adf4a
authored
May 19, 2025
by
Dhruv Nair
Committed by
GitHub
May 19, 2025
Browse files
[Single File] Fix loading for LTX 0.9.7 transformer (#11578)
update
parent
00f9273d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletion
+5
-1
src/diffusers/loaders/single_file_utils.py
src/diffusers/loaders/single_file_utils.py
+5
-1
No files found.
src/diffusers/loaders/single_file_utils.py
View file @
799adf4a
...
...
@@ -179,6 +179,7 @@ DIFFUSERS_DEFAULT_PIPELINE_PATHS = {
"ltx-video"
:
{
"pretrained_model_name_or_path"
:
"diffusers/LTX-Video-0.9.0"
},
"ltx-video-0.9.1"
:
{
"pretrained_model_name_or_path"
:
"diffusers/LTX-Video-0.9.1"
},
"ltx-video-0.9.5"
:
{
"pretrained_model_name_or_path"
:
"Lightricks/LTX-Video-0.9.5"
},
"ltx-video-0.9.7"
:
{
"pretrained_model_name_or_path"
:
"Lightricks/LTX-Video-0.9.7-dev"
},
"autoencoder-dc-f128c512"
:
{
"pretrained_model_name_or_path"
:
"mit-han-lab/dc-ae-f128c512-mix-1.0-diffusers"
},
"autoencoder-dc-f64c128"
:
{
"pretrained_model_name_or_path"
:
"mit-han-lab/dc-ae-f64c128-mix-1.0-diffusers"
},
"autoencoder-dc-f32c32"
:
{
"pretrained_model_name_or_path"
:
"mit-han-lab/dc-ae-f32c32-mix-1.0-diffusers"
},
...
...
@@ -644,7 +645,10 @@ def infer_diffusers_model_type(checkpoint):
model_type
=
"flux-schnell"
elif
any
(
key
in
checkpoint
for
key
in
CHECKPOINT_KEY_NAMES
[
"ltx-video"
]):
if
checkpoint
[
"vae.encoder.conv_out.conv.weight"
].
shape
[
1
]
==
2048
:
has_vae
=
"vae.encoder.conv_in.conv.bias"
in
checkpoint
if
any
(
key
.
endswith
(
"transformer_blocks.47.scale_shift_table"
)
for
key
in
checkpoint
):
model_type
=
"ltx-video-0.9.7"
elif
has_vae
and
checkpoint
[
"vae.encoder.conv_out.conv.weight"
].
shape
[
1
]
==
2048
:
model_type
=
"ltx-video-0.9.5"
elif
"vae.decoder.last_time_embedder.timestep_embedder.linear_1.weight"
in
checkpoint
:
model_type
=
"ltx-video-0.9.1"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment