File tree Expand file tree Collapse file tree 4 files changed +13
-8
lines changed Expand file tree Collapse file tree 4 files changed +13
-8
lines changed Original file line number Diff line number Diff line change @@ -14,10 +14,10 @@ or with specific arguments
1414``` bash
1515git clone < git-repository>
1616docker image build \
17- -t pytorch-lightning:py3.8 \
18- -f dockers/conda /Dockerfile \
17+ -t pytorch-lightning:py3.8-pt1.6 \
18+ -f dockers/base-cuda /Dockerfile \
1919 --build-arg PYTHON_VERSION=3.8 \
20- --build-arg PYTORCH_VERSION=1.4 \
20+ --build-arg PYTORCH_VERSION=1.6 \
2121 .
2222```
2323
Original file line number Diff line number Diff line change @@ -35,7 +35,8 @@ SHELL ["/bin/bash", "-c"]
3535
3636ENV PATH="$PATH:/root/.local/bin"
3737
38- RUN apt-get update && apt-get install -y --no-install-recommends \
38+ RUN apt-get update -qq && \
39+ apt-get install -y --no-install-recommends \
3940 build-essential \
4041 cmake \
4142 git \
@@ -104,6 +105,7 @@ RUN \
104105 # Install remaining requirements
105106 pip install -r requirements-extra.txt --upgrade-strategy only-if-needed && \
106107 pip install -r requirements-test.txt --upgrade-strategy only-if-needed && \
108+ pip install --extra-index-url https://developer.download.nvidia.com/compute/redist nvidia-dali-cuda${CUDA_VERSION%%.*}0 && \
107109 rm requirements*
108110
109111RUN \
@@ -118,4 +120,4 @@ RUN \
118120 conda info && \
119121 pip list && \
120122 python -c "import sys; assert sys.version[:3] == '$PYTHON_VERSION', sys.version" && \
121- python -c "import torch; assert torch.__version__[:3] == '$PYTORCH_VERSION', torch.__version__"
123+ python -c "import torch; assert torch.__version__[:3] == '$PYTORCH_VERSION', torch.__version__"
Original file line number Diff line number Diff line change @@ -28,6 +28,7 @@ FROM nvidia/cuda:${CUDA_VERSION}-cudnn${CUDNN_VERSION}-devel-ubuntu18.04
2828
2929ARG PYTHON_VERSION=3.7
3030ARG PYTORCH_VERSION=1.6
31+ ARG CMAKE_VERSION=3.18.4
3132
3233SHELL ["/bin/bash" , "-c" ]
3334# https://techoverflow.net/2019/05/18/how-to-fix-configuring-tzdata-interactive-input-when-building-docker-images/
@@ -37,7 +38,7 @@ ENV TZ=Europe/Prague
3738ENV PATH="$PATH:/root/.local/bin"
3839ENV CUDA_TOOLKIT_ROOT_DIR="/usr/local/cuda"
3940
40- RUN apt-get update && \
41+ RUN apt-get update -qq && \
4142 apt-get install -y --no-install-recommends \
4243 build-essential \
4344 pkg-config \
9394
9495 # Install all requirements
9596 pip install -r requirements/devel.txt --upgrade-strategy only-if-needed --use-feature=2020-resolver && \
97+ pip install --extra-index-url https://developer.download.nvidia.com/compute/redist nvidia-dali-cuda${CUDA_VERSION%%.*}0 && \
9698 rm -rf requirements*
9799
98100RUN \
@@ -105,5 +107,6 @@ RUN \
105107 # Show what we have
106108 pip --version && \
107109 pip list && \
110+ python -c 'from nvidia.dali.pipeline import Pipeline' && \
108111 python -c "import sys; assert sys.version[:3] == '$PYTHON_VERSION', sys.version" && \
109- python -c "import torch; assert torch.__version__[:3] == '$PYTORCH_VERSION', torch.__version__"
112+ python -c "import torch; assert torch.__version__[:3] == '$PYTORCH_VERSION', torch.__version__"
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ ENV CONDA_ENV=lightning
3131# show system inforation
3232RUN lsb_release -a && cat /etc/*-release
3333
34- RUN apt-get update && \
34+ RUN apt-get update -qq && \
3535 apt-get install -y --no-install-recommends \
3636 build-essential \
3737 cmake \
You can’t perform that action at this time.
0 commit comments