如何在kaggle_python docker镜像中使用GPU

时间:2018-06-02 13:18:54

标签: python docker tensorflow kaggle

我从本教程安装了kaggle_python docker image: precedence 这个图像很完美,但我不知道如何在其中使用GPU。有谁有任何想法?

2 个答案:

答案 0 :(得分:0)

Nvidia发布了一个docker运行时,允许docker容器访问其主机GPU。假设您运行的图像内置了CUDA库,您应该能够install nvidia-docker as per their instructions,然后使用docker run --runtime=nvidia ...启动容器

如果您遇到其他障碍,请

There's an FAQ for using nvidia-dockers。我自己没有这样做,但很多问题可能都与你在特定机器上安装驱动程序和cuda库的方式有关。您可能还必须modify the image包含任何必要的CUDA库(如果尚未安装)。

答案 1 :(得分:0)

Did you download the CUDA branch (link: https://github.com/Kaggle/docker-python/tree/cuda)? If so, all the infrastructure for the GPUs should already be set up and ready to go. Otherwise, you're going to have to do the setup yourself. :)