Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
6fa116fb
Commit
6fa116fb
authored
Jan 20, 2026
by
zhuwenwen
Browse files
update VLLM_USE_TOPK_RENORM
parent
fb35feea
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
vllm/envs.py
vllm/envs.py
+1
-1
vllm/model_executor/layers/fused_moe/fused_moe.py
vllm/model_executor/layers/fused_moe/fused_moe.py
+1
-1
No files found.
vllm/envs.py
View file @
6fa116fb
...
@@ -1683,7 +1683,7 @@ environment_variables: dict[str, Callable[[], Any]] = {
...
@@ -1683,7 +1683,7 @@ environment_variables: dict[str, Callable[[], Any]] = {
# vLLM will use optimized topk_softmax + renormalize
# vLLM will use optimized topk_softmax + renormalize
"VLLM_USE_TOPK_RENORM"
:
"VLLM_USE_TOPK_RENORM"
:
lambda
:
lambda
:
(
os
.
environ
.
get
(
"VLLM_USE_TOPK_RENORM"
,
"
Fals
e"
).
lower
()
in
(
os
.
environ
.
get
(
"VLLM_USE_TOPK_RENORM"
,
"
Tru
e"
).
lower
()
in
(
"true"
,
"1"
)),
(
"true"
,
"1"
)),
# vLLM will use fused RMS + RoPE kernel
# vLLM will use fused RMS + RoPE kernel
"VLLM_USE_FUSED_RMS_ROPE"
:
"VLLM_USE_FUSED_RMS_ROPE"
:
...
...
vllm/model_executor/layers/fused_moe/fused_moe.py
View file @
6fa116fb
...
@@ -1363,7 +1363,7 @@ def vllm_topk_softmax(topk_weights: torch.Tensor, topk_indices: torch.Tensor,
...
@@ -1363,7 +1363,7 @@ def vllm_topk_softmax(topk_weights: torch.Tensor, topk_indices: torch.Tensor,
token_expert_indices
:
torch
.
Tensor
,
token_expert_indices
:
torch
.
Tensor
,
gating_output
:
torch
.
Tensor
,
gating_output
:
torch
.
Tensor
,
renormalize
:
bool
)
->
tuple
[
torch
.
Tensor
,
...]:
renormalize
:
bool
)
->
tuple
[
torch
.
Tensor
,
...]:
if
envs
.
VLLM_USE_TOPK_RENORM
:
if
envs
.
VLLM_USE_TOPK_RENORM
and
renormalize
is
True
:
from
lightop
import
op
as
op
from
lightop
import
op
as
op
op
.
topk_softmax
(
op
.
topk_softmax
(
topk_weights
,
topk_weights
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment