Skip to content

Commit 38cf553

Browse files
committed
fix distributed
test=develop
1 parent d5d0967 commit 38cf553

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

python/paddle/fluid/transpiler/distribute_transpiler.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1717,8 +1717,8 @@ def _get_lr_ops(self):
17171717
lr_ops = []
17181718
block = self.origin_program.global_block()
17191719
for op in block.ops:
1720-
if int(op.attr(RPC_OP_ROLE_ATTR_NAME)) == int(
1721-
LR_SCHED_OP_ROLE_ATTR_VALUE):
1720+
if int(op.attr(RPC_OP_ROLE_ATTR_NAME)) | int(
1721+
LR_SCHED_OP_ROLE_ATTR_VALUE) > 0:
17221722
lr_ops.append(op)
17231723
log("append lr op: ", op.type)
17241724
return lr_ops

0 commit comments

Comments
 (0)