Skip to content

Commit 04d6477

Browse files
committed
support scs-python
1 parent 9895346 commit 04d6477

File tree

1 file changed

+9
-48
lines changed

1 file changed

+9
-48
lines changed

commons/Dockerfile.base.py38-cuda11.2

Lines changed: 9 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,9 @@ ENV DEBIAN_FRONTEND=noninteractive \
1515
PIP_IGNORE_INSTALLED=0 \
1616
PYTHONUNBUFFERED=1 \
1717
LIBRARY_PATH=/usr/local/cuda/lib64/stubs \
18-
<<<<<<< HEAD
1918
_CUDA_COMPAT_PATH="/usr/local/cuda/compat" \
2019
LD_LIBRARY_PATH="/usr/local/cuda/extras/CUPTI/lib64:/usr/local/cuda/compat/lib:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/usr/local/cuda/lib64:/usr/lib/x86_64-linux-gnu:/usr/include/x86_64-linux-gnu:/usr/local/lib" \
21-
PATH="/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/mpi/bin:/usr/local/ucx:/opt/conda/bin:/usr/local/sbin:/usr/bin/cmake/bin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/src/lightgbm/LightGBM" \
22-
=======
23-
_CUDA_COMPAT_PATH="/usr/local/cuda/compat" LD_LIBRARY_PATH="/usr/local/cuda/extras/CUPTI/lib64:/usr/local/cuda/compat/lib:/usr/local/nvidia/lib:/usr/local/nvidia/lib64:/usr/local/cuda/lib64:/usr/lib/x86_64-linux-gnu:/usr/include/x86_64-linux-gnu:/usr/local/lib" \
24-
PATH="/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/mpi/bin:/usr/local/ucx:/usr/local/sbin:/usr/bin/cmake/bin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/src/lightgbm/LightGBM" \
25-
>>>>>>> 3946c9e80914c8ab44e7d1524d83448a031eeaf4
20+
PATH="/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/mpi/bin:/usr/local/ucx:/opt/conda/bin:/usr/bin/cmake/bin:/usr/local/sbin:/usr/bin/cmake/bin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/src/lightgbm/LightGBM" \
2621
CPLUS_INCLUDE_PATH=/usr/include/gdal \
2722
C_INCLUDE_PATH=/usr/include/gdal \
2823
mecab_dicdir=/usr/local/lib/mecab/dic/mecab-ko-dic \
@@ -207,7 +202,6 @@ RUN apt-get update -y && \
207202
/opt/conda/bin/conda install pip && \
208203
/opt/conda/bin/python -m pip install --no-cache-dir -U "setuptools <58"
209204

210-
211205
# OFED
212206
WORKDIR /tmp
213207
RUN wget -q -O - https://www.mellanox.com/downloads/ofed/MLNX_OFED-5.4-2.4.1.3/MLNX_OFED_LINUX-${MLNX_OFED_VERSION}-ubuntu20.04-x86_64.tgz | tar xzf - && \
@@ -288,38 +282,7 @@ RUN cd /usr/local/src && mkdir lightgbm && cd lightgbm && \
288282
cd /usr/local/src/lightgbm/LightGBM/python-package && \
289283
python3 setup.py install --precompile
290284

291-
ENV NUMPY_VERSION 1.22.4
292-
ENV SCIPY_VERSION 1.8.1
293-
ENV MKL_VERSION=2020.3
294-
ENV MKL_BUILD=279
295-
296-
# Numpy
297-
RUN git clone --branch=v${NUMPY_VERSION} --depth=1 https://github.com/numpy/numpy.git numpy && \
298-
cd numpy && \
299-
git checkout -b v${NUMPY_VERSION} && \
300-
git submodule update --init && \
301-
cp site.cfg.example site.cfg && \
302-
echo "[mkl]" >> site.cfg && \
303-
echo "include_dirs = /opt/2020.3.279/linux/mkl/include/" >> site.cfg && \
304-
echo "library_dirs = /opt/intel/compilers_and_libraries_2020.3.279/linux/mkl/lib/intel64" >> site.cfg && \
305-
echo "mkl_libs = mkl_rt" >> site.cfg && \
306-
echo "lapack_libs =" >> site.cfg && \
307-
python3 setup.py bdist_wheel -d /tmp
308-
309-
# Scipy
310-
RUN cd /tmp && \
311-
git clone --branch=v${SCIPY_VERSION} --depth=1 https://github.com/scipy/scipy.git scipy && \
312-
cd scipy && \
313-
git checkout -b v${SCIPY_VERSION} && \
314-
git submodule update --init && \
315-
cp site.cfg.example site.cfg && \
316-
echo "[mkl]" >> site.cfg && \
317-
echo "include_dirs = /opt/intel/compilers_and_libraries_2020.3.279/linux/mkl/include/" >> site.cfg && \
318-
echo "library_dirs = /opt/intel/compilers_and_libraries_2020.3.279/linux/mkl/lib/intel64" >> site.cfg && \
319-
echo "mkl_libs = mkl_rt" >> site.cfg && \
320-
echo "lapack_libs =" >> site.cfg && \
321-
python3 -m pip install -U --no-cache-dir /tmp/numpy-*.whl && \
322-
python3 setup.py install
285+
# scs-python
323286
RUN cd /tmp && \
324287
git clone --recursive https://github.com/bodono/scs-python.git && \
325288
cd scs-python && \
@@ -349,11 +312,6 @@ RUN curl -LO https://bitbucket.org/eunjeon/mecab-ko/downloads/mecab-0.996-ko-0.9
349312
git clone https://bitbucket.org/eunjeon/mecab-python-0.996.git && \
350313
python3 -m pip install /tmp/mecab-python-0.996
351314

352-
WORKDIR /tmp
353-
COPY ./requirements.22.06.txt /tmp/requirements.txt
354-
RUN python3 -m pip install --no-cache-dir -r requirements.txt && \
355-
rm -f /tmp/*.whl /tmp/requirements.txt
356-
357315
# OpenCV
358316
WORKDIR /tmp
359317
ENV OPENCV_VERSION="4.5.5"
@@ -427,10 +385,13 @@ RUN mkdir /tmp/openmpi && \
427385
echo "btl_tcp_if_exclude = lo,docker0" >> /usr/local/etc/openmpi-mca-params.conf
428386
RUN MPICC=/usr/lib64/openmpi/bin/mpicc python3 -m pip install mpi4py && \
429387
python3 -m pip install "jax[cuda11_cudnn805]" -f https://storage.googleapis.com/jax-releases/jax_releases.html
430-
RUN CUDA_ROOT=/usr/local/cuda python3 -m pip install mpi4jax
431-
# nni==1.9 \
432-
# mlflow==1.12.1 \
433-
# scikit-nni==0.2.1
388+
389+
WORKDIR /tmp
390+
COPY ./requirements.22.06.txt /tmp/requirements.txt
391+
RUN python3 -m pip install --no-cache-dir -r requirements.txt && \
392+
rm -f /tmp/*.whl /tmp/requirements.txt
393+
394+
RUN CUDA_ROOT=/usr/local/cuda python3 -m pip install mpi4jax scikit-nni==0.2.1 mlflow==1.12.1 nni==1.9
434395

435396
RUN ldconfig /usr/local/cuda/targets/x86_64-linux/lib/stubs && \
436397
HOROVOD_NCCL_LINK=SHARED \

0 commit comments

Comments
 (0)