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
40f26734
Unverified
Commit
40f26734
authored
Aug 19, 2025
by
Woosuk Kwon
Committed by
GitHub
Aug 19, 2025
Browse files
[Misc] Fix seq_lens for graph capture (#23175)
Signed-off-by:
Woosuk Kwon
<
woosuk.kwon@berkeley.edu
>
parent
2c3f557f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
4 deletions
+2
-4
vllm/v1/worker/gpu_model_runner.py
vllm/v1/worker/gpu_model_runner.py
+2
-4
No files found.
vllm/v1/worker/gpu_model_runner.py
View file @
40f26734
...
...
@@ -2317,15 +2317,13 @@ class GPUModelRunner(LoRAModelRunnerMixin, KVConnectorModelRunnerMixin):
# If force_attention is True, we always capture attention. Otherwise,
# it only happens for cudagraph_runtime_mode=FULL.
if
force_attention
or
cudagraph_runtime_mode
==
\
CUDAGraphMode
.
FULL
:
if
force_attention
or
cudagraph_runtime_mode
==
CUDAGraphMode
.
FULL
:
attn_metadata
=
{}
# Make sure max_model_len is used at the graph capture time.
self
.
seq_lens_np
[:
num_reqs
]
=
self
.
max_model_len
self
.
seq_lens_np
[
num_reqs
:]
=
0
self
.
seq_lens
[:
num_reqs
].
copy_
(
self
.
seq_lens_cpu
[:
num_reqs
],
non_blocking
=
True
)
self
.
seq_lens
.
copy_
(
self
.
seq_lens_cpu
,
non_blocking
=
True
)
for
kv_cache_group_id
,
kv_cache_group_spec
in
enumerate
(
self
.
kv_cache_config
.
kv_cache_groups
):
...
...
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