Skip to content

Commit 5db0733

Browse files
committed
Add CPU dockerfile and prevent tensorflow-gpu being overwritten
1 parent 19327c1 commit 5db0733

File tree

2 files changed

+14
-3
lines changed

2 files changed

+14
-3
lines changed

Dockerfile.cpu

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
FROM tensorflow/tensorflow:1.12.0-py3
2+
3+
ENV LANG=C.UTF-8
4+
RUN apt-get update && mkdir /gpt-2
5+
ADD requirements.txt /gpt-2/requirements.txt
6+
RUN pip3 install -r /gpt-2/requirements.txt
7+
8+
WORKDIR /gpt-2
9+
ADD . /gpt-2
10+
11+
CMD ["sleep", "infinity"]

Dockerfile renamed to Dockerfile.gpu

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ ENV NVIDIA_VISIBLE_DEVICES=all \
1010
NVIDIA_REQUIRE_CUDA="cuda>=8.0" \
1111
LANG=C.UTF-8
1212

13-
RUN apt-get update && mkdir /gpt-2
14-
ADD requirements.txt /gpt-2/requirements.txt
15-
RUN pip3 install -r /gpt-2/requirements.txt
13+
RUN apt-get update && \
14+
mkdir /gpt-2 && \
15+
pip3 install fire==0.1.3 regex==2017.4.5
1616

1717
WORKDIR /gpt-2
1818
ADD . /gpt-2

0 commit comments

Comments
 (0)