Unverified Commit 6e97eccf authored by Frost Mitchell's avatar Frost Mitchell Committed by GitHub
Browse files

[XPU] Enable custom routing functions in IPEX for Llama4 (#28004)


Signed-off-by: default avatarfrost-intel <frost.mitchell@intel.com>
parent 6ab18381
...@@ -915,7 +915,6 @@ class UnquantizedFusedMoEMethod(FusedMoEMethodBase, CustomOp): ...@@ -915,7 +915,6 @@ class UnquantizedFusedMoEMethod(FusedMoEMethodBase, CustomOp):
or logical_replica_count is not None or logical_replica_count is not None
): ):
raise NotImplementedError("Expert load balancing is not supported for XPU.") raise NotImplementedError("Expert load balancing is not supported for XPU.")
assert custom_routing_function is None
return layer.ipex_fusion( return layer.ipex_fusion(
x, x,
use_grouped_topk, use_grouped_topk,
...@@ -924,6 +923,7 @@ class UnquantizedFusedMoEMethod(FusedMoEMethodBase, CustomOp): ...@@ -924,6 +923,7 @@ class UnquantizedFusedMoEMethod(FusedMoEMethodBase, CustomOp):
renormalize, renormalize,
topk_group, topk_group,
num_expert_group, num_expert_group,
custom_routing_function=custom_routing_function,
) )
def forward_tpu( def forward_tpu(
......
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