AIBluefisher / DAGSfM

Distributed and Graph-based Structure from Motion. This project includes the official implementation of our Pattern Recognition 2020 paper: Graph-Based Parallel Large Scale Structure from Motion.
https://aibluefisher.github.io/GraphSfM/
BSD 3-Clause "New" or "Revised" License
395 stars 84 forks source link

Can't run pipeline with sequential mode. #58

Open DubovitskyDenis opened 1 year ago

DubovitskyDenis commented 1 year ago

image I have database, which I got after colmap reconstruction(from original colmap). What could have gone wrong?

AIBluefisher commented 1 year ago

How do you build the database, by COLMAP or by DAGSfM? Since DAGSfM stores relative camera poses instead of the essential/fundamental/homography matrices, the database built by COLMAP is not compatible with DAGSfM.

DubovitskyDenis commented 1 year ago

I built the database by COLMAP. Now I see, that it was a bad idea. What should I do to run DAGSfM correctly? Should I run 'extract_feature.in' and 'exhaustive_matcher.in' after that?

AIBluefisher commented 1 year ago

The relative poses are obtained during feature matching. All you need to do is to rebuild a database. Actually, you can follow the pipeline in this script but replace colmap's original mapper at lines 34-39 with the distributed mapper.

DubovitskyDenis commented 1 year ago

Hello again! I have a problem when starting colmap distributed_mapper command. I created database by DAFSfM. The third command from the script started working and continued to carry out the reconstruction, but at some point an error occurred. It's hard for me to understand what could be the problem.

image

AIBluefisher commented 1 year ago

I'm not sure what causes the crash. You may need to debug that piece of code. But you can simply set retriangulate to false to avoid re-triangulation after merging:

  if (options_.retriangulate) {
    LOG(INFO) << "Triangulating for separators...";
    timer.Start();
    Triangulate();
    timer.Pause();
    triangulate_time = timer.ElapsedSeconds();
  }

Then, you can rerun the sfm_aligner to merge all the partitions. The command can be like:

colmap sfm_aligner --reconstructions_path {YOUR_PARTITION_PATH}