1、查看pytorch版本 torch.__version__ 2、查看pytorch的cuda版本 torch.version.cuda 3、查看torch能否使用cuda torch.cuda.is_available()