Skip to content

Commit 2fd1a23

Browse files
authored
[TRTLLM-9998][fix] Change trtllm-gen MoE distributed tuning strategy back to INDEPENDENT (#10036)
Signed-off-by: Yukun He <[email protected]>
1 parent 5d71f66 commit 2fd1a23

File tree

1 file changed

+14
-27
lines changed

1 file changed

+14
-27
lines changed

tensorrt_llm/_torch/custom_ops/trtllm_gen_custom_ops.py

Lines changed: 14 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,8 @@
1111
last_positive_power_of_2,
1212
next_positive_power_of_2)
1313

14-
from ..autotuner import (AutoTuner, ConstraintSpec, DistributedTuningStrategy,
15-
DynamicTensorSpec, OptimizationProfile, TunableRunner,
16-
TuningConfig)
14+
from ..autotuner import (AutoTuner, ConstraintSpec, DynamicTensorSpec,
15+
OptimizationProfile, TunableRunner, TuningConfig)
1716

1817

1918
def prepare_dummy_topk_and_hook(
@@ -346,10 +345,8 @@ def get_tuning_config(cls) -> TuningConfig:
346345
dynamic_tensor_specs = cls.get_dynamic_tensor_specs()
347346
constraint_specs = cls.get_constraint_specs()
348347

349-
tuning_config = TuningConfig(
350-
dynamic_tensor_specs=dynamic_tensor_specs,
351-
constraint_specs=constraint_specs,
352-
distributed_tuning_strategy=DistributedTuningStrategy.PARALLEL)
348+
tuning_config = TuningConfig(dynamic_tensor_specs=dynamic_tensor_specs,
349+
constraint_specs=constraint_specs)
353350

354351
return tuning_config
355352

@@ -670,10 +667,8 @@ def get_tuning_config(cls) -> TuningConfig:
670667
dynamic_tensor_specs = cls.get_dynamic_tensor_specs()
671668
constraint_specs = cls.get_constraint_specs()
672669

673-
tuning_config = TuningConfig(
674-
dynamic_tensor_specs=dynamic_tensor_specs,
675-
constraint_specs=constraint_specs,
676-
distributed_tuning_strategy=DistributedTuningStrategy.PARALLEL)
670+
tuning_config = TuningConfig(dynamic_tensor_specs=dynamic_tensor_specs,
671+
constraint_specs=constraint_specs)
677672

678673
return tuning_config
679674

@@ -971,10 +966,8 @@ def get_tuning_config(cls) -> TuningConfig:
971966
dynamic_tensor_specs = cls.get_dynamic_tensor_specs()
972967
constraint_specs = cls.get_constraint_specs()
973968

974-
tuning_config = TuningConfig(
975-
dynamic_tensor_specs=dynamic_tensor_specs,
976-
constraint_specs=constraint_specs,
977-
distributed_tuning_strategy=DistributedTuningStrategy.PARALLEL)
969+
tuning_config = TuningConfig(dynamic_tensor_specs=dynamic_tensor_specs,
970+
constraint_specs=constraint_specs)
978971

979972
return tuning_config
980973

@@ -1244,10 +1237,8 @@ def get_tuning_config(cls) -> TuningConfig:
12441237
dynamic_tensor_specs = cls.get_dynamic_tensor_specs()
12451238
constraint_specs = cls.get_constraint_specs()
12461239

1247-
tuning_config = TuningConfig(
1248-
dynamic_tensor_specs=dynamic_tensor_specs,
1249-
constraint_specs=constraint_specs,
1250-
distributed_tuning_strategy=DistributedTuningStrategy.PARALLEL)
1240+
tuning_config = TuningConfig(dynamic_tensor_specs=dynamic_tensor_specs,
1241+
constraint_specs=constraint_specs)
12511242

12521243
return tuning_config
12531244

@@ -1515,10 +1506,8 @@ def get_tuning_config(cls) -> TuningConfig:
15151506
dynamic_tensor_specs = cls.get_dynamic_tensor_specs()
15161507
constraint_specs = cls.get_constraint_specs()
15171508

1518-
tuning_config = TuningConfig(
1519-
dynamic_tensor_specs=dynamic_tensor_specs,
1520-
constraint_specs=constraint_specs,
1521-
distributed_tuning_strategy=DistributedTuningStrategy.PARALLEL)
1509+
tuning_config = TuningConfig(dynamic_tensor_specs=dynamic_tensor_specs,
1510+
constraint_specs=constraint_specs)
15221511

15231512
return tuning_config
15241513

@@ -1775,10 +1764,8 @@ def get_tuning_config(cls) -> TuningConfig:
17751764
dynamic_tensor_specs = cls.get_dynamic_tensor_specs()
17761765
constraint_specs = cls.get_constraint_specs()
17771766

1778-
tuning_config = TuningConfig(
1779-
dynamic_tensor_specs=dynamic_tensor_specs,
1780-
constraint_specs=constraint_specs,
1781-
distributed_tuning_strategy=DistributedTuningStrategy.PARALLEL)
1767+
tuning_config = TuningConfig(dynamic_tensor_specs=dynamic_tensor_specs,
1768+
constraint_specs=constraint_specs)
17821769

17831770
return tuning_config
17841771

0 commit comments

Comments
 (0)