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
change
sglang
Commits
52029bd1
Unverified
Commit
52029bd1
authored
Mar 25, 2025
by
fzyzcjy
Committed by
GitHub
Mar 25, 2025
Browse files
Fix warmup error when dp=1 (#4753)
parent
eb934bdf
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
+6
-0
python/sglang/srt/entrypoints/http_server.py
python/sglang/srt/entrypoints/http_server.py
+6
-0
No files found.
python/sglang/srt/entrypoints/http_server.py
View file @
52029bd1
...
@@ -761,8 +761,14 @@ def _wait_and_warmup(
...
@@ -761,8 +761,14 @@ def _wait_and_warmup(
}
}
if
server_args
.
skip_tokenizer_init
:
if
server_args
.
skip_tokenizer_init
:
json_data
[
"input_ids"
]
=
[[
10
,
11
,
12
]
for
_
in
range
(
server_args
.
dp_size
)]
json_data
[
"input_ids"
]
=
[[
10
,
11
,
12
]
for
_
in
range
(
server_args
.
dp_size
)]
# TODO Workaround the bug that embedding errors for list of size 1
if
server_args
.
dp_size
==
1
:
json_data
[
"input_ids"
]
=
json_data
[
"input_ids"
][
0
]
else
:
else
:
json_data
[
"text"
]
=
[
"The capital city of France is"
]
*
server_args
.
dp_size
json_data
[
"text"
]
=
[
"The capital city of France is"
]
*
server_args
.
dp_size
# TODO Workaround the bug that embedding errors for list of size 1
if
server_args
.
dp_size
==
1
:
json_data
[
"text"
]
=
json_data
[
"text"
][
0
]
# Debug dumping
# Debug dumping
if
server_args
.
debug_tensor_dump_input_file
:
if
server_args
.
debug_tensor_dump_input_file
:
...
...
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