Update Dockerfile.compute5.0
This commit is contained in:
@@ -5,6 +5,7 @@ RUN apt-get update && \
|
||||
python3-dev \
|
||||
python3-pip \
|
||||
wget \
|
||||
git \
|
||||
&& \
|
||||
apt-get clean && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
@@ -45,24 +46,18 @@ RUN wget -q https://download.open-mpi.org/release/open-mpi/v4.1/openmpi-${OPENMP
|
||||
cd .. && \
|
||||
rm -r openmpi-*
|
||||
|
||||
COPY third_party third_party
|
||||
COPY cli cli
|
||||
COPY include include
|
||||
COPY src src
|
||||
COPY cmake cmake
|
||||
COPY python python
|
||||
COPY CMakeLists.txt .
|
||||
RUN git clone --recursive https://github.com/OpenNMT/CTranslate2.git
|
||||
|
||||
ARG CXX_FLAGS
|
||||
ENV CXX_FLAGS=${CXX_FLAGS:-"-msse4.1"}
|
||||
ARG CUDA_NVCC_FLAGS
|
||||
ENV CUDA_NVCC_FLAGS=${CUDA_NVCC_FLAGS:-"-Xfatbin=-compress-all"}
|
||||
ARG CUDA_ARCH_LIST
|
||||
ENV CUDA_ARCH_LIST=${CUDA_ARCH_LIST:-"Common"}
|
||||
ENV CUDA_ARCH_LIST=${CUDA_ARCH_LIST:-"5.0"}
|
||||
ENV CTRANSLATE2_ROOT=/opt/ctranslate2
|
||||
ENV LD_LIBRARY_PATH=/usr/local/lib/:${LD_LIBRARY_PATH}
|
||||
|
||||
RUN mkdir build_tmp && \
|
||||
RUN cd CTranslate2 && mkdir build_tmp && \
|
||||
cd build_tmp && \
|
||||
cmake -DCMAKE_INSTALL_PREFIX=${CTRANSLATE2_ROOT} \
|
||||
-DWITH_CUDA=ON -DWITH_CUDNN=ON -DWITH_MKL=ON -DWITH_DNNL=ON -DOPENMP_RUNTIME=COMP \
|
||||
@@ -73,7 +68,7 @@ RUN mkdir build_tmp && \
|
||||
ENV LANG=en_US.UTF-8
|
||||
COPY README.md .
|
||||
|
||||
RUN cd python && \
|
||||
RUN cd /root/CTranslate2/python && \
|
||||
python3 -m pip --no-cache-dir install -r install_requirements.txt && \
|
||||
python3 setup.py bdist_wheel --dist-dir $CTRANSLATE2_ROOT
|
||||
|
||||
|
||||
Reference in New Issue
Block a user