vllm - 💡(How to fix) Fix [Performance]: vllm 19.0 online server测试波动偏大 [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
vllm-project/vllm#40001Fetched 2026-04-17 08:27:46
View on GitHub
Comments
0
Participants
1
Timeline
1
Reactions
0
Author
Participants
Timeline (top)
labeled ×1

Code Example

export CUBLAS_WORKSPACE_CONFIG=:4096:8
export PYTHONHASHSEED=0
OMP_NUM_THREADS=1 \
CUDA_VISIBLE_DEVICES=0,1,2,3,4,5,6,7 python -m vllm.entrypoints.openai.api_server --model /models/Qwen3-VL-8B-Instruct --served-model-name Qwen3-VL-8B-Instruct --port=8007 --limit-mm-per-prompt.image=15 --seed 42 --gpu-memory-utilization 0.90 --trust-remote-code True --tensor-parallel-size 8 --attention-backend FLASH_ATTN

---

accuracy: 0.7155172413793104
    precision: 0.7916666666666666
    recall: 0.6551724137931034
    f1: 0.7169811320754716
    tp: 38
    fp: 10
    fn: 20
    tn: 45

    accuracy: 0.7844827586206896
    precision: 0.7692307692307693
    recall: 0.8333333333333334
    f1: 0.8
    tp: 50
    fp: 15
    fn: 10
    tn: 41

    "accuracy": 0.7241379310344828,
    "precision": 0.7959183673469388,
    "recall": 0.6724137931034483,
    "f1": 0.7289719626168225,
    "tp": 39,
    "fp": 10,
    "fn": 19,
    "tn": 45,

---

The output of `python collect_env.py`
RAW_BUFFERClick to expand / collapse

Proposal to improve performance

将模型部署成server做测测试,命令如下:

export CUBLAS_WORKSPACE_CONFIG=:4096:8
export PYTHONHASHSEED=0
OMP_NUM_THREADS=1 \
CUDA_VISIBLE_DEVICES=0,1,2,3,4,5,6,7 python -m vllm.entrypoints.openai.api_server --model /models/Qwen3-VL-8B-Instruct --served-model-name Qwen3-VL-8B-Instruct --port=8007 --limit-mm-per-prompt.image=15 --seed 42 --gpu-memory-utilization 0.90 --trust-remote-code True --tensor-parallel-size 8 --attention-backend FLASH_ATTN

在batch size 为32,temperature 0 seed 42下请求调用,一批116的数据测试acc波动很大

    accuracy: 0.7155172413793104
    precision: 0.7916666666666666
    recall: 0.6551724137931034
    f1: 0.7169811320754716
    tp: 38
    fp: 10
    fn: 20
    tn: 45

    accuracy: 0.7844827586206896
    precision: 0.7692307692307693
    recall: 0.8333333333333334
    f1: 0.8
    tp: 50
    fp: 15
    fn: 10
    tn: 41

    "accuracy": 0.7241379310344828,
    "precision": 0.7959183673469388,
    "recall": 0.6724137931034483,
    "f1": 0.7289719626168225,
    "tp": 39,
    "fp": 10,
    "fn": 19,
    "tn": 45,

ACC最大靠近7个点

Report of performance regression

No response

Misc discussion on performance

No response

Your current environment (if you think it is necessary)

The output of `python collect_env.py`

Before submitting a new issue...

  • Make sure you already searched for relevant issues, and asked the chatbot living at the bottom right corner of the documentation page, which can answer lots of frequently asked questions.

extent analysis

TL;DR

  • Investigate and adjust the batch size, gpu-memory-utilization, and tensor-parallel-size parameters to stabilize the accuracy of the model.

Guidance

  • Review the command used to deploy the model as a server, focusing on parameters that could impact performance and accuracy, such as batch size, gpu-memory-utilization, and tensor-parallel-size.
  • Consider reducing the batch size from 32 to a smaller number to see if it improves the stability of the accuracy.
  • Experiment with different values for gpu-memory-utilization and tensor-parallel-size to find an optimal balance between performance and accuracy.
  • Verify the impact of these changes by running multiple tests with the same set of data to check for consistency in accuracy.

Example

No specific code example is provided due to the lack of direct code issues in the problem statement. However, an example command adjusting some of the mentioned parameters could look like:

OMP_NUM_THREADS=1 \
CUDA_VISIBLE_DEVICES=0,1,2,3,4,5,6,7 python -m vllm.entrypoints.openai.api_server --model /models/Qwen3-VL-8B-Instruct --served-model-name Qwen3-VL-8B-Instruct --port=8007 --limit-mm-per-prompt.image=15 --seed 42 --gpu-memory-utilization 0.80 --trust-remote-code True --tensor-parallel-size 4 --attention-backend FLASH_ATTN

This example reduces gpu-memory-utilization to 0.80 and tensor-parallel-size to 4, which might help in stabilizing the performance.

Notes

  • The actual optimal parameters may vary depending on the specific hardware and model being used.
  • It's crucial to monitor the system's resources and the model's performance during these experiments to avoid overloading the GPUs.

Recommendation

  • Apply workaround: Adjust the model deployment parameters to find a stable configuration that balances performance and accuracy, as the issue seems to be related to the current configuration rather than a version-specific bug.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING