use self.hidden_size not use self.fd_config.model_config.hidden_size (#7340)

This commit is contained in:
周周周
2026-04-11 22:39:43 +08:00
committed by GitHub
parent 4982aa000e
commit 225fc8d222
2 changed files with 3 additions and 1 deletions
+1 -1
View File
@@ -788,7 +788,7 @@ class FusedMoE(nn.Layer):
chunk_size = self.fd_config.parallel_config.chunked_moe_size
token_num = x.shape[0]
fake_x = paddle.empty(
shape=[0, self.fd_config.model_config.hidden_size],
shape=[0, self.hidden_size],
dtype=paddle.get_default_dtype(),
)
# input size that are less than a chunk, less than the max size data or empty input
+2
View File
@@ -169,6 +169,8 @@ class TestChunkedMoE(unittest.TestCase):
fused_moe.fd_config = mock_fd_config
fused_moe.quant_method = MockQuantMethod()
fused_moe.enable_routing_replay = None
fused_moe.hidden_size = mock_fd_config.model_config.hidden_size
return fused_moe
def run_model_runner(self):