diff --git a/tests/model_executor/model_loader/test_ep_weight_filter.py b/tests/model_executor/model_loader/test_ep_weight_filter.py index 2ac38192a4..0ff53d24e7 100644 --- a/tests/model_executor/model_loader/test_ep_weight_filter.py +++ b/tests/model_executor/model_loader/test_ep_weight_filter.py @@ -185,6 +185,21 @@ class TestShouldSkipWeight: "model.layers.0.mlp.experts.200.gate_proj.weight", self.local_ids ) + def test_local_packed_expert_not_skipped(self): + assert not should_skip_weight( + "model.layers.0.mlp.experts.10.gate_proj.weight_packed", self.local_ids + ) + + def test_remote_packed_expert_skipped(self): + assert should_skip_weight( + "model.layers.0.mlp.experts.200.gate_proj.weight_packed", self.local_ids + ) + + def test_remote_expert_scale_not_skipped(self): + assert not should_skip_weight( + "model.layers.0.mlp.experts.200.gate_proj.weight_scale", self.local_ids + ) + def test_boundary_expert(self): # Expert 47 is local (last one), 48 is not assert not should_skip_weight( diff --git a/vllm/model_executor/model_loader/ep_weight_filter.py b/vllm/model_executor/model_loader/ep_weight_filter.py index 48bfacc6ee..e9152f2cdb 100644 --- a/vllm/model_executor/model_loader/ep_weight_filter.py +++ b/vllm/model_executor/model_loader/ep_weight_filter.py @@ -76,6 +76,6 @@ def should_skip_weight( # Only skip heavy weight tensors, never scale/metadata tensors. # Scale tensors are tiny and some backends need them from ALL experts # (e.g. FlashInfer NVFP4 computes a global max of activation scales). - if not weight_name.endswith(".weight"): + if not weight_name.endswith((".weight", ".weight_packed")): return False return eid not in local_expert_ids