Skip to content
Snippets Groups Projects
Commit e46614f5 authored by calrama's avatar calrama
Browse files

centos-7,windows-1809: Update MXNet to 1.6.0

parent e3a04522
Branches
No related tags found
No related merge requests found
Pipeline #26688 canceled
......@@ -10,6 +10,7 @@ RUN yum install -y centos-release-scl && \
yum install -y epel-release && \
yum install -y devtoolset-8 && \
yum install -y rh-git218-git && \
yum install -y patch && \
yum clean all
ADD bash/toolchain.sh /etc/profile.d/toolchain.sh
ADD bash/ld-library-path.sh /etc/profile.d/ld-library-path.sh
......@@ -207,8 +208,9 @@ RUN version=4.2.0 && \
rm -rf opencv-${version}* opencv_contrib-${version}*
# MXNet
ENV MXNet_DIR /opt/mxnet-1.5.1
RUN version=1.5.1 && \
ENV MXNet_DIR /opt/mxnet-1.6.0
ADD patches/mxnet-1.6.0-manual-cuda-arch-flags.patch /opt/mxnet-1.6.0-manual-cuda-arch-flags.patch
RUN version=1.6.0 && \
source /etc/profile && \
cd /opt && \
curl -sSLO https://github.com/apache/incubator-mxnet/releases/download/${version}/apache-mxnet-src-${version}-incubating.tar.gz && \
......@@ -216,16 +218,15 @@ RUN version=1.5.1 && \
rm -f apache-mxnet-src-${version}-incubating.tar.gz && \
mv apache-mxnet-src-${version}-incubating mxnet-${version} && \
cd mxnet-${version} && \
patch -p1 -i /opt/mxnet-1.6.0-manual-cuda-arch-flags.patch && \
cmake -S. -B build -G Ninja \
-D CMAKE_CXX_STANDARD=14 -D USE_CXX14_IF_AVAILABLE=ON \
-D CMAKE_BUILD_TYPE=Release -D CMAKE_INSTALL_PREFIX=/usr/local \
-D CMAKE_CUDA_COMPILER=/usr/local/cuda-10.1/bin/nvcc \
-D USE_CUDA=ON -D USE_CUDNN=ON -D USE_NCCL=OFF \
-D CUDA_ARCH_NAME=Manual \
-D CUDA_ARCH_BIN="61" \
-D CUDA_ARCH_PTX="30 52 75" \
-D CUDA_ARCH_FLAGS="-gencode;arch=compute_61,code=sm_61;-gencode;arch=compute_30,code=compute_30;-gencode;arch=compute_52,code=compute_52;-gencode;arch=compute_75,code=compute_75" \
-D USE_OPENCV=ON -D USE_OPENMP=ON \
-D USE_LAPACK=ON -D USE_MKL_IF_AVAILABLE=OFF \
-D USE_PROFILER=ON \
-D USE_DIST_KVSTORE=OFF \
-D USE_CPP_PACKAGE=ON \
-D USE_SIGNAL_HANDLER=ON \
......@@ -234,6 +235,7 @@ RUN version=1.5.1 && \
-D USE_GPERFTOOLS=OFF \
-D USE_JEMALLOC=OFF \
&& \
rm /opt/mxnet-1.6.0-manual-cuda-arch-flags.patch && \
ninja -C build
# pybind11
......
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 12bc195d5..e297262b7 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -593,7 +593,9 @@ if(USE_CUDA)
# CUDA_SELECT_NVCC_ARCH_FLAGS is not deprecated, though part of deprecated
# FindCUDA https://gitlab.kitware.com/cmake/cmake/issues/19199
include(${CMAKE_ROOT}/Modules/FindCUDA/select_compute_arch.cmake)
- CUDA_SELECT_NVCC_ARCH_FLAGS(CUDA_ARCH_FLAGS ${MXNET_CUDA_ARCH})
+ if(NOT CUDA_ARCH_FLAGS)
+ CUDA_SELECT_NVCC_ARCH_FLAGS(CUDA_ARCH_FLAGS ${MXNET_CUDA_ARCH})
+ endif()
message("-- CUDA: Using the following NVCC architecture flags ${CUDA_ARCH_FLAGS}")
set(arch_code_list)
foreach(arch_str ${CUDA_ARCH_FLAGS})
......@@ -47,6 +47,6 @@ RUN [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tl
RUN $vcpkg_dir = 'C:/vcpkg'; \
git clone https://git.imp.fu-berlin.de/bioroboticslab/robofish/vcpkg.git $vcpkg_dir; \
cd $vcpkg_dir; \
git checkout 7d322e995f49d3989fa982268c2d4586c4f8d1f1; \
git checkout cf0d3656f27287943a5c65f1158314845ae96ad4; \
./scripts/bootstrap.ps1; \
[Environment]::SetEnvironmentVariable('VCPKG_DIR', "\"$vcpkg_dir\"", [EnvironmentVariableTarget]::Machine);
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment