Found no NVIDIA driver on your system
参考文章
解决方法:
docker run -it --gpus=all -e NVIDIA_DRIVER_CAPABILITIES=compute,utility -e NVIDIA_VISIBLE_DEVICES=all your_image:version /bin/bash
Docker里安装anaconda
直接贴Dockerfile
FROM your_base_image:version
LABEL maintainer="your_name" description="your_description" version="1.0"
WORKDIR /usr/local/bin
COPY Anaconda3-2019.10-Linux-x86_64.sh Anaconda3-2019.10-Linux-x86_64.sh
RUN bash Anaconda3-2019.10-Linux-x86_64.sh -b && \
echo "export PATH="/root/anaconda3/bin:$PATH"" >> ~/.bashrc && \
/bin/bash -c "source ~/.bashrc"
# 最重要的部分在这里!如果不加环境变量,会出现conda command not found的情况
ENV PATH /root/anaconda3/bin:$PATH