Hi there.
I’ve been following some documentation online to install PyTorch on my Jetson Orin Nano (henceforth Jetson).
Setup
Upon getting the Jetson, I followed the setup guide here. Upon entering BIOS, I noted the versions in the top left was 36.4.3. I then installed and imaged JetPack 6.2 just as the guide mentioned, and everything seemed to be in order as it booted properly.
PyTorch
After doing some coding work on the Jetson, I needed to actually figure out how to work with an AI model.
I’ve been following the steps listed here, and I’ve run into some issues. Step 2.3 has some broken syntax (wget on a different line, etc.), but when I execute bash ./install_cusparselt.sh
I error out. Restarting this process, thinknig I did something wrong, I removed the installed files (via rm -rf install_cusparselt.sh
and rm -rf tmp_cusparselt/
) and went line by line:
cd ~
wget ...
works just fine when fixedexport CUDA_VERSION=...
I honestly don’t even know if I have CUDA installed, if that came with the image, or what.bash ./install...
returns:
+ mkdir tmp_cusparselt
+ cd tmp_cusparselt
+ [[ 12.1 =~ ^12\.[1-4]$ ]]
+ arch_path=sbsa
++ uname -m
+ export TARGETARCH=aarch64
+ TARGETARCH=aarch64
+ '[' aarch64 = amd64 ']'
+ '[' aarch64 = x86_64 ']'
+ CUSPARSELT_NAME=libcusparse_lt-linux-sbsa-0.5.2.1-archive
+ curl --retry 3 -OLs https://developer.download.nvidia.com/compute/cusparselt/redist/libcusparse_lt/linux-sbsa/libcusparse_lt-linux-sbsa-0.5.2.1-archive.tar.xz
+ tar xf libcusparse_lt-linux-sbsa-0.5.2.1-archive.tar.xz
+ cp -a libcusparse_lt-linux-sbsa-0.5.2.1-archive/include/cusparseLt.h /usr/local/cuda/include/
cp: cannot create regular file '/usr/local/cuda/include/cusparseLt.h': Permission denied
- Thinking this was strange, removed the files again and ran 1-3 but then ran
sudo bash ./install...
but this just returned
+ mkdir tmp_cusparselt
+ cd tmp_cusparselt
+ [[ '' =~ ^12\.[1-4]$ ]]
+ [[ '' == \1\1\.\8 ]]
+ tar xf .tar.xz
tar: .tar.xz: Cannot open: No such file or directory
tar: Error is not recoverable: exiting now
I’ve even tried abandoning this method and going to installing a specific version of PyTorch (same guide, just further down in Next, install PyTorch with the following steps) where I used
export JP_VERSION= 621
export PYT_VERSION= 2.8.0a0+5228986c39
export TORCH_INSTALL=https://developer.download.nvidia.com/compute/redist/jp/v$JP_VERSION/pytorch/$PYT_VERSION
where the versions were confirmed for JP_VERSION here and the PYT_VERSION here. I also tried directly installing the wheel from a forum from 2019 (which I can’t link anymore links since I’m a new user, but just search up “PyTorch for Jetson” and its the first result) which covered JetPack 6.
Honestly I’m just stuck as to what I’m doing wrong with this whole thing, and would greatly appreciate some guidance. I’ve asked a couple of AIs but they’re not much help.
Thanks!