Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
c33afd89
Unverified
Commit
c33afd89
authored
Mar 13, 2024
by
Antoni Baum
Committed by
GitHub
Mar 13, 2024
Browse files
Fix lint (#3388)
parent
7e9bd08f
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
vllm/model_executor/layers/rotary_embedding.py
vllm/model_executor/layers/rotary_embedding.py
+2
-2
No files found.
vllm/model_executor/layers/rotary_embedding.py
View file @
c33afd89
...
@@ -143,8 +143,8 @@ class RotaryEmbedding(nn.Module):
...
@@ -143,8 +143,8 @@ class RotaryEmbedding(nn.Module):
offsets
:
Optional
[
torch
.
Tensor
]
=
None
,
offsets
:
Optional
[
torch
.
Tensor
]
=
None
,
)
->
Tuple
[
torch
.
Tensor
,
torch
.
Tensor
]:
)
->
Tuple
[
torch
.
Tensor
,
torch
.
Tensor
]:
self
.
cos_sin_cache
=
self
.
cos_sin_cache
.
to
(
positions
.
get_device
())
self
.
cos_sin_cache
=
self
.
cos_sin_cache
.
to
(
positions
.
get_device
())
# ops.rotary_embedding()/batched_rotary_embedding()
are in-place operations that
# ops.rotary_embedding()/batched_rotary_embedding()
# update the query and key tensors.
#
are in-place operations that
update the query and key tensors.
if
offsets
is
not
None
:
if
offsets
is
not
None
:
ops
.
batched_rotary_embedding
(
positions
,
query
,
key
,
self
.
head_size
,
ops
.
batched_rotary_embedding
(
positions
,
query
,
key
,
self
.
head_size
,
self
.
cos_sin_cache
,
self
.
cos_sin_cache
,
...
...
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