torch.cuda.isavailable() /usr/local/lib/python3.8/dist-packages/torch/cuda/init.py:107:…
- User
torch.cuda.is_available() /usr/local/lib/python3.8/dist-packages/torch/cuda/init.py:107: UserWarning: CUDA initialization: Unexpected error from cudaGetDeviceCount(). Did you run some cuda functions before calling NumCudaDevices() that might have already set an error? Error 803: system has unsupported display driver / cuda driver combination (Triggered internally at ../c10/cuda/CUDAFunctions.cpp:109.) return torch._C._cuda_getDeviceCount() > 0 False
- Assistant
The output suggests that CUDA is not available on the current system.
- User
cat /proc/driver/nvidia/version NVRM version: NVIDIA UNIX x86_64 Kernel Module 535.113.01 Tue Sep 12 19:41:24 UTC 2023 GCC version: gcc version 9.4.0 (Ubuntu 9.4.0-1ubuntu1~20.04.2) 适合什么cuda
- Assistant
Based on the NVIDIA driver version you provided (535.113.01), it appears that you have a newer driver installed. However, this version of the driver does not match any known CUDA versions.
To determine the compatible CUDA version, you can refer to the NVIDIA CUDA Toolkit Release Notes. The release notes will specify which CUDA version is compatible with the specific driver version you have installed.
You can find the release notes on the NVIDIA website by searching for "NVIDIA CUDA Toolkit Release Notes" along with your driver version.
- User
Traceback (most recent call last): File "", line 1, in AttributeError: module 'torch.cuda' has no attribute 'is_avaiable'
- Assistant
Apologies for the confusion earlier. It seems like there was a typo in the attribute name. The correct attribute name is
torch.cuda.is_available()(with a typo in your question). Here is the revised code:import torch print(torch.cuda.is_available())Please try running the code again with the corrected attribute name.
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.