1
1
FROM lablup/common-base:py38-cuda11.1
2
2
3
+ RUN python3 -m pip install --no-cache-dir --upgrade \
4
+ -q git+https://github.com/google-research/tensorflow_constrained_optimization
5
+
6
+ RUN python3 -m pip install --no-cache-dir \
7
+ --use-feature=2020-resolver \
8
+ requests_oauthlib==1.2.0 \
9
+ neural-structured-learning==1.3.1 \
10
+ pydot==1.4.0 \
11
+ proto-plus==1.10.2
12
+ RUN python3 -m pip install --no-cache-dir \
13
+ --use-feature=2020-resolver \
14
+ tensorflow-transform==0.24.1 \
15
+ tensorflow_model_analysis \
16
+ tensorflow-datasets \
17
+ tensorflow_probability==0.11.1 \
18
+ tensorflow-addons==0.11.2 \
19
+ neural-structured-learning==1.3.1 \
20
+ tensorflow-model-optimization==0.5.0 \
21
+ tfx==0.24.1 \
22
+ tfx-bsl==0.24.1 \
23
+ tf-agents==0.6.0
24
+
3
25
RUN python3 -m pip install --no-cache-dir --extra-index-url \
4
26
https://developer.download.nvidia.com/compute/redist \
5
27
nvidia-dali-cuda100 && \
@@ -24,6 +46,11 @@ RUN python3 -m pip uninstall -y torch && \
24
46
25
47
RUN python3 -m pip install --no-cache-dir mxnet mkl
26
48
49
+ RUN python3 -m pip uninstall -y tensorflow && \
50
+ python3 -m pip install --no-cache-dir \
51
+ tensorflow-gpu==2.4.0 \
52
+ tensorboard==2.4.0
53
+
27
54
# Install Horovod, temporarily using CUDA stubs
28
55
RUN ldconfig /usr/local/cuda/targets/x86_64-linux/lib/stubs && \
29
56
HOROVOD_GPU_ALLREDUCE=NCCL HOROVOD_GPU_BROADCAST=NCCL \
@@ -39,10 +66,35 @@ RUN python3 -m pip install --no-cache-dir \
39
66
40
67
# install kaldi
41
68
WORKDIR /opt
42
- RUN apt update ; apt-get install -y sox subversion
43
- RUN git clone https://github.com/kaldi-asr/kaldi.git /opt/kaldi && \
44
- cd /opt/kaldi && \
45
- git checkout c013e2e && \
69
+ RUN apt update && \
70
+ apt list --upgradable && \
71
+ apt-get install -y --no-install-recommends \
72
+ patch wget rsync jq gnupg libtcmalloc-minimal4 && \
73
+ apt-get install -y --no-install-recommends \
74
+ automake \
75
+ autoconf \
76
+ flac \
77
+ gawk \
78
+ libatlas3-base \
79
+ libtool \
80
+ sox \
81
+ subversion \
82
+ unzip \
83
+ bc \
84
+ libatlas-base-dev \
85
+ gfortran \
86
+ zlib1g-dev && \
87
+ apt-get install -y --no-install-recommends \
88
+ git libglib2.0-0 less libnl-route-3-200 libnl-3-dev \
89
+ libnl-route-3-dev libnuma-dev libnuma1 \
90
+ libpmi2-0-dev nano numactl openssh-client vim && \
91
+ rm -rf /var/lib/apt/lists/*
92
+ RUN ln -sf /usr/include/x86_64-linux-gnu/atlas /usr/local/include/atlas && \
93
+ ln -sf /usr/include/x86_64-linux-gnu/cblas.h /usr/local/include/cblas.h && \
94
+ ln -sf /usr/include/x86_64-linux-gnu/clapack.h /usr/local/include/clapack.h && \
95
+ ln -sf /usr/lib/x86_64-linux-gnu/atlas /usr/local/lib/atlas
96
+
97
+ RUN git clone https://github.com/hephaex/kaldi.git /opt/kaldi && \
46
98
cd /opt/kaldi/tools && \
47
99
make -j $(nproc) && \
48
100
cd /opt/kaldi/src && \
@@ -51,12 +103,24 @@ RUN git clone https://github.com/kaldi-asr/kaldi.git /opt/kaldi && \
51
103
--mathlib=ATLAS \
52
104
--cuda-arch="-gencode arch=compute_52,code=sm_52 -gencode arch=compute_60,code=sm_60 -gencode arch=compute_61,code=sm_61 -gencode arch=compute_70,code=sm_70 -gencode arch=compute_75,code=sm_75 -gencode arch=compute_80,code=sm_80" && \
53
105
make depend -j $(nproc) && \
54
- make -j $(nproc) -lcuda -L /usr/local/cuda/lib64/stubs && \
55
- make -j $(nproc) ext -lcuda -L /usr/local/cuda/lib64/stubs && \
106
+ make -j $(nproc)
107
+ RUN cd /opt/kaldi/src && \
108
+ make ext -j $(nproc) && \
56
109
ldconfig && \
57
- find /opt/kaldi -type f \( -name "*.o" -o -name "*.la" -o -name "*.a" \) -exec rm {} \; && \
110
+ find /opt/kaldi -type f \( -name "*.o" -o -name "*.la" -o -name "*.a" \) -\
111
+ exec rm {} \; && \
58
112
rm -rf /opt/kaldi/.git
59
113
114
+ RUN mkdir -p /workspace && \
115
+ chmod -R 777 /workspace
116
+
117
+ RUN apt autoclean && \
118
+ sed -i 's/source \/ usr\/ local\/ nvm\/ nvm.sh//' /etc/bash.bashrc && \
119
+ python3 -m pip uninstall -y tensorboard-plugin-wit && \
120
+ rm -rf /var/lib/apt/lists/* && \
121
+ rm -rf /root/.cache && \
122
+ rm -rf /tmp/*
123
+
60
124
# Install ipython kernelspec
61
125
Run python3 -m ipykernel install --display-name "Lablup FF 21.01 on Python 3.8 (CUDA 11.1)" && \
62
126
cat /usr/local/share/jupyter/kernels/python3/kernel.json
0 commit comments