Skip to content

Commit ad8c839

Browse files
committed
2 parents 0e211fd + 4d120db commit ad8c839

File tree

2 files changed

+11
-6
lines changed

2 files changed

+11
-6
lines changed

build.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ def build_common(name, tag, extra_opts=''):
7878
'tf-old', 'tf-current', 'tf-future',
7979
'caffe', 'pytorch',
8080
'cntk-builder','cntk',
81+
'kaldi',
8182
'vendor-aws', 'vendor-ngc', 'vendor-freecad',
8283
]
8384

@@ -338,6 +339,9 @@ def main(build, list_builds, _auto_push):
338339
build_kernel('python-cntk', '2.7-py36')
339340
build_kernel('python-cntk', '2.7-py36-cuda9')
340341

342+
if 'kaldi' in build:
343+
build_kernel('python-kaldi', 'py38-cuda11.1')
344+
341345
# AWS polly
342346
if 'vendor-aws' in build:
343347
build_kernel('vendor/aws_polly', '0.1-alpine3.8')

python-kaldi/Dockerfile.py38-cuda11.1

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,30 +3,31 @@ FROM lablup/common-base:py38-cuda11.1
33
# install kaldi
44
WORKDIR /opt
55
RUN apt update ; apt-get install -y sox subversion
6-
RUN git clone https://github.com/kaldi-asr/kaldi.git /opt/kaldi && \
7-
cd /opt/kaldi && \
8-
git checkout c013e2e && \
6+
RUN git clone https://github.com/hephaex/kaldi.git /opt/kaldi && \
97
cd /opt/kaldi/tools && \
108
make -j $(nproc) && \
119
cd /opt/kaldi/src && \
1210
./configure --shared --use-cuda \
1311
--cudatk-dir=/usr/local/cuda/ \
1412
--mathlib=ATLAS \
1513
--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" && \
16-
make depend -j $(nproc) -lcuda -L /usr/local/cuda/lib64/stubs && \
17-
make -j $(nproc) -lcuda -L /usr/local/cuda/lib64/stubs
14+
make depend -j $(nproc) && \
15+
make -j $(nproc)
1816
RUN cd /opt/kaldi/src && \
19-
make ext -j $(nproc) -lcuda -L /usr/local/cuda/lib64/stubs && \
17+
make ext -j $(nproc) && \
2018
ldconfig && \
2119
find /opt/kaldi -type f \( -name "*.o" -o -name "*.la" -o -name "*.a" \) -\
2220
exec rm {} \; && \
2321
rm -rf /opt/kaldi/.git
2422

23+
RUN mkdir -p /workspace && \
24+
chmod -R 777 /workspace
2525
# Install ipython kernelspec
2626
Run python3 -m ipykernel install --display-name "Lablup Kaldi 21.01 on Python 3\
2727
.8 (CUDA 11.1)" && \
2828
cat /usr/local/share/jupyter/kernels/python3/kernel.json
2929

30+
3031
# Backend.AI specifics
3132
LABEL ai.backend.kernelspec="1" \
3233
ai.backend.envs.corecount="OPENBLAS_NUM_THREADS,OMP_NUM_THREADS,NPROC" \

0 commit comments

Comments
 (0)