NVIDIA / apex

A PyTorch Extension: Tools for easy mixed precision and distributed training in Pytorch
BSD 3-Clause "New" or "Revised" License
8.16k stars 1.35k forks source link

Skip the p2p test on single GPU platforms #1775

Closed nWEIdia closed 4 months ago

nWEIdia commented 4 months ago

This PR fixes the errors that would show up if the test_bottleneck_module.py is run on a single GPU platform, where running torch.cuda.can_device_access_peer(0,1) would produce "invalid peer device id".