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
18f9b990
Unverified
Commit
18f9b990
authored
Dec 06, 2024
by
Aryan
Committed by
GitHub
Dec 06, 2024
Browse files
Remove duplicate checks for len(generator) != batch_size when generator is a list (#10134)
remove duplicate checks
parent
bf64b326
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
0 additions
and
18 deletions
+0
-18
src/diffusers/pipelines/animatediff/pipeline_animatediff_video2video.py
...pipelines/animatediff/pipeline_animatediff_video2video.py
+0
-6
src/diffusers/pipelines/animatediff/pipeline_animatediff_video2video_controlnet.py
...nimatediff/pipeline_animatediff_video2video_controlnet.py
+0
-6
src/diffusers/pipelines/cogvideo/pipeline_cogvideox_video2video.py
...sers/pipelines/cogvideo/pipeline_cogvideox_video2video.py
+0
-6
No files found.
src/diffusers/pipelines/animatediff/pipeline_animatediff_video2video.py
View file @
18f9b990
...
...
@@ -662,12 +662,6 @@ class AnimateDiffVideoToVideoPipeline(
self
.
vae
.
to
(
dtype
=
torch
.
float32
)
if
isinstance
(
generator
,
list
):
if
len
(
generator
)
!=
batch_size
:
raise
ValueError
(
f
"You have passed a list of generators of length
{
len
(
generator
)
}
, but requested an effective batch"
f
" size of
{
batch_size
}
. Make sure the batch size matches the length of the generators."
)
init_latents
=
[
self
.
encode_video
(
video
[
i
],
generator
[
i
],
decode_chunk_size
).
unsqueeze
(
0
)
for
i
in
range
(
batch_size
)
...
...
src/diffusers/pipelines/animatediff/pipeline_animatediff_video2video_controlnet.py
View file @
18f9b990
...
...
@@ -794,12 +794,6 @@ class AnimateDiffVideoToVideoControlNetPipeline(
self
.
vae
.
to
(
dtype
=
torch
.
float32
)
if
isinstance
(
generator
,
list
):
if
len
(
generator
)
!=
batch_size
:
raise
ValueError
(
f
"You have passed a list of generators of length
{
len
(
generator
)
}
, but requested an effective batch"
f
" size of
{
batch_size
}
. Make sure the batch size matches the length of the generators."
)
init_latents
=
[
self
.
encode_video
(
video
[
i
],
generator
[
i
],
decode_chunk_size
).
unsqueeze
(
0
)
for
i
in
range
(
batch_size
)
...
...
src/diffusers/pipelines/cogvideo/pipeline_cogvideox_video2video.py
View file @
18f9b990
...
...
@@ -373,12 +373,6 @@ class CogVideoXVideoToVideoPipeline(DiffusionPipeline, CogVideoXLoraLoaderMixin)
if
latents
is
None
:
if
isinstance
(
generator
,
list
):
if
len
(
generator
)
!=
batch_size
:
raise
ValueError
(
f
"You have passed a list of generators of length
{
len
(
generator
)
}
, but requested an effective batch"
f
" size of
{
batch_size
}
. Make sure the batch size matches the length of the generators."
)
init_latents
=
[
retrieve_latents
(
self
.
vae
.
encode
(
video
[
i
].
unsqueeze
(
0
)),
generator
[
i
])
for
i
in
range
(
batch_size
)
]
...
...
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