Skip to content

Instantly share code, notes, and snippets.

@cdcseacave
cdcseacave / CMakeLists.txt
Created November 23, 2022 08:35
Example using Boost serialization with ZSTD or ZIP compression
# CMakeList.txt : Top-level CMake project file, do global configuration
cmake_minimum_required (VERSION 3.8.2)
# Load automatically VCPKG toolchain if available
IF(NOT DEFINED CMAKE_TOOLCHAIN_FILE AND DEFINED ENV{VCPKG_ROOT})
SET(CMAKE_TOOLCHAIN_FILE "$ENV{VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake" CACHE STRING "")
IF(NOT DEFINED VCPKG_TARGET_TRIPLET AND DEFINED ENV{VCPKG_DEFAULT_TRIPLET})
SET(VCPKG_TARGET_TRIPLET "$ENV{VCPKG_DEFAULT_TRIPLET}" CACHE STRING "")
ENDIF()
ENDIF()
@cdcseacave
cdcseacave / extract_colmap_poses.py
Created April 14, 2022 17:43
Convert cameras_poses.log generated by InterfaceCOLMAP to individual poses files
import argh
import os
import numpy as np
def extract_colmap_poses(
log_file: str,
output_path: str,
) -> None:
print('Loading ', log_file)
lines = []
@cdcseacave
cdcseacave / Dockerfile
Last active July 7, 2022 12:35
Build latest OpenMVG+OpenMVS+COLMAP in docker
FROM ubuntu:20.04
# Get dependencies
RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y \
cmake \
build-essential \
graphviz \
git \
coinor-libclp-dev \
libceres-dev \