@@ -5,13 +5,14 @@ FROM nvcr.io/nvidia/pytorch:21.06-py3
5
5
6
6
ENV DEBIAN_FRONTEND=noninteractive \
7
7
MPLBACKEND=Svg \
8
- PIP_IGNORE_INSTALLED=0 \
9
- PYTHONUNBUFFERED=1 \
10
- LD_LIBRARY_PATH="/usr/local/cuda/compat/lib:/usr/local/cuda/extras/CUPTI/lib64:/usr/local/cuda/lib:/usr/local/cuda/lib64:/usr/local/nvidia/lib64:/usr/include/x86_64-linux-gnu" \
11
- PATH="/usr/local/nvm/versions/node/v14.8.0/bin:/opt/conda/bin:/usr/local/mpi/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/ucx/bin:/opt/tensorrt/bin:/usr/local/src/lightgbm/LightGBM:/usr/local/bin/mecab" \
12
- mecab_dicdir=/usr/local/lib/mecab/dic/mecab-ko-dic \
13
8
CPLUS_INCLUDE_PATH=/usr/include/gdal \
14
9
C_INCLUDE_PATH=/usr/include/gdal \
10
+ PYTHONUNBUFFERED=1 \
11
+ LIBRARY_PATH=/usr/local/cuda/lib64/stubs \
12
+ _CUDA_COMPAT_PATH="/usr/local/cuda/compat" \
13
+ 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/include/x86_64-linux-gnu:/opt/intel/compilers_and_libraries_2020.3.279/linux/mkl/lib/intel64" \
14
+ PATH="/usr/local/nvm/versions/node/v14.8.0/bin:/opt/conda/bin:/usr/local/mpi/bin:/usr/local/ucx:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/bin/cmake/bin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/tensorrt/bin:/usr/local/src/lightgbm/LightGBM:/usr/local/bin/mecab" \
15
+ mecab_dicdir=/usr/local/lib/mecab/dic/mecab-ko-dic \
15
16
LANG=C.UTF-8
16
17
17
18
RUN apt-get update && \
@@ -134,17 +135,39 @@ RUN cd /tmp && \
134
135
pytorch-lightning \
135
136
&& \
136
137
python3 setup.py install
137
-
138
- WORKDIR /tmp
139
- COPY ./requirements.txt /tmp
140
- RUN /opt/conda/bin/python3 -m pip install --no-cache-dir --ignore-installed -r requirements.txt && \
141
- rm -f /tmp/*.whl /tmp/requirements.txt
142
138
143
139
# OpenCV
140
+ RUN ln -s /usr/include/libv4l1-videodev.h /usr/include/linux/videodev.h && \
141
+ apt-get install -y \
142
+ libgstreamer1.0-dev \
143
+ libgstreamer-plugins-base1.0-dev \
144
+ libgtk-3-dev \
145
+ libtbb-dev \
146
+ libatlas-base-dev \
147
+ libdc1394-22-dev \
148
+ libxvidcore-dev \
149
+ libfaac-dev \
150
+ libmp3lame-dev \
151
+ libtheora-dev \
152
+ libvorbis-dev \
153
+ libxvidcore-dev \
154
+ libopencore-amrnb-dev libopencore-amrwb-dev \
155
+ libavresample-dev \
156
+ x264 \
157
+ libx264-dev \
158
+ v4l-utils \
159
+ libprotobuf-dev protobuf-compiler \
160
+ libgoogle-glog-dev libgflags-dev \
161
+ libgphoto2-dev \
162
+ libeigen3-dev \
163
+ libhdf5-dev \
164
+ && \
165
+ apt-get clean && \
166
+ rm -rf /var/lib/apt/lists/
167
+
144
168
WORKDIR /tmp
145
169
ENV OPENCV_VERSION="4.5.2"
146
- RUN ln -s /usr/include/libv4l1-videodev.h /usr/include/linux/videodev.h && \
147
- wget https://github.com/opencv/opencv/archive/${OPENCV_VERSION}.zip && \
170
+ RUN wget https://github.com/opencv/opencv/archive/${OPENCV_VERSION}.zip && \
148
171
wget -O opencv-contrib.zip https://github.com/opencv/opencv_contrib/archive/${OPENCV_VERSION}.zip && \
149
172
unzip ${OPENCV_VERSION}.zip && \
150
173
unzip opencv-contrib.zip && \
@@ -176,10 +199,14 @@ RUN ln -s /usr/include/libv4l1-videodev.h /usr/include/linux/videodev.h && \
176
199
-D PYTHON_PACKAGES_PATH=$(python3 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())" ) \
177
200
.. 2>&1 | tee cmake_messages.txt && \
178
201
make -j$(nproc) && \
179
- make install && \
180
- cd /tmp && \
181
- python3 -m pip install --no-cache-dir opencv-python && \
182
- rm -fr opencv*
202
+ make install && \
203
+ python3 -m pip install --no-cache-dir opencv-python
204
+
205
+ WORKDIR /tmp
206
+ COPY ./requirements.txt /tmp
207
+ RUN /opt/conda/bin/python3 -m pip install --no-cache-dir --ignore-installed -r requirements.txt && \
208
+ rm -f /tmp/*.whl /tmp/requirements.txt
209
+
183
210
184
211
# install git-lfs
185
212
WORKDIR /tmp
@@ -193,9 +220,9 @@ RUN git clone https://github.com/aristocratos/bashtop.git && \
193
220
cd bashtop && \
194
221
make install
195
222
196
- RUN curl -fL https://github.com/cdr/code-server/releases/download/v3.9.3 /code-server-3.9.3 -linux-amd64.tar.gz | tar -C /usr/local/lib -xz && \
197
- mv /usr/local/lib/code-server-3.9.3 -linux-amd64 /usr/local/lib/code-server-3.9.3 && \
198
- ln -s /usr/local/lib/code-server-3.9.3 /bin/code-server /usr/local/bin/code-server
223
+ RUN curl -fL https://github.com/cdr/code-server/releases/download/v3.10.2 /code-server-3.10.2 -linux-amd64.tar.gz | tar -C /usr/local/lib -xz && \
224
+ mv /usr/local/lib/code-server-3.10.2 -linux-amd64 /usr/local/lib/code-server-3.10.2 && \
225
+ ln -s /usr/local/lib/code-server-3.10.2 /bin/code-server /usr/local/bin/code-server
199
226
200
227
# Install Open MPI
201
228
RUN mkdir /tmp/openmpi && \
0 commit comments