diff --git a/python/paddle/fleet/base/distributed_strategy.py b/python/paddle/fleet/base/distributed_strategy.py index c72e3ca160dafc0ad2f166bca826f689a100a92d..0ebaff3a0f70c734b97b1da509fdaa0b080c5e3f 100644 --- a/python/paddle/fleet/base/distributed_strategy.py +++ b/python/paddle/fleet/base/distributed_strategy.py @@ -374,17 +374,6 @@ class DistributedStrategy(object): else: print("WARNING: sync should have value of bool type") - @property - def async(self): - return self.strategy.async - - @async.setter - def async(self, flag): - if isinstance(flag, bool): - self.strategy.async = flag - else: - print("WARNING: async should have value of bool type") - @property def async_k_step(self): return self.strategy.async_k_step diff --git a/python/paddle/fluid/tests/unittests/test_fleet_distributed_strategy.py b/python/paddle/fluid/tests/unittests/test_fleet_distributed_strategy.py index 3ec220d841d98e41e7fdaaf3d3342389aebdf919..0668546a703bc00369d55e12d4b03c934c9315c2 100644 --- a/python/paddle/fluid/tests/unittests/test_fleet_distributed_strategy.py +++ b/python/paddle/fluid/tests/unittests/test_fleet_distributed_strategy.py @@ -247,15 +247,6 @@ class TestStrategyConfig(unittest.TestCase): strategy.sync = "True" self.assertEqual(strategy.sync, False) - def test_async(self): - strategy = paddle.fleet.DistributedStrategy() - strategy.async = True - self.assertEqual(strategy.async, True) - strategy.async = False - self.assertEqual(strategy.async, False) - strategy.async = "True" - self.assertEqual(strategy.async, False) - def test_async_k_step(self): strategy = paddle.fleet.DistributedStrategy() strategy.async_k_step = 10000