@@ -12,56 +12,150 @@ ENV DEBIAN_FRONTEND=noninteractive \
12
12
C_INCLUDE_PATH=/usr/include/gdal \
13
13
LANG=C.UTF-8
14
14
15
- RUN apt-get update && \
15
+ RUN apt-key adv --refresh-keys --keyserver keyserver.ubuntu.com && \
16
+ apt-get update && \
16
17
apt-get install -y --no-install-recommends \
17
18
automake \
19
+ bison \
20
+ build-essential \
18
21
bzip2 \
22
+ ca-certificates \
19
23
cabextract \
24
+ chrpath \
25
+ devscripts \
26
+ dh-make \
27
+ dirmngr \
28
+ dkms \
29
+ dpatch \
30
+ ethtool \
31
+ fakeroot \
20
32
ffmpeg \
33
+ flex \
21
34
fonts-nanum \
22
35
fonts-nanum-coding \
23
36
fonts-nanum-extra \
37
+ g++ \
38
+ gcc \
39
+ gdal-bin \
24
40
gfortran \
41
+ gir1.2-gtk-3.0 \
42
+ git \
43
+ graphviz \
25
44
htop \
45
+ iputils-ping \
26
46
libasound2-dev \
27
47
libatlas-base-dev \
48
+ libavcodec-dev \
49
+ libavformat-dev \
28
50
libavresample-dev \
51
+ libboost-dev \
52
+ libboost-filesystem-dev \
53
+ libboost-system-dev \
54
+ libcairo-dev \
55
+ libcairo2-dev \
56
+ libcurl3-dev \
29
57
libdc1394-22-dev \
30
58
libeigen3-dev \
31
59
libfaac-dev \
60
+ libfftw3-dev \
61
+ libfreetype6-dev \
62
+ libfuse2 \
32
63
libgdal-dev \
64
+ libgeos++-dev \
65
+ libgeos-dev \
33
66
libgflags-dev \
67
+ libgfortran4 \
68
+ libgirepository1.0-dev \
69
+ libglib2.0-0 \
34
70
libgoogle-glog-dev \
35
71
libgphoto2-dev \
36
72
libgstreamer-plugins-base1.0-dev \
37
73
libgstreamer1.0-dev \
38
74
libgtk-3-dev \
39
- libhdf5-dev \
75
+ libhdf5-dev \
76
+ libhdf5-serial-dev \
77
+ # libjasper-dev \
40
78
libjemalloc-dev \
79
+ libjpeg-dev \
80
+ liblapack-dev \
81
+ libmnl0 \
41
82
libmp3lame-dev \
83
+ libmpdec2 \
42
84
libncurses-dev \
85
+ libnl-3-200 \
86
+ libnl-3-dev \
87
+ libnl-route-3-200 \
88
+ libnl-route-3-dev \
89
+ libnlopt-dev \
90
+ libnuma-dev \
43
91
libopenblas-dev \
44
92
libopencore-amrnb-dev \
45
93
libopencore-amrwb-dev \
94
+ libpci3 \
95
+ libpng-dev \
96
+ libportmidi-dev \
97
+ libproj-dev \
46
98
libprotobuf-dev \
99
+ libsdl-dev \
100
+ libsdl-image1.2-dev \
101
+ libsdl-mixer1.2-dev \
102
+ libsdl-ttf2.0-dev \
103
+ libsm6 \
104
+ libsmpeg-dev \
105
+ libssl-dev \
106
+ libswscale-dev \
107
+ libtbb-dev \
47
108
libtheora-dev \
109
+ libtiff-dev \
110
+ libv4l-dev \
48
111
libvorbis-dev \
49
112
libx264-dev \
50
113
libxext6 \
114
+ libxine2-dev \
115
+ libxml2-dev \
51
116
libxrender-dev \
117
+ libxrender1 \
118
+ libxslt1-dev \
52
119
libxvidcore-dev \
53
- libsm6 \
54
- libtbb-dev \
120
+ libzmq3-dev \
121
+ lintian \
122
+ lsof \
123
+ make \
55
124
mercurial \
125
+ mime-support \
126
+ mpich \
56
127
ncurses-term \
57
- openjdk-8-jdk \
128
+ net-tools \
129
+ nodejs \
130
+ openjdk-8-jdk \
131
+ openssh-client \
132
+ openssh-server \
58
133
pbzip2 \
59
- pv \
134
+ pciutils \
60
135
pdsh \
136
+ pkg-config \
137
+ proj-bin \
61
138
protobuf-compiler \
139
+ pv \
140
+ python-apt \
141
+ python-xkit \
142
+ python3-gdal \
143
+ screen-resolution-extra \
144
+ subversion \
145
+ swig \
146
+ tk \
147
+ unzip \
62
148
v4l-utils \
63
- x264
64
-
149
+ vim \
150
+ x264 \
151
+ xvfb \
152
+ xz-utils \
153
+ yarn \
154
+ yasm \
155
+ zip \
156
+ tcl \
157
+ udev \
158
+ zlib1g-dev
65
159
# Install CUDA + cuDNN
66
160
RUN ln -s /usr/lib/x86_64-linux-gnu/libcudnn.so.8.3.2 /usr/local/cuda/lib64/libcudnn.so && \
67
161
rm -rf /var/lib/apt/lists/* && \
@@ -112,9 +206,6 @@ RUN git clone -q --branch=v0.3.20 https://github.com/xianyi/OpenBLAS.git && \
112
206
cd /tmp/scs-python && \
113
207
python setup.py install --scs --gpu
114
208
115
- RUN /opt/conda/bin/conda install -n base conda==4.13.0
116
- RUN /opt/conda/bin/conda install -c conda-forge opencv ffmpeg
117
-
118
209
# install git-lfs
119
210
WORKDIR /tmp
120
211
RUN curl -sLO https://github.com/git-lfs/git-lfs/releases/download/v3.3.0/git-lfs-linux-amd64-v3.3.0.tar.gz && \
@@ -131,20 +222,68 @@ RUN git clone https://github.com/aristocratos/bashtop.git && \
131
222
RUN curl -fL https://github.com/cdr/code-server/releases/download/v4.9.1/code-server-4.9.1-linux-amd64.tar.gz \
132
223
| tar -C /usr/local/lib -xz && \
133
224
mv /usr/local/lib/code-server-4.9.1-linux-amd64 /usr/local/lib/code-server-4.9.1 && \
134
- ln -s /usr/local/lib/code-server-4.9.1/bin/code-server /usr/local/bin/code-server
225
+ ln -s /usr/local/lib/code-server-4.9.1/bin/code-server /usr/local/bin/code-server && \
226
+ code-server \
227
+ --install-extension ms-python.python \
228
+ --install-extension ms-ceintl.vscode-language-pack-ko
135
229
230
+ # OpenCV
231
+ ENV OPENCV_VERSION="4.5.5"
136
232
WORKDIR /tmp
137
- COPY ./requirements.22.09.1.txt /tmp/requirements.txt
138
- RUN /opt/conda/bin/python3 -m pip install --no-cache-dir -r requirements.txt
139
- COPY ./requirements.22.09.2.txt /tmp/requirements.txt
140
- RUN /opt/conda/bin/python3 -m pip install --no-cache-dir -r requirements.txt
141
- COPY ./requirements.22.09.3.txt /tmp/requirements.txt
142
- RUN /opt/conda/bin/python3 -m pip install --no-cache-dir -r requirements.txt
143
- COPY ./requirements.22.09.4.txt /tmp/requirements.txt
144
- RUN /opt/conda/bin/python3 -m pip install --no-cache-dir -r requirements.txt
145
- COPY ./requirements.22.09.5.txt /tmp/requirements.txt
146
- RUN /opt/conda/bin/python3 -m pip install --no-cache-dir -r requirements.txt && \
147
- rm -f /tmp/*.whl /tmp/requirem*
233
+ RUN wget https://github.com/opencv/opencv/archive/${OPENCV_VERSION}.zip && \
234
+ wget -O opencv-contrib.zip https://github.com/opencv/opencv_contrib/archive/${OPENCV_VERSION}.zip && \
235
+ unzip ${OPENCV_VERSION}.zip && \
236
+ unzip opencv-contrib.zip && \
237
+ mkdir opencv-${OPENCV_VERSION}/cmake_binary && \
238
+ cd opencv-${OPENCV_VERSION}/cmake_binary && \
239
+ cmake \
240
+ -DCMAKE_BUILD_TYPE=RELEASE \
241
+ -D BUILD_TIFF=ON \
242
+ -D BUILD_opencv_java=OFF \
243
+ -D WITH_CUDA=ON \
244
+ -D CUDA_NVCC_FLAGS=--expt-relaxed-constexpr \
245
+ -D CUDA_TOOLKIT_ROOT_DIR=/usr/local/cuda-11.8 \
246
+ -D ENABLE_FAST_MATH=1 \
247
+ -D CUDA_FAST_MATH=1 \
248
+ -D WITH_CUBLAS=1 \
249
+ -D WITH_OPENGL=ON \
250
+ -D WITH_OPENCL=ON \
251
+ -D WITH_IPP=ON \
252
+ -D WITH_TBB=ON \
253
+ -D WITH_EIGEN=ON \
254
+ -D WITH_V4L=ON \
255
+ -D BUILD_TESTS=OFF \
256
+ -D BUILD_PERF_TESTS=OFF \
257
+ -D OPENCV_EXTRA_MODULES_PATH="../../opencv_contrib-4.5.5/modules" \
258
+ -D CMAKE_BUILD_TYPE=RELEASE \
259
+ -D CMAKE_INSTALL_PREFIX=$(python3 -c "import sys; print(sys.prefix)") \
260
+ -D PYTHON_EXECUTABLE=$(which python3) \
261
+ -D PYTHON_INCLUDE_DIR=$(python3 -c "from distutils.sysconfig import get_python_inc; print(get_python_inc())") \
262
+ -D PYTHON_PACKAGES_PATH=$(python3 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())") \
263
+ .. 2>&1 | tee cmake_messages.txt && \
264
+ make -j$(nproc) && \
265
+ make install && \
266
+ cd /tmp && \
267
+ python3 -m pip install --no-cache-dir opencv-python && \
268
+ rm -fr opencv*
269
+
270
+ WORKDIR /tmp
271
+ COPY requirements.22.09.txt /tmp/requirements.txt
272
+ RUN for f in $(ls requirements*.txt); do pip3 install --disable-pip-version-check --no-cache-dir -r $f; done && \
273
+ rm -f /tmp/*.whl /tmp/requirem*
274
+
275
+
276
+ #COPY ./requirements.22.09.1.txt /tmp/requirements.txt
277
+ #RUN /opt/conda/bin/python3 -m pip install --no-cache-dir -r requirements.txt
278
+ #COPY ./requirements.22.09.2.txt /tmp/requirements.txt
279
+ #RUN /opt/conda/bin/python3 -m pip install --no-cache-dir -r requirements.txt
280
+ #COPY ./requirements.22.09.3.txt /tmp/requirements.txt
281
+ #RUN /opt/conda/bin/python3 -m pip install --no-cache-dir -r requirements.txt
282
+ #COPY ./requirements.22.09.4.txt /tmp/requirements.txt
283
+ #RUN /opt/conda/bin/python3 -m pip install --no-cache-dir -r requirements.txt
284
+ #COPY ./requirements.22.09.5.txt /tmp/requirements.txt
285
+ #RUN /opt/conda/bin/python3 -m pip install --no-cache-dir -r requirements.txt && \
286
+ # rm -f /tmp/*.whl /tmp/requirem*
148
287
149
288
# Install Open MPI
150
289
RUN mkdir /tmp/openmpi && \
@@ -179,6 +318,16 @@ RUN ldconfig /usr/local/cuda/targets/x86_64-linux/lib/stubs && \
179
318
pip install --no-cache-dir horovod==0.24.2 && \
180
319
ldconfig
181
320
321
+ RUN python3 -m pip install pytorch-lightning && \
322
+ python3 -m pip install --no-cache-dir \
323
+ pyg-lib \
324
+ torch-scatter \
325
+ torch-sparse \
326
+ torch-cluster \
327
+ torch-spline-conv \
328
+ torch-geometric \
329
+ -f https://data.pyg.org/whl/torch-1.13.0+cu117.html
330
+
182
331
RUN python3 -m pip install --no-cache-dir \
183
332
mpi4py==3.1.3 \
184
333
nni==2.9 \
0 commit comments