Hi,
I’m trying to run the code here, but it doesn’t work. Specifically, I ran this code cell in a Jupyter notebook:
%matplotlib inline
import d2l
from mxnet import gluon, image, np, npx
import os
and I got the following error:
ImportError: cannot import name 'np'
I’m running the latest NVIDIA Docker image for MXNet. My Dockerfile is extremely simple:
FROM nvcr.io/nvidia/mxnet:19.10-py3
# omitted: proxy stuff
RUN apt-get update -y
RUN pip3 install git+https://github.com/d2l-ai/d2l-en@numpy2
# omitted: certificates stuff
# omitted: generate a password for Jupyter
WORKDIR /
EXPOSE 8888
CMD ["jupyter", "notebook", "--allow-root", "--ip=0.0.0.0"]
My enviroment:
Ubuntu 18.04.3 LTS
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2019 NVIDIA Corporation
Built on Sun_Jul_28_19:07:16_PDT_2019
Cuda compilation tools, release 10.1, V10.1.243
Python 3.6.8
Can you help me? Thanks