After successfully installing JetPack6.1 on my Jetson agx orin using sdkmanger, I want to install pytorch on it.
So I first installed cusparselt following Installing PyTorch for Jetson Platform - NVIDIA Docs, and then created a virtual environment by
conda create -n pytorch python=3.10
Then I downloaded torch-2.5.0a0+872d972e41.nv24.08.17622132-cp310-cp310-linux_aarch64.whl from https://developer.download.nvidia.com/compute/redist/jp/v61/pytorch/.
And succefully run the pip install command.
pip install torch-2.5.0a0+872d972e41.nv24.08.17622132-cp310-cp310-linux_aarch64.whl
Then I tried to verify but failed.
It seems that pytorch can’t find a cuda device, what’s wrong?
Even stranger, the “NvRmMemInitNvmap failed with Permission denied” problem occurs everytime I try to create a new conda environment, though this problem doesn’t affect my environment creating.
Additionally, I also successfully installed tvm, but still failed to find the cuda device.
This may help your first question. add
/usr/local/cuda/bin to your path in .bashrc
and add this to the bottom of .bashrc
export CUDA_HOME=/usr/local/cuda
and looking at your first picture looks like you need to pip install numpy or however you do that with anaconda.
Thanks, but these content are already in my ~/.bashrc (and ~/.zshrc)
I try to switch to the root user and successfully find the cuda device!
But why? And how can I find the cuda device in other users?
[Update]I ran this command but still failed.
usermod -aG sudo,video,i2c "$USER"
I don’t know if this would cause a problem, but
the pytorch.whl you installed is for python 3.10,
your last picture shows python 3.9.20.
This doesn’t return True in python?
import torch; print(torch.cuda.is_available())
You could try installing or upgrading cuda with
conda install nvidia/label/cuda-12.6.2::cuda-toolkit
Might need to ask on Anaconda how to resolve it.
There is no update from you for a period, assuming this is not an issue anymore.
Hence, we are closing this topic. If need further support, please open a new one.
Thanks
Hi,
Could you run the same test to see if it works outside of the virtual environment?
Thanks.