Commit a48a4d24 authored by Sascha Dewes's avatar Sascha Dewes

updated Dockerfile to install mxnet for C++

parent 7e66a886
Pipeline #395235 failed with stages
in 60 minutes and 13 seconds
......@@ -10,21 +10,21 @@ buildDockerMXNetMaven:
script:
- cd docker
- docker login registry.git.rwth-aachen.de -u someUserName -p yEep-tAt19HbsmNQJMNo
- docker build -t registry.git.rwth-aachen.de/monticore/embeddedmontiarc/applications/reinforcement_learning/forestrl/mxnetmvn:v0.0.1 .
- docker push registry.git.rwth-aachen.de/monticore/embeddedmontiarc/applications/reinforcement_learning/forestrl/mxnetmvn:v0.0.1
- docker build -t registry.git.rwth-aachen.de/monticore/embeddedmontiarc/applications/reinforcement_learning/forestrl/mxnetmvn:v0.0.2 .
- docker push registry.git.rwth-aachen.de/monticore/embeddedmontiarc/applications/reinforcement_learning/forestrl/mxnetmvn:v0.0.2
only:
changes:
- docker/*
testDockerImage:
image: registry.git.rwth-aachen.de/monticore/embeddedmontiarc/applications/reinforcement_learning/forestrl/mxnetmvn:v0.0.1
image: registry.git.rwth-aachen.de/monticore/embeddedmontiarc/applications/reinforcement_learning/forestrl/mxnetmvn:v0.0.2
stage: testimage
script:
- chmod +x install.sh
- ./install.sh
TestBuild:
image: registry.git.rwth-aachen.de/monticore/embeddedmontiarc/applications/reinforcement_learning/forestrl/mxnetmvn:v0.0.1
image: registry.git.rwth-aachen.de/monticore/embeddedmontiarc/applications/reinforcement_learning/forestrl/mxnetmvn:v0.0.2
stage: build
script:
- mvn clean install -s settings.xml
......@@ -7,7 +7,7 @@ ENV ROS_HOME=/opt/ros/kinetic
CMD ["bash"]
# Essential
RUN apt-get install -y openjdk-8-jdk openjdk-8-jre gcc make cmake git python2.7 python-dev python-numpy swig libboost-all-dev curl wget python-tk
RUN apt-get install -y openjdk-8-jdk openjdk-8-jre gcc make cmake ninja-build git python2.7 python-dev python-numpy swig libboost-all-dev curl wget python-tk
RUN curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
RUN python get-pip.py
RUN pip install h5py numpy pyprind matplotlib
......@@ -30,9 +30,10 @@ RUN apt-get install -y libblas-dev liblapack-dev
RUN apt-get install -y build-essential
RUN apt-get install -y libopenblas-dev
RUN apt-get install -y libopencv-dev
RUN git clone --recursive https://github.com/apache/incubator-mxnet.git mxnet_source && \
cd mxnet_source && git checkout tags/1.5.0 && cd .. && \
cp -r mxnet_source/include/mxnet /usr/include/mxnet
RUN git clone --recursive https://github.com/apache/incubator-mxnet.git mxnet
RUN cd mxnet && git checkout tags/1.5.0 && git submodule update --recursive --init
RUN cd mxnet && mkdir build && cd build && cmake -DUSE_CPP_PACKAGE=1 -DUSE_CUDA=0 -GNinja .. && ninja
RUN cd mxnet && cp -r include/mxnet /usr/include/mxnet && cp -r cpp-package/include/mxnet-cpp /usr/include/ && cp -r 3rdparty/tvm/nnvm/include/nnvm /usr/include/ && cp -r 3rdparty/dmlc-core/include/dmlc /usr/include/
RUN pip install numpy==1.16.5 mxnet==1.5.0
RUN cp -r "$(dirname $(python -c 'import mxnet; print(mxnet.__file__)'))/libmxnet.so" /usr/lib
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment