Unable to import torch (ImportError: libcudart.so.10.0)
I'm currently working on a Nvidia Jetson Nano and I'm not very familiar with Linux. I am trying to run a python file which imports a package called torch. I have installed it alongside with  torchvision while following the instructions from NVIDIA here. 

When I run pip list on my terminal, I am able to see torch listed as one of the packages installed. However, I am unable to run the python file due to the error seen below. When I try to run it on python shell, the same error pops up.
FYI: Previously it had issues as the system was using python 2 by default but I have already fixed the path by switching to python 3 by editing the .bashrc file.

&gt;&gt;&gt; import torch
Traceback (most recent call last):
  File "&lt;stdin&gt;", line 1, in &lt;module&gt;
  File "/home/jiayi/.local/lib/python3.6/site-packages/torch/__init__.py", line 81, in &lt;module&gt;
    from torch._C import *
ImportError: libcudart.so.10.0: cannot open shared object file: No such file or directory


I have tried uninstalling and installing via pip but to no avail. When I try to install the pytorch package (following the instructions from a github repo here), an error occurs as seen below and it is due to the same issue. It is able to detect that the torch package is installed but there seems to be an internal issue.

Requirement already satisfied: torch==1.4.0 from file:///home/jiayi/jetson-inference/build/torch-1.4.0-cp36-cp36m-linux_aarch64.whl in /home/jiayi/.local/lib/python3.6/site-packages (1.4.0)
[jetson-inference]  cloning torchvision...
[sudo] password for jiayi: 
Cloning into 'torchvision-36'...
remote: Enumerating objects: 71, done.
remote: Counting objects: 100% (71/71), done.
remote: Compressing objects: 100% (56/56), done.
remote: Total 8219 (delta 37), reused 29 (delta 15), pack-reused 8148
Receiving objects: 100% (8219/8219), 10.22 MiB | 3.60 MiB/s, done.
Resolving deltas: 100% (5631/5631), done.
[jetson-inference]  building torchvision for Python 3.6...
Traceback (most recent call last):
  File "setup.py", line 14, in &lt;module&gt;
    import torch
  File "/home/jiayi/.local/lib/python3.6/site-packages/torch/__init__.py", line 81, in &lt;module&gt;
    from torch._C import *
ImportError: libcudart.so.10.0: cannot open shared object file: No such file or directory

[jetson-inference]  installation complete, exiting with status code 0
[jetson-inference]  to run this tool again, use the following commands:

    $ cd &lt;jetson-inference&gt;/build
    $ ./install-pytorch.sh


I meet the exact same problem. The problem seems to be cuda 10.2. Downgrading to 10.0 does not help either. Probably the solution is to manually install everything from Jetpack and making sure that the cuda version to be installed is 10.0.
