colmap 安装


#预准备

环境:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
sudo apt-get install \
    git \
    cmake \
    ninja-build \
    build-essential \
    libboost-program-options-dev \
    libboost-filesystem-dev \
    libboost-graph-dev \
    libboost-system-dev \
    libeigen3-dev \
    libflann-dev \
    libfreeimage-dev \
    libmetis-dev \
    libgoogle-glog-dev \
    libgtest-dev \
    libsqlite3-dev \
    libglew-dev \
    qtbase5-dev \
    libqt5opengl5-dev \
    libcgal-dev \
    libceres-dev

#安装colmap

参考

  • colmap新版本没有dev环境
1
2
3
4
5
6
7
8
git clone --branch 3.8 https://github.com/colmap/colmap.git --single-branch

cd colmap && \
	mkdir build && \
	cd build && \
	sudo cmake .. -DCMAKE_CUDA_ARCHITECTURES=native && \
	sudo make -j$(nproc) && \
	sudo make install

#遇到的错误

1
2
3
set(Qt5_CMAKE_DIR "/path/to/your/qt/lib/cmake")
set(Qt5Core_DIR ${Qt5_CMAKE_DIR}/Qt5Core)
set(Qt5OpenGL_DIR ${Qt5_CMAKE_DIR}/Qt5OpenGL)