cindybrain:

if args.local_rank == 0:
      top1, top5 = test(net, testloader, criterion, False)
torch.distributed.broadcast(torch.tensor(top1).cuda(args.local_rank),src=0, async_op=False)
print("local rank:{}, top1:{}".format(args.local_rank, top1))



Thanks for your reply! But it still doesn’t work