prl83
December 16, 2024, 8:50pm
1
I am running:
python 3.8.10
cuda 11.4.315
jetpack 5.1.4 [L4T 35.6.0]
No matter what pytorch version I use from: PyTorch for Jetson Platform - NVIDIA Docs (i.e. any with jetpack 5.1.x specified) I get:
ERROR: torch-2.1.0a0+41361538.nv23.06-cp38-cp38-linux_aarch64.whl is not a supported wheel on this platform.
In the pinned forum thread: PyTorch for Jetson , it does not give any specific instructions for 5.1.4
What can I try next? Downgrade jetpack? build from source?
Hi
The wheel is compatible with Jetpack 5.1.4.
Thanks
prl83
December 17, 2024, 2:51pm
5
That’s good to know, but I was looking more for guidance as to why I would get this error if it is compatible. I’ve installed this version of Pytorch on another Xavier AGX with 5.1.4, so I’m going to reinstall Jetpack on the offending unit and see if that helps.
Thanks
Hi,
Have you followed the guidance in this
I tested it on our end, and it worked successfully.
Thanks
prl83
December 18, 2024, 2:52pm
7
Yes, that is the guide I linked to in my first post. I reinstalled Jetpack 5.1.4 and was able to install PyTorch.
I had previously installed PyTorch with these steps from your jetson-inference repo: jetson-inference/docs/building-repo-2.md at master · dusty-nv/jetson-inference · GitHub . Are they still valid?
Yes, it is still valid.
However, you can review the code at this location to verify.
Currently, it supports torch-2.0
but does not support torch-2.1
when using JetPack 5.1.x. You can modify the source code to install torch-2.1
along with the corresponding version of torchvision
.
Thanks
1 Like
prl83
December 19, 2024, 11:08pm
9
For others future reference with AGX Xavier, and JetPack 5.1.4, these are the commands I used to install PyTorch:
$ sudo apt-get update -y && sudo apt-get upgrade -y
$ sudo apt-get install -y python3-pip libopenblas-dev;
$ export TORCH_INSTALL=https://developer.download.nvidia.com/compute/redist/jp/v512/pytorch/torch-2.1.0a0+41361538.nv23.06-cp38-cp38-linux_aarch64.whl
$ python3 -m pip install --upgrade pip; python3 -m pip install numpy==1.26.1; python3 -m pip install --no-cache $TORCH_INSTALL
Notes:
For whatever reason, I had to reflash Jetpack first with SDK manager
The version in the command says “512” but this did not cause problems. I do not know if “514” would work or not.
Later had to downgrade to numpy==1.23.1 for other software (older version of mmcv) to work. This did not seem to cause issues.
And torchvision:
$ sudo apt-get install libjpeg-dev zlib1g-dev libpython3-dev libopenblas-dev libavcodec-dev libavformat-dev libswscale-dev
$ git clone --branch release/0.16 https://github.com/pytorch/vision torchvision
$ cd torchvision/
$ export BUILD_VERSION=0.16.2
$ python3 setup.py install --user
1 Like
system
Closed
January 16, 2025, 4:52am
11
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.