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
e27142ac
Unverified
Commit
e27142ac
authored
Jun 11, 2025
by
Tolga Cangöz
Committed by
GitHub
Jun 11, 2025
Browse files
[`Wan`] Fix VAE sampling mode in `WanVideoToVideoPipeline` (#11639)
* fix: vae sampling mode * fix a typo
parent
8e88495d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
7 deletions
+2
-7
src/diffusers/pipelines/wan/pipeline_wan_video2video.py
src/diffusers/pipelines/wan/pipeline_wan_video2video.py
+2
-7
No files found.
src/diffusers/pipelines/wan/pipeline_wan_video2video.py
View file @
e27142ac
...
...
@@ -419,12 +419,7 @@ class WanVideoToVideoPipeline(DiffusionPipeline, WanLoraLoaderMixin):
)
if
latents
is
None
:
if
isinstance
(
generator
,
list
):
init_latents
=
[
retrieve_latents
(
self
.
vae
.
encode
(
video
[
i
].
unsqueeze
(
0
)),
generator
[
i
])
for
i
in
range
(
batch_size
)
]
else
:
init_latents
=
[
retrieve_latents
(
self
.
vae
.
encode
(
vid
.
unsqueeze
(
0
)),
generator
)
for
vid
in
video
]
init_latents
=
[
retrieve_latents
(
self
.
vae
.
encode
(
vid
.
unsqueeze
(
0
)),
sample_mode
=
"argmax"
)
for
vid
in
video
]
init_latents
=
torch
.
cat
(
init_latents
,
dim
=
0
).
to
(
dtype
)
...
...
@@ -441,7 +436,7 @@ class WanVideoToVideoPipeline(DiffusionPipeline, WanLoraLoaderMixin):
if
hasattr
(
self
.
scheduler
,
"add_noise"
):
latents
=
self
.
scheduler
.
add_noise
(
init_latents
,
noise
,
timestep
)
else
:
latents
=
self
.
schedu
e
lr
.
scale_noise
(
init_latents
,
timestep
,
noise
)
latents
=
self
.
schedul
e
r
.
scale_noise
(
init_latents
,
timestep
,
noise
)
else
:
latents
=
latents
.
to
(
device
)
...
...
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