Pytorch with CUDA for Jetpack 5.1.4

I have JetPack 5.1.4 on my Jetson Orin Nano. I have installed CUDA 12.1 and Python 3.9.
I followed the Pytorch website and used the command listed after selecting CUDA 12.1. However, when I tried to use a YOLOv11 model to run inference over a video, I got an error saying: Torch not compiled with CUDA enabled.
I found a couple NVIDIA links such as Pytorch for Jetson and Installing Pytorch for Jetson Platform. However, I cannot figure out which one is correct for JetPack 5.1.4 and CUDA 12.1.
Is there a combination available for my configuration? Or do I have to change the CUDA version and use Python3.8?

Hi,

We provide PyTorch prebuilt with the default Python version.

For example,
JetPack 5+Python 3.8+CUDA 11.4: PyTorch for Jetson
JetPack 6.1+Python 3.10+CUDA 12.6: jp6/cu126 index

Do these environments meet your requirements?
We also have a tutorial guiding users to set up a device for YOLOv11:
https://elinux.org/Jetson/L4T/TRT_Customized_Example#YoloV11_using_Pytorch

Thanks.

Hello,
Thank you so much for your help. The tutorial for YOLOv11 worked flawlessly.
If I need to downgrade to JetPack 6.0, is there a similar tutorial available for that configuration?

Hi,

The steps are similar but please pick up the package from the below link instead:

https://pypi.jetson-ai-lab.dev/jp6/cu122

Thanks.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.