[v1loader]Reduce EB300B model loading time (#3700)

* speed up eb45

* update
This commit is contained in:
bukejiyu
2025-09-02 19:13:57 +08:00
committed by GitHub
parent 693c7d781c
commit b6a4115369
4 changed files with 45 additions and 36 deletions

View File

@@ -160,6 +160,7 @@ def default_weight_loader(fd_config: FDConfig) -> None:
output_dim = getattr(param, "output_dim", None)
model_format = getattr(param, "model_format", "")
if model_format == "torch":
loaded_weight = get_tensor(loaded_weight)
loaded_weight = loaded_weight.transpose([1, 0])
# Tensor parallelism splits the weight along the output_dim
if output_dim is not None and fd_config.parallel_config.tensor_parallel_size > 1: