NVIDIA-AI-IOT / torch2trt

An easy to use PyTorch to TensorRT converter
MIT License
4.56k stars 673 forks source link

Is that available on orin nano? #933

Open adrenalin7237 opened 3 months ago

adrenalin7237 commented 3 months ago

I have a jetson Orin Nano model. I've tried to install torch2trt in my jetson device using docker system. Here is my error log during installation.

root@ubuntu:/home/torch2trt# python3 setup.py install Traceback (most recent call last): File "setup.py", line 24, in plugins_ext_module = CUDAExtension( File "/usr/local/lib/python3.8/dist-packages/torch/utils/cpp_extension.py", line 1077, in CUDAExtension library_dirs += library_paths(cuda=True) File "/usr/local/lib/python3.8/dist-packages/torch/utils/cpp_extension.py", line 1204, in library_paths if (not os.path.exists(_join_cuda_home(lib_dir)) and File "/usr/local/lib/python3.8/dist-packages/torch/utils/cpp_extension.py", line 2419, in _join_cuda_home raise OSError('CUDA_HOME environment variable is not set. ' OSError: CUDA_HOME environment variable is not set. Please set it to your CUDA install root. root@ubuntu:/home/torch2trt#

Despite trying this, the installation still fails. can you help me? And is it possible that this module cannot be used in orin nano?

leeeenammmmm commented 1 month ago

I have the same problem! Looking forward to the answer

leeeenammmmm commented 1 month ago

Hi, I have fix this error. You can check torch.cuda.is_available(). In my situation it return false. So I reinstall torch in this link: https://forums.developer.nvidia.com/t/pytorch-for-jetson/72048. Check torch.cuda.is_available() again and if it return true, this error has fixed