Skip to content

Commit 59120b6

Browse files
[Docs] Add comment explaining DEEPEP_MAX_TOKENS_PER_RANK env variable (#1624)
Co-authored-by: claude[bot] <41898282+claude[bot]@users.noreply.github.com>
1 parent 7ca0434 commit 59120b6

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

xtuner/v1/ray/rollout/lmdeploy.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -349,6 +349,11 @@ def _transform_rollout_config_to_server_configs(self) -> Namespace:
349349
{
350350
"LMDEPLOY_DP_MASTER_ADDR": dist_addr,
351351
"LMDEPLOY_DP_MASTER_PORT": dist_port,
352+
# DEEPEP_MAX_TOKENS_PER_RANK is required by DLBlas's DeepEP
353+
# token dispatcher used in lmdeploy EP mode. Without it,
354+
# lmdeploy will fail during warmup.
355+
# Ref: https://github.com/DeepLink-org/DLBlas/blob/aae23445/dlblas/layers/moe/token_dispatcher.py#L81
356+
# Ref: https://github.com/InternLM/lmdeploy/blob/81627e3d/lmdeploy/utils.py#L375
352357
"DEEPEP_MAX_TOKENS_PER_RANK": str(max_batch_size),
353358
}
354359
)

0 commit comments

Comments
 (0)