Pytorch install failed

I have a xavier nx running a freshly installed ver of Jetpack 5.02
I went to the zoo
I followed instructions and cloned torch2trt.
after cloning i try to follow the next step to setup:

python install

Traceback (most recent call last):
File “”, line 3, in
import torch
ModuleNotFoundError: No module named ‘torch’

I also wasted several hours and try to create a virtual env. and pip install
but that failed miserably

Please help

Hi @rick.minicucci, which PyTorch wheel did you install? If you pick one for JetPack 5 from this thread or from here, those should be good to use.

Thanks for the quick response. I have a question:
The first link you sent is for PyTorch v1.12.0 and I cant see what version of CUDA it was built for
The second link is from and it has an interactive downloader. The version is 1.13.0 and its available via pip venv which i would like to use and has choice for CUDA 11.6 or 11.7

What is the better choice to use for the tutorials and demos available for my Jetson Xavier NX?
I have the latest Jetpack Installed. JetPack 5.0.2 (L4T R35.1.0)


These are our prebuilt for the Jetson users.
So the package for JetPack 5.0.2 is built with CUDA 11.4 rather than 11.6 or 11.7.


So the site only has versions built for CUDA 11.6,11.3,11.2
Will any of these work?

  1. do the CUDA versions have to match?
  2. does a higher CUDA version support earlier, i.e. If i download the Pytorch vers. built with 11.3 will it work with the Jetpack 5.0.2 that was built with 11.4?

Hi @rick.minicucci, those binaries from aren’t for Jetson / aarch64. Please use one of the wheels from my links above for installing PyTorch into JetPack.

Thanks, that worked.

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