cvg / pixel-perfect-sfm

Pixel-Perfect Structure-from-Motion with Featuremetric Refinement (ICCV 2021, Best Student Paper Award)
Apache License 2.0
1.29k stars 132 forks source link

build error when building the pixsfm package: #66

Closed pengzhao-life closed 1 year ago

pengzhao-life commented 1 year ago

Hey, I encountered this build error as below. It looks like from ceres library. I installed ceres-solver from colmap official website https://colmap.github.io/install.html#build-from-source

Any suggestions? Thanks!

Error message: pixsfm/util/src/memory.h:59:39: error: ‘const class ceres::Problem’ has no member named ‘ParameterBlockLocalSize’; did you mean ‘ParameterBlockSize’? 59 | num_active_params += problem->ParameterBlockLocalSize(param_block);

sarlinpe commented 1 year ago

Hi, thanks for reporting this. We still use the deprecated LocalParameterization API of Ceres, which was removed recently from master (https://github.com/ceres-solver/ceres-solver/commit/68c53bb39552cd4abfd6381df08638285f7386b3). For now a simple fix is to install Ceres v2.1.0 via git checkout 2.1.0.

@Phil26AT We should update pixsfm as https://github.com/colmap/colmap/commit/30521f19de45c1cb2df8809728e780bf95fc8836.

pengzhao-life commented 1 year ago

Thanks for the quick response! It built successfully after switching to Ceres 2.1.0. And demo.ipynb works great.

sarlinpe commented 1 year ago

Tentative fix in PR https://github.com/cvg/pixel-perfect-sfm/pull/68 in case Ceres >= 2.2.0 is required.