torch.xpu.device_count#
- torch.xpu.device_count()[source]#
Return the number of XPU device available.
Note
This API will NOT poison fork if Level Zero Sysman discovery succeeds. See Poison fork in multiprocessing for more details.
- Return type:
Return the number of XPU device available.
Note
This API will NOT poison fork if Level Zero Sysman discovery succeeds. See Poison fork in multiprocessing for more details.