forked from mapillary/OpenSfM
-
Notifications
You must be signed in to change notification settings - Fork 38
/
Dockerfile.ceres2
43 lines (35 loc) · 1.05 KB
/
Dockerfile.ceres2
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
FROM ubuntu:20.04
ARG DEBIAN_FRONTEND=noninteractive
# Install apt-getable dependencies
RUN apt-get update \
&& apt-get install -y \
build-essential \
cmake \
git \
libeigen3-dev \
libgoogle-glog-dev \
libopencv-dev \
libsuitesparse-dev \
python3-dev \
python3-numpy \
python3-opencv \
python3-pip \
python3-pyproj \
python3-scipy \
python3-yaml \
curl \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
# Install Ceres 2
RUN \
mkdir -p /source && cd /source && \
curl -L http://ceres-solver.org/ceres-solver-2.0.0.tar.gz | tar xz && \
cd /source/ceres-solver-2.0.0 && \
mkdir -p build && cd build && \
cmake .. -DCMAKE_C_FLAGS=-fPIC -DCMAKE_CXX_FLAGS=-fPIC -DBUILD_EXAMPLES=OFF -DBUILD_TESTING=OFF && \
make -j4 install && \
cd / && rm -rf /source/ceres-solver-2.0.0
COPY . /source/OpenSfM
WORKDIR /source/OpenSfM
RUN pip3 install -r requirements.txt && \
python3 setup.py build