Latest commit 3f6cc9d Dec 6, 2016 @pineking pineking committed with piiswrong Add CUDA 7.5 and 8.0 Dockerfiles (#4114)
* Add CUDA 7.5 and 8.0 Dockerfiles

* Use ~/mxnet as the workdir, set PYTHONPATH in dockerfile

Docker images for MXNET

Pre-built docker images are available at

How to use

  1. First pull the pre-built image

    docker pull dmlc/mxnet
  2. Then we can run the python shell in the docker

    docker run -ti dmlc/mxnet python

    For example

    $ docker run -ti dmlc/mxnet python
    Python 2.7.6 (default, Jun 22 2015, 17:58:13)
    [GCC 4.8.2] on linux2
    Type "help", "copyright", "credits" or "license" for more information.
    >>> import mxnet as mx
    import mxnet as mx
    >>> quit()

    Note: One may get the error message libdc1394 error: Failed to initialize libdc1394, which is due to opencv and can be ignored.

  3. Train a model on MNIST to check everything works

    docker run dmlc/mxnet python /mxnet/example/image-classification/

If the host machine has Nvidia GPUs, we can use dmlc/mxnet:cuda, which has both CUDA and CUDNN installed. To launch the docker, we need to install nvidia-docker first.

  1. Pull the image

    docker pull dmlc/mxnet:cuda
  2. Train MNIST on GPU 0

    nvidia-docker run dmlc/mxnet:cuda python /mxnet/example/image-classification/ --gpus 0

How to build

docker build -t dmlc/mxnet:cpu cpu
docker build -t dmlc/mxnet:cuda cuda