Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
change
sglang
Commits
9a719b7a
Unverified
Commit
9a719b7a
authored
Sep 05, 2025
by
Kaixi Hou
Committed by
GitHub
Sep 05, 2025
Browse files
[NVIDIA] Remove unused `get_fused_moe_impl_class` function (#9764)
parent
3fa62da7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 addition
and
18 deletions
+1
-18
python/sglang/srt/layers/moe/fused_moe_triton/layer.py
python/sglang/srt/layers/moe/fused_moe_triton/layer.py
+0
-13
python/sglang/srt/layers/quantization/fp8.py
python/sglang/srt/layers/quantization/fp8.py
+1
-5
No files found.
python/sglang/srt/layers/moe/fused_moe_triton/layer.py
View file @
9a719b7a
...
@@ -1074,16 +1074,3 @@ class FlashInferFP4MoE(FusedMoE):
...
@@ -1074,16 +1074,3 @@ class FlashInferFP4MoE(FusedMoE):
)[
0
]
)[
0
]
return
result
return
result
def
get_fused_moe_impl_class
():
"""Factory function to get the appropriate FusedMoE implementation class."""
if
should_use_flashinfer_trtllm_moe
()
and
_is_fp4_quantization_enabled
():
# Use FP4 variant when FP4 quantization is enabled
return
FlashInferFP4MoE
elif
should_use_flashinfer_trtllm_moe
():
# Use regular FlashInfer variant for non-FP4 FlashInfer cases
return
FlashInferFusedMoE
else
:
# Default case
return
FusedMoE
python/sglang/srt/layers/quantization/fp8.py
View file @
9a719b7a
...
@@ -635,11 +635,7 @@ class Fp8MoEMethod(FusedMoEMethodBase):
...
@@ -635,11 +635,7 @@ class Fp8MoEMethod(FusedMoEMethodBase):
layer
.
register_parameter
(
"w13_weight_scale_inv"
,
w13_weight_scale
)
layer
.
register_parameter
(
"w13_weight_scale_inv"
,
w13_weight_scale
)
layer
.
register_parameter
(
"w2_weight_scale_inv"
,
w2_weight_scale
)
layer
.
register_parameter
(
"w2_weight_scale_inv"
,
w2_weight_scale
)
assert
self
.
quant_config
.
activation_scheme
==
"dynamic"
assert
self
.
quant_config
.
activation_scheme
==
"dynamic"
if
(
if
self
.
use_cutlass_fused_experts_fp8
:
get_bool_env_var
(
"SGLANG_CUTLASS_MOE"
)
and
self
.
cutlass_fp8_supported
and
(
is_sm100_supported
()
or
is_sm90_supported
())
):
self
.
ab_strides1
=
torch
.
full
(
self
.
ab_strides1
=
torch
.
full
(
(
num_experts
,),
(
num_experts
,),
hidden_size
,
hidden_size
,
...
...
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