Hello, I’m geting following error when installing PyTorch using L4T Docker image on Jetson Nano. Here is the Dockerfile. Can you please look into it? Thanks
FROM nvcr.io/nvidia/l4t-base:r32.3.1
ENV DEBIAN_FRONTEND noninteractive
RUN apt-get update && apt-get install -y \
python3-opencv ca-certificates python3-dev git wget sudo python-setuptools && \
rm -rf /var/lib/apt/lists/*
ENV PATH="/home/appuser/.local/bin:${PATH}"
RUN wget https://bootstrap.pypa.io/get-pip.py && \
python3 get-pip.py && \
rm get-pip.py
RUN wget https://nvidia.box.com/shared/static/phqe92v26cbhqjohwtvxorrwnmrnfx1o.whl -O torch-1.3.0-cp36-cp36m-linux_aarch64.whl
RUN pip3 install numpy torch-1.3.0-cp36-cp36m-linux_aarch64.whl
After that if I do
docker build -t jetson-pytorch:latest .
docker run -it jetson-pytorch:latest bash
root@21592ebf82b0:/# python3
Python 3.6.9 (default, Nov 7 2019, 10:44:02)
[GCC 8.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python3.6/dist-packages/torch/__init__.py", line 81, in <module>
from torch._C import *
ImportError: libnvToolsExt.so.1: cannot open shared object file: No such file or directory
>>> exit()
root@21592ebf82b0:/# exit
exit
Hi,
libnvToolsExt.so.1 is located at /usr/local/cuda-10.0/targets/aarch64-linux/lib/.
Could you try to export the path to LD_LIBRARY_PATH and try it again?
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda-10.0/targets/aarch64-linux/lib/
Thanks.
Thanks for the response. Its not there.
root@69f5ee8f643e:/# printenv | grep LD_
LD_LIBRARY_PATH=/usr/local/cuda-10.0/lib64:/usr/local/cuda-10.0/targets/aarch64-linux/lib:
root@69f5ee8f643e:/# ls /usr/local/cuda-10.0/targets/aarch64-linux/lib/
libcudadevrt.a libcudart_static.a stubs
Actually was able to figure it out but getting this now.
jetson-nano:$ docker run -it --rm --net=host --runtime nvidia -e DISPLAY=$DISPLAY -v /tmp/.X11-unix/:/tmp/.X11-unix jetson-pytorch:latest bash
root@jetson-nano:/# python3
Python 3.6.9 (default, Nov 7 2019, 10:44:02)
[GCC 8.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python3.6/dist-packages/torch/__init__.py", line 81, in <module>
from torch._C import *
ModuleNotFoundError: No module named 'numpy.core._multiarray_umath'
>>> exit()
Hi,
ModuleNotFoundError: No module named 'numpy.core._multiarray_umath'
This is related to the installed numpy version.
Could you check if this command helps?
RUN pip install --upgrade numpy
Thanks.