[ 仅 API 调用方式不一致 ]torch.distributed.is_nccl_available

torch.distributed.is_nccl_available

torch.distributed.is_nccl_available()

paddle.core.is_compiled_with_nccl

paddle.core.is_compiled_with_nccl()

两者功能一致,但调用方式不一致,具体如下:

转写示例

# PyTorch 写法
result = torch.distributed.is_nccl_available()

# Paddle 写法
result = paddle.core.is_compiled_with_nccl()