mirror of
https://git.datalinker.icu/vllm-project/vllm.git
synced 2025-12-13 11:25:40 +08:00
Sort the outputs before return (#402)
This commit is contained in:
parent
2179e4f4c5
commit
b6fbb9a565
@ -155,4 +155,8 @@ class LLM:
|
|||||||
pbar.update(1)
|
pbar.update(1)
|
||||||
if use_tqdm:
|
if use_tqdm:
|
||||||
pbar.close()
|
pbar.close()
|
||||||
|
# Sort the outputs by request ID.
|
||||||
|
# This is necessary because some requests may be finished earlier than
|
||||||
|
# its previous requests.
|
||||||
|
outputs = sorted(outputs, key=lambda x: int(x.request_id))
|
||||||
return outputs
|
return outputs
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user