-
Notifications
You must be signed in to change notification settings - Fork 155
Add B300 config: dsv4-fp4fp8-vllm (DeepSeek-V4-Pro) #1128
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,89 @@ | ||
| #!/usr/bin/env bash | ||
|
|
||
| # Per https://vllm.ai/blog/deepseek-v4 the DeepSeek-V4-Pro recipe lists | ||
| # 8xB200 and 8xB300 with identical flags, so this script mirrors | ||
| # dsv4_fp4_b200.sh. | ||
|
|
||
| source "$(dirname "$0")/../benchmark_lib.sh" | ||
|
|
||
| check_env_vars \ | ||
| MODEL \ | ||
| TP \ | ||
| CONC \ | ||
| ISL \ | ||
| OSL \ | ||
| MAX_MODEL_LEN \ | ||
| RANDOM_RANGE_RATIO \ | ||
| RESULT_FILENAME | ||
|
|
||
| if [[ -n "$SLURM_JOB_ID" ]]; then | ||
| echo "JOB $SLURM_JOB_ID running on $SLURMD_NODENAME" | ||
| fi | ||
|
|
||
| nvidia-smi | ||
|
|
||
| hf download "$MODEL" | ||
|
|
||
| SERVER_LOG=/workspace/server.log | ||
| PORT=${PORT:-8888} | ||
|
|
||
| # DeepSeek-V4-Pro weights are large and engine startup on B300 can exceed | ||
| # the default 600s. Give it an hour to load. | ||
| export VLLM_ENGINE_READY_TIMEOUT_S=3600 | ||
|
|
||
| if [ "${EVAL_ONLY}" = "true" ]; then | ||
| setup_eval_context | ||
| MAX_MODEL_LEN="$EVAL_MAX_MODEL_LEN" | ||
| fi | ||
|
|
||
| # Start GPU monitoring (power, temperature, clocks every second) | ||
| start_gpu_monitor | ||
|
|
||
| # Per the recipe, run with EP + DP=8 (no --tensor-parallel-size flag). TP | ||
| # from the search space is used only for GPU allocation by the runner and | ||
| # as the DP size. | ||
| set -x | ||
| vllm serve $MODEL --host 0.0.0.0 --port $PORT \ | ||
| --trust-remote-code \ | ||
| --kv-cache-dtype fp8 \ | ||
| --block-size 256 \ | ||
| --no-enable-prefix-caching \ | ||
| --enable-expert-parallel \ | ||
| --data-parallel-size $TP \ | ||
| --max-model-len $MAX_MODEL_LEN \ | ||
| --compilation-config '{"cudagraph_mode":"FULL_AND_PIECEWISE","custom_ops":["all"]}' \ | ||
| --attention_config.use_fp4_indexer_cache=True \ | ||
| --tokenizer-mode deepseek_v4 \ | ||
| --tool-call-parser deepseek_v4 \ | ||
| --enable-auto-tool-choice \ | ||
| --reasoning-parser deepseek_v4 > $SERVER_LOG 2>&1 & | ||
|
|
||
| SERVER_PID=$! | ||
|
|
||
| # Wait for server to be ready | ||
| wait_for_server_ready --port "$PORT" --server-log "$SERVER_LOG" --server-pid "$SERVER_PID" | ||
|
|
||
| pip install -q datasets pandas | ||
|
|
||
| run_benchmark_serving \ | ||
| --model "$MODEL" \ | ||
| --port "$PORT" \ | ||
| --backend vllm \ | ||
| --input-len "$ISL" \ | ||
| --output-len "$OSL" \ | ||
| --random-range-ratio "$RANDOM_RANGE_RATIO" \ | ||
| --num-prompts "$((CONC * 10))" \ | ||
| --max-concurrency "$CONC" \ | ||
| --result-filename "$RESULT_FILENAME" \ | ||
| --result-dir /workspace/ \ | ||
| --trust-remote-code | ||
|
|
||
| # After throughput, run evaluation only if RUN_EVAL is true | ||
| if [ "${RUN_EVAL}" = "true" ]; then | ||
| run_eval --framework lm-eval --port "$PORT" | ||
| append_lm_eval_summary | ||
| fi | ||
|
|
||
| # Stop GPU monitoring | ||
| stop_gpu_monitor | ||
| set +x | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🟡 The new
dsv4_fp4_b300.shhardcodes--enable-expert-parallelat line 47, violating the project's PR-review rule (.github/workflows/claude-pr-review.ymllines 141-159) that scripts must conditionally enable EP based onEP_SIZE. Every other vLLM/ATOM script inbenchmarks/single_node/uses theif [ "$EP_SIZE" -gt 1 ]pattern; please wrap the flag the same way (and addEP_SIZEtocheck_env_vars) so a future search-space entry withep: 1doesn't silently still apply expert parallelism.Extended reasoning...
What the bug is
In
benchmarks/single_node/dsv4_fp4_b300.shline 47, thevllm serveinvocation hardcodes--enable-expert-parallelunconditionally. The repo's own PR-review rules (.github/workflows/claude-pr-review.ymllines 141-159) explicitly forbid this and prescribe the canonical pattern:The rule is documented as a 🟡 WARNING-level review issue. Today the script also doesn't list
EP_SIZEin itscheck_env_varscall (lines 8-16), so even if a caller exportedEP_SIZE=1, the script would ignore it.Why existing code doesn't prevent it
The sole reason runtime behavior is currently fine is that the new YAML search space (
.github/configs/nvidia-master.yaml) only emitsep: 8entries, so the runner always intends EP. There is nothing structural preventing a futureep: 1entry — and once one is added, this script will silently still pass--enable-expert-parallel, contradicting the YAML's declared intent.Code-path proof
{ tp: 8, ep: 1, ... }todsv4-fp4-b300-vllm.search-spaceinnvidia-master.yamlto compare TP-only vs EP performance.EP_SIZE=1into the script's environment (this is the standard contract used by every other ATOM/vLLM script inbenchmarks/single_node/).EP_SIZE—check_env_varsdoesn't list it, and thevllm servecommand unconditionally has--enable-expert-parallelbaked in.ep: 1configuration. The run is silently mislabeled in the result store.Convention evidence
Grep over
benchmarks/single_node/shows ~24 sibling vLLM/ATOM scripts that use the conditional pattern (minimaxm2.5_fp8_b300.sh:34,minimaxm2.5_fp8_b200.sh:30,dsr1_fp4_mi355x_atom.sh,dsr1_fp4_mi355x_atom_mtp.sh,dsr1_fp8_mi355x_atom.sh,dsr1_fp8_mi355x_atom_mtp.sh,glm5_fp8_mi355x_atom.sh,glm5.1_fp4_mi355x_atom.sh,gptoss_fp4_mi355x_atom.sh,kimik2.5_fp4_mi355x_atom.sh,qwen3.5_fp8_mi355x_atom.sh,qwen3.5_fp8_mi355x_atom_mtp.sh, etc.).dsv4_fp4_b300.shis the lone outlier.Fix
EP_SIZEto thecheck_env_varscall (lines 8-16).vllm serveblock, insert:--enable-expert-parallel \line with$EP \(matching the pattern in the sibling scripts).Severity rationale
The project's own review rule classifies this as WARNING (not blocking), and runtime behavior is unaffected today because the YAML always emits
ep: 8. It's a convention/robustness issue rather than a current functional bug — filing asnit.