Skip to content

Commit d176b7d

Browse files
committed
del wait in sharding for npu
1 parent 911c859 commit d176b7d

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

python/paddle/distributed/fleet/meta_optimizers/sharding_optimizer.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -379,8 +379,9 @@ def minimize_impl(self,
379379
'w') as f:
380380
f.writelines(str(main_block.program))
381381

382-
# GPU and NPU need to wait server ready
383-
self._wait()
382+
# GPU need to wait server ready, GPU and NPU is Layered connection
383+
if not core.is_compiled_with_npu():
384+
self._wait()
384385
return optimize_ops, params_grads
385386

386387
def _init_pair_comm(self, pair, ring_id):

0 commit comments

Comments
 (0)