Unverified Commit aaa3092f authored by Jaewon's avatar Jaewon Committed by GitHub
Browse files

[MoE] Add routing simulation override for MXFP4 quantized MoE (#33595)


Signed-off-by: default avatarJaewon Lee <jaewon@meta.com>
parent 87985077
...@@ -1109,6 +1109,12 @@ class Mxfp4MoEMethod(FusedMoEMethodBase): ...@@ -1109,6 +1109,12 @@ class Mxfp4MoEMethod(FusedMoEMethodBase):
layer.eplb_state.logical_replica_count, layer.eplb_state.logical_replica_count,
), "MXFP4 are not supported with this configuration." ), "MXFP4 are not supported with this configuration."
# Apply routing simulation strategy if specified.
# This applies to all monolithic backends (SM100_FI and TRITON).
routing_strategy = envs.VLLM_MOE_ROUTING_SIMULATION_STRATEGY
if routing_strategy == "uniform_random":
router_logits = torch.rand_like(router_logits)
if ( if (
self.mxfp4_backend == Mxfp4Backend.SM100_FI_MXFP4_MXFP8_TRTLLM self.mxfp4_backend == Mxfp4Backend.SM100_FI_MXFP4_MXFP8_TRTLLM
or self.mxfp4_backend == Mxfp4Backend.SM100_FI_MXFP4_BF16 or self.mxfp4_backend == Mxfp4Backend.SM100_FI_MXFP4_BF16
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment