diff --git a/.github/workflows/build-docker-image.yml b/.github/workflows/build-docker-image.yml new file mode 100644 index 000000000..353624071 --- /dev/null +++ b/.github/workflows/build-docker-image.yml @@ -0,0 +1,38 @@ +name: Build docker image +on: + push: + branches: + - docker + + workflow_dispatch: + +concurrency: + group: build_docker-${{ github.ref }} + cancel-in-progress: true + +jobs: + build-doc: + name: build docker image + runs-on: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest] + steps: + - name: Check out the repo + uses: actions/checkout@v3 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v2 + + - name: Log in to Docker Hub + uses: docker/login-action@v2 + with: + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + + - name: Build and push + uses: docker/build-push-action@v4 + with: + push: true + tags: k2fsa/icefall:torch1.13.0-cuda11.6 diff --git a/docker/torch1.13.0-cuda11.6-cudnn8.dockerfile b/docker/torch1.13.0-cuda11.6-cudnn8.dockerfile new file mode 100644 index 000000000..3f8fd0d37 --- /dev/null +++ b/docker/torch1.13.0-cuda11.6-cudnn8.dockerfile @@ -0,0 +1,25 @@ +FROM pytorch/pytorch:1.13.0-cuda11.6-cudnn8-devel + +# Install dependencies +RUN pip install --no-cache-dir \ + torchaudio==0.13.0+cu116 -f https://download.pytorch.org/whl/torch_stable.html \ + k2==1.24.3.dev20230725+cuda11.6.torch1.13.0 -f https://k2-fsa.github.io/k2/cuda.html \ + git+https://github.com/lhotse-speech/lhotse \ + kaldifeat==1.25.0.dev20230726+cuda11.6.torch1.13.0 -f https://csukuangfj.github.io/kaldifeat/cuda.html \ + \ + kaldifst \ + kaldilm \ + kaldialign \ + sentencepiece>=0.1.96 \ + tensorboard \ + typeguard \ + dill \ + +RUN git clone https://github.com/k2-fsa/icefall /workspace/icefall && \ + cd /workspace/icefall && \ + pip install --no-cache-dir -r requirements.txt + +ENV PYTHONPATH /workspace/icefall:$PYTHONPATH + +WORKDIR /workspace/icefall +