Last active
April 26, 2018 00:09
-
-
Save alantian/d6ddf922b6e04796fb6f32726b6015df to your computer and use it in GitHub Desktop.
Dockerfile for running code built on some common deep learning frameworks.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| FROM nvidia/cuda:9.0-cudnn7-devel-ubuntu16.04 | |
| #------------------------------------------------------------------------------- | |
| ### Enable UTF8 in docker instance | |
| #------------------------------------------------------------------------------- | |
| RUN apt-get update -y && \ | |
| apt-get install -y locales && \ | |
| rm -rf /var/lib/apt/lists/* /var/cache/apt/archives/* | |
| RUN locale-gen en_US.UTF-8 | |
| ENV LANG='en_US.UTF-8' LANGUAGE='en_US:en' LC_ALL='en_US.UTF-8' | |
| #------------------------------------------------------------------------------- | |
| #------------------------------------------------------------------------------- | |
| ### System packages | |
| #------------------------------------------------------------------------------- | |
| RUN apt-get update -y && \ | |
| apt-get install -y coreutils python3 python3-pip && \ | |
| rm -rf /var/lib/apt/lists/* /var/cache/apt/archives/* | |
| #------------------------------------------------------------------------------- | |
| ### Deep Learning Packages | |
| #------------------------------------------------------------------------------- | |
| # Note that tf and pytorch here use CUDA 9.0, not 9.1. | |
| RUN pip3 install tensorflow-gpu==1.8.0rc0 | |
| RUN pip3 install keras==2.1.5 | |
| RUN pip3 install cupy-cuda90==4.0.0rc1 | |
| RUN pip3 install chainer==4.0.0rc1 | |
| RUN pip3 install http://download.pytorch.org/whl/cu90/torch-0.3.1-cp35-cp35m-linux_x86_64.whl | |
| RUN pip3 install torchvision | |
| # Misc | |
| RUN pip3 install python-gflags yapf flake8 absl-py Pillow tqdm h5py | |
| RUN pip3 install tensorflowjs --no-dependencies | |
| RUN pip3 install -U scikit-learn | |
| #------------------------------------------------------------------------------- |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment