fix strategy, test=develop (#27323)

* fix strategy, test=develop

* fix can_apply
cancel_disable_ut
mapingshuo 4 years ago committed by GitHub
parent c8e54c5e42
commit 9dedafa0df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -60,7 +60,7 @@ class StrategyCompiler(StrategyCompilerBase):
def _get_valid_strategy(self, dist_strategy, can_not_apply_optimizer_list):
import copy
valid_strategy = copy.copy(dist_strategy)
valid_strategy = copy.deepcopy(dist_strategy)
invalid_optimizers = []
for candidate in self._meta_optimizer_candidates:
is_valid = False

@ -38,7 +38,7 @@ class RecomputeOptimizer(MetaOptimizerBase):
list(user_defined_strategy.recompute_configs["checkpoints"]))
def _can_apply(self):
if self.role_maker._is_collective:
if not self.role_maker._is_collective:
return False
if self.user_defined_strategy.recompute == True:

Loading…
Cancel
Save