I have a code that I’m trying to run using Nvidia Jetson Orin Nano. The code runs, but it’s quite slow because it runs on the CPU. Therefore, I need to activate CUDA. First, I want to do this process on an Ubuntu computer with an Intel processor. For this reason, I want to use CUDA 12 or higher, supported by Jetpack 6 and above.
I need information on which versions of CUDA 12 and above are compatible with Torch, TorchAudio, and TorchVision. I tried with Torch 2.2 but was unsuccessful. When I check the version with nvcc --version, I see CUDA 12.2. Similarly, when I try the following Python code, it returns versions but says CUDA is not enabled:
Please inform me of the Torch and the necessary library versions compatible with any version of CUDA 12 or higher, working on Ubuntu 22.04 with x86_arm64 architecture.
Note: I have also downloaded these libraries via pip3 and conda (miniconda3), but the result hasn’t changed. When providing the versions, I kindly request you to share how I should download them and, if possible, terminal commands.
Best Regards,
Good Work!
import torch
# Check if CUDA is enabled
if torch.cuda.is_available():
print("CUDA is enabled.")
else:
print("CUDA is not enabled.")
# Print Torch and TorchVision versions
print("Torch version:", torch.__version__)
print("TorchVision version:", torch.__version__)
# Print TorchAudio version
import torchaudio
print("TorchAudio version:", torchaudio.__version__)
The environment looks good to us.
But the problem comes from the PyTorch/TorchVision/TorchAudio installation.
The package from pip3 only builds with CPU support.
You can surely build it from the source (like you try in the pdf) but it will be easier to install our prebuilt.
Yes, I was already using 8.9.1, which was coming as default, this is also seen in the previous screenshots, but when it did not work, when I downloaded cudnn for the system and cuda 12, 9.1.0 came up, thinking that maybe it would work, I downloaded it again, but this does not seem to solve my problem, because if it did, thousands of thousands of times above were downloaded. I think it would solve it if I tried it. Also, why can’t I see anything when I type nvdia-smi? Are my driver packages missing? If so, what should I download for the Jetson Orin Nano 8 GB Developer Kit?
Only CUDA has Jetson-compatible packages on the website.
For other libraries, please use the package from JetPack which can be found below (JetPack apt link): https://repo.download.nvidia.com/jetson/
Could you reset the system and install the PyTorch package shared above?
Different library versions might cause some unexpected compatibility issues.
Setting the environment with JetPack and installing our PyTorch is the way we recommended and verified.
Jetson is an iGPU system so the driver is integrated into the OS.
It doesn’t have a standalone GPU driver so it won’t show on the nvidia-smi.