-
Notifications
You must be signed in to change notification settings - Fork 208
[NV]dsr1-fp4-b200-sglang: add DPA PDL lane #1792
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
Merged
Merged
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
2651117
add DPA PDL lane
hshrivastava-droid a2f2de3
Merge branch 'main' into nv/dsr1-fp4-v2
hshrivastava-droid 496cefc
Update perf-changelog.yaml
hshrivastava-droid d7ce1a1
Merge branch 'main' into nv/dsr1-fp4-v2
cquil11 8bc5659
Merge branch 'main' into nv/dsr1-fp4-v2
cquil11 37af7c5
Merge branch 'main' into nv/dsr1-fp4-v2
cquil11 426b637
Merge branch 'main' into nv/dsr1-fp4-v2
cquil11 ae3a317
Merge branch 'main' into nv/dsr1-fp4-v2
cquil11 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 |
|---|---|---|
|
|
@@ -2,6 +2,8 @@ | |
|
|
||
| source "$(dirname "$0")/../../benchmark_lib.sh" | ||
|
|
||
| DP_ATTENTION="${DP_ATTENTION:-false}" | ||
|
|
||
| check_env_vars \ | ||
| MODEL \ | ||
| TP \ | ||
|
|
@@ -10,7 +12,13 @@ check_env_vars \ | |
| OSL \ | ||
| RANDOM_RANGE_RATIO \ | ||
| RESULT_FILENAME \ | ||
| EP_SIZE | ||
| EP_SIZE \ | ||
| DP_ATTENTION | ||
|
|
||
| if [[ "$DP_ATTENTION" != "true" && "$DP_ATTENTION" != "false" ]]; then | ||
| echo "DP_ATTENTION must be true or false; got '$DP_ATTENTION'" >&2 | ||
| exit 1 | ||
| fi | ||
|
|
||
| if [[ -n "$SLURM_JOB_ID" ]]; then | ||
| echo "JOB $SLURM_JOB_ID running on $SLURMD_NODENAME" | ||
|
|
@@ -22,13 +30,38 @@ nvidia-smi | |
|
|
||
| SERVER_LOG=/workspace/server.log | ||
|
|
||
| # Default: recv every ~10 requests; if CONC ≥ 16, relax to ~30 requests between scheduler recv polls. | ||
| # Default: recv every ~10 requests; if CONC >= 16, relax to ~30 requests between scheduler recv polls. | ||
| if [[ $CONC -ge 16 ]]; then | ||
| SCHEDULER_RECV_INTERVAL=30 | ||
| else | ||
| SCHEDULER_RECV_INTERVAL=10 | ||
| fi | ||
| echo "SCHEDULER_RECV_INTERVAL: $SCHEDULER_RECV_INTERVAL, CONC: $CONC, ISL: $ISL, OSL: $OSL" | ||
|
|
||
| CHUNKED_PREFILL_SIZE=16384 | ||
| SGLANG_PARALLEL_ARGS=( | ||
| --tensor-parallel-size="$TP" | ||
| --data-parallel-size=1 | ||
| ) | ||
| SGLANG_DPA_ARGS=() | ||
|
|
||
| if [[ "$DP_ATTENTION" == "true" ]]; then | ||
| SCHEDULER_RECV_INTERVAL=1 | ||
| CHUNKED_PREFILL_SIZE=32768 | ||
| SGLANG_PARALLEL_ARGS=( | ||
| --tensor-parallel-size="$TP" | ||
| --data-parallel-size="$TP" | ||
| --enable-dp-attention | ||
| --enable-dp-attention-local-control-broadcast | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. sgalng cookbook There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Added to SGLang cookbook: https://github.com/sgl-project/sglang/pull/28954/changes Please let me know if there is any issue |
||
| --enable-dp-lm-head | ||
| ) | ||
| SGLANG_DPA_ARGS=( | ||
| --schedule-conservativeness 3.33 | ||
| --enable-prefill-delayer | ||
|
cquil11 marked this conversation as resolved.
|
||
| ) | ||
| fi | ||
|
|
||
| echo "TP: $TP, EP_SIZE: $EP_SIZE, DP_ATTENTION: $DP_ATTENTION, CONC: $CONC, ISL: $ISL, OSL: $OSL" | ||
| echo "SCHEDULER_RECV_INTERVAL: $SCHEDULER_RECV_INTERVAL, CHUNKED_PREFILL_SIZE: $CHUNKED_PREFILL_SIZE" | ||
|
|
||
| EVAL_CONTEXT_ARGS="" | ||
| if [ "${EVAL_ONLY}" = "true" ]; then | ||
|
|
@@ -39,12 +72,12 @@ fi | |
| start_gpu_monitor | ||
|
|
||
| set -x | ||
| PYTHONNOUSERSITE=1 python3 -m sglang.launch_server --model-path $MODEL --host 0.0.0.0 --port $PORT --trust-remote-code \ | ||
| --tensor-parallel-size=$TP --data-parallel-size=1 \ | ||
| SGLANG_RADIX_FORCE_MISS=1 PYTHONNOUSERSITE=1 python3 -m sglang.launch_server --model-path $MODEL --host 0.0.0.0 --port $PORT --trust-remote-code \ | ||
| "${SGLANG_PARALLEL_ARGS[@]}" \ | ||
| --cuda-graph-max-bs 256 --max-running-requests 256 --mem-fraction-static 0.85 --kv-cache-dtype fp8_e4m3 \ | ||
| --chunked-prefill-size 16384 \ | ||
| --chunked-prefill-size "$CHUNKED_PREFILL_SIZE" \ | ||
| --ep-size $EP_SIZE --quantization modelopt_fp4 --enable-flashinfer-allreduce-fusion --scheduler-recv-interval $SCHEDULER_RECV_INTERVAL \ | ||
| --enable-symm-mem --disable-radix-cache --attention-backend trtllm_mla --moe-runner-backend flashinfer_trtllm --stream-interval 10 $EVAL_CONTEXT_ARGS > $SERVER_LOG 2>&1 & | ||
|
Ankur-singh marked this conversation as resolved.
|
||
| --enable-symm-mem --disable-piecewise-cuda-graph --attention-backend trtllm_mla --moe-runner-backend flashinfer_trtllm --stream-interval 10 "${SGLANG_DPA_ARGS[@]}" $EVAL_CONTEXT_ARGS > $SERVER_LOG 2>&1 & | ||
|
|
||
| SERVER_PID=$! | ||
|
|
||
|
|
||
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
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.
Uh oh!
There was an error while loading. Please reload this page.