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
c4c99c39
Unverified
Commit
c4c99c39
authored
Dec 18, 2024
by
Aryan
Committed by
GitHub
Dec 18, 2024
Browse files
[tests] Fix broken cuda, nightly and lora tests on main for CogVideoX (#10270)
fix joint pos embedding device
parent
862a7d50
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
src/diffusers/models/embeddings.py
src/diffusers/models/embeddings.py
+1
-1
No files found.
src/diffusers/models/embeddings.py
View file @
c4c99c39
...
...
@@ -691,7 +691,7 @@ class CogVideoXPatchEmbed(nn.Module):
output_type
=
"pt"
,
)
pos_embedding
=
pos_embedding
.
flatten
(
0
,
1
)
joint_pos_embedding
=
torch
.
zeros
(
joint_pos_embedding
=
pos_embedding
.
new_
zeros
(
1
,
self
.
max_text_seq_length
+
num_patches
,
self
.
embed_dim
,
requires_grad
=
False
)
joint_pos_embedding
.
data
[:,
self
.
max_text_seq_length
:].
copy_
(
pos_embedding
)
...
...
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