Skip to content

Commit a2e7ba3

Browse files
mdoulatydanpovey
authored andcommitted
[build] Initial version of Docker images for (CPU and GPU versions) (kaldi-asr#3322)
1 parent 35f96db commit a2e7ba3

File tree

3 files changed

+91
-0
lines changed

3 files changed

+91
-0
lines changed

docker/README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Kaldi Docker Images
2+
3+
Sample usage of the CPU based images:
4+
```
5+
docker run -it mdoulaty/kaldi:latest bash
6+
```
7+
8+
Sample usage of the GPU based images:
9+
10+
Note: use [nvidia-docker](https://github.com/NVIDIA/nvidia-docker) to run the GPU images.
11+
12+
```
13+
docker run -it --runtime=nvidia mdoulaty/kaldi:gpu-latest bash
14+
```

docker/debian9.8-cpu/Dockerfile

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
2+
FROM debian:9.8
3+
LABEL maintainer="mdoulaty@gmail.com"
4+
5+
RUN apt-get update && \
6+
apt-get install -y --no-install-recommends \
7+
g++ \
8+
make \
9+
automake \
10+
autoconf \
11+
bzip2 \
12+
unzip \
13+
wget \
14+
sox \
15+
libtool \
16+
git \
17+
subversion \
18+
python2.7 \
19+
python3 \
20+
zlib1g-dev \
21+
ca-certificates \
22+
patch \
23+
vim && \
24+
rm -rf /var/lib/apt/lists/*
25+
26+
RUN ln -s /usr/bin/python2.7 /usr/bin/python
27+
28+
RUN git clone https://github.com/kaldi-asr/kaldi.git /opt/kaldi && \
29+
cd /opt/kaldi && \
30+
cd /opt/kaldi/tools && \
31+
./extras/install_mkl.sh && \
32+
make -j $(nproc) && \
33+
cd /opt/kaldi/src && \
34+
./configure --shared && \
35+
make depend -j $(nproc) && \
36+
make -j $(nproc)
37+
38+
WORKDIR /opt/kaldi/
39+

docker/ubuntu16.04-gpu/Dockerfile

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
2+
FROM nvidia/cuda:10.0-cudnn7-devel-ubuntu16.04
3+
LABEL maintainer="mdoulaty@gmail.com"
4+
5+
RUN apt-get update && \
6+
apt-get install -y --no-install-recommends \
7+
g++ \
8+
make \
9+
automake \
10+
autoconf \
11+
bzip2 \
12+
unzip \
13+
wget \
14+
sox \
15+
libtool \
16+
git \
17+
subversion \
18+
python2.7 \
19+
python3 \
20+
zlib1g-dev \
21+
ca-certificates \
22+
patch \
23+
vim && \
24+
rm -rf /var/lib/apt/lists/*
25+
26+
RUN ln -s /usr/bin/python2.7 /usr/bin/python
27+
28+
RUN git clone https://github.com/kaldi-asr/kaldi.git /opt/kaldi && \
29+
cd /opt/kaldi && \
30+
cd /opt/kaldi/tools && \
31+
./extras/install_mkl.sh && \
32+
make -j $(nproc) && \
33+
cd /opt/kaldi/src && \
34+
./configure --shared --use-cuda && \
35+
make depend -j $(nproc) && \
36+
make -j $(nproc)
37+
38+
WORKDIR /opt/kaldi/

0 commit comments

Comments
 (0)