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
norm
vllm
Commits
2bdea7ac
Unverified
Commit
2bdea7ac
authored
Jul 17, 2023
by
Zhuohan Li
Committed by
GitHub
Jul 17, 2023
Browse files
[Fix] Fix the condition of max_seq_len (#477)
parent
58df2883
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
vllm/core/scheduler.py
vllm/core/scheduler.py
+1
-1
vllm/engine/llm_engine.py
vllm/engine/llm_engine.py
+1
-1
No files found.
vllm/core/scheduler.py
View file @
2bdea7ac
...
...
@@ -190,7 +190,7 @@ class Scheduler:
break
num_prompt_tokens
=
seq_group
.
get_seqs
()[
0
].
get_len
()
if
num_prompt_tokens
>
=
self
.
scheduler_config
.
max_seq_len
:
if
num_prompt_tokens
>
self
.
scheduler_config
.
max_seq_len
:
logger
.
warning
(
f
"Input prompt (
{
num_prompt_tokens
}
tokens) is too long"
" and exceeds limit of "
...
...
vllm/engine/llm_engine.py
View file @
2bdea7ac
...
...
@@ -300,7 +300,7 @@ class LLMEngine:
continue
# Check if the sequence has reached max_seq_len.
if
(
seq
.
get_len
()
>
=
if
(
seq
.
get_len
()
>
self
.
scheduler
.
scheduler_config
.
max_seq_len
):
self
.
scheduler
.
free_seq
(
seq
,
SequenceStatus
.
FINISHED_LENGTH_CAPPED
)
...
...
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