Automatically configure for EPLB-related args (#6628)
This commit is contained in:
@@ -366,12 +366,28 @@ class ServerArgs:
|
|||||||
"Pipeline parallelism is incompatible with overlap schedule."
|
"Pipeline parallelism is incompatible with overlap schedule."
|
||||||
)
|
)
|
||||||
|
|
||||||
|
if self.enable_eplb and (self.expert_distribution_recorder_mode is None):
|
||||||
|
self.expert_distribution_recorder_mode = "stat"
|
||||||
|
logger.info(
|
||||||
|
f"EPLB is enabled. The expert_distribution_recorder_mode is automatically set."
|
||||||
|
)
|
||||||
|
|
||||||
|
if (self.enable_eplb or (self.init_expert_location is not None)) and (
|
||||||
|
self.ep_dispatch_algorithm is None
|
||||||
|
):
|
||||||
|
self.ep_dispatch_algorithm = "static"
|
||||||
|
logger.info(
|
||||||
|
f"EPLB is enabled or init_expert_location is provided. ep_dispatch_algorithm is configured."
|
||||||
|
)
|
||||||
|
|
||||||
|
if self.enable_expert_distribution_metrics and (
|
||||||
|
self.expert_distribution_recorder_mode is None
|
||||||
|
):
|
||||||
|
self.expert_distribution_recorder_mode = "stat"
|
||||||
|
|
||||||
if self.expert_distribution_recorder_buffer_size is None:
|
if self.expert_distribution_recorder_buffer_size is None:
|
||||||
# TODO pr-chain: enable this later
|
if (x := self.eplb_rebalance_num_iterations) is not None:
|
||||||
# if (x := self.eplb_rebalance_num_iterations) is not None:
|
self.expert_distribution_recorder_buffer_size = x
|
||||||
# self.expert_distribution_recorder_buffer_size = x
|
|
||||||
if False:
|
|
||||||
pass
|
|
||||||
elif self.expert_distribution_recorder_mode is not None:
|
elif self.expert_distribution_recorder_mode is not None:
|
||||||
self.expert_distribution_recorder_buffer_size = 1000
|
self.expert_distribution_recorder_buffer_size = 1000
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user