-
Notifications
You must be signed in to change notification settings - Fork 85
/
Copy pathDockerfile.ubuntu
51 lines (42 loc) · 1.29 KB
/
Dockerfile.ubuntu
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
FROM nvidia/cuda:10.0-cudnn7-devel
ARG DEBIAN_FRONTEND=noninteractive
# Add library path
ENV LD_LIBRARY_PATH ./thirdparty/install/lib:${LD_LIBRARY_PATH}
# Add nvidia driver settings
ENV NVIDIA_VISIBLE_DEVICES ${NVIDIA_VISIBLE_DEVICES:-all}
ENV NVIDIA_DRIVER_CAPABILITIES ${NVIDIA_DRIVER_CAPABILITIES:+$NVIDIA_DRIVER_CAPABILITIES,}graphics
# Install system dependencies
RUN set -x && apt-get update -y && apt-get install -y \
cmake \
libboost-all-dev \
libglew-dev \
libgoogle-glog-dev \
libjsoncpp-dev \
libopencv-dev \
libopenni2-dev \
unzip \
wget \
&& rm -rf /var/lib/apt/lists/*
# Download TensorFlow C API
ARG TFAPI_URL=https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-gpu-linux-x86_64-1.15.0.tar.gz
RUN wget -qO - ${TFAPI_URL} | tar -C /usr/local -xvz
# Build DeepFactors
COPY . /DeepFactors
WORKDIR /DeepFactors
# Download pretrained weight
RUN set -x && bash ./scripts/download_network.bash
# build deps
RUN set -x && ./thirdparty/makedeps.sh --threads 2
# build slam
RUN set -x && \
mkdir -p build && \
cd build && \
cmake \
-DDF_BUILD_TOOLS=ON \
-DDF_BUILD_TESTS=ON \
-DDF_BUILD_DEMO=ON \
-DDF_CUDA_ARCH="6.1" \
.. && \
make -j1
WORKDIR /DeepFactors
ENTRYPOINT ["/bin/bash"]