facebookresearch / consistent_depth

We estimate dense, flicker-free, geometrically consistent depth from monocular video, for example hand-held cell phone video.
MIT License
1.62k stars 235 forks source link

colmap issue #9

Closed miaoqiz closed 4 years ago

miaoqiz commented 4 years ago

Hi,

Thanks for the excellent framework!

When testing without camera calibration:


python main.py --video_file $video_file_path --path $output_path --make_video


There is an error that seems to ask for camera information:


File "consistent_depth/process.py", line 62, in pipeline
valid_frames = calibrate_scale(self.video, self.out_dir, frame_range, params)

File "consistent_depth/scale_calibration.py", line 184, in calibrate_scale video.path, colmap.sparse_dir(colmap_dir, 0)

File "consistent_depth/scale_calibration.py", line 74, in make_camera_params_from_colmap cameras, images, points3D = load_colmap.read_model(path=sparse_dir, ext=".bin")

File "consistent_depth/third_party/colmap/scripts/python/read_write_model.py", line 416, in read_model cameras = read_cameras_binary(os.path.join(path, "cameras" + ext))

File "consistent_depth/third_party/colmap/scripts/python/read_write_model.py", line 135, in read_cameras_binary with open(path_to_model_file, "rb") as fid: FileNotFoundError: [Errno 2] No such file or directory: './results/tmp/colmap_dense/sparse/0/cameras.bin'


Can you kindly advise?

Thanks so much!

miaoqiz commented 4 years ago

The issue seems to be gone after installing "colmap" correctly.

One more question, if not specifying "--camera_model", is the default model "SIMPLE_PINHOLE" or "FOV"?

Thanks so much!

KyoukaMinaduki commented 4 years ago

Hello! This problem occurs to me. May I ask the version about your colmap?

Tord-Zhang commented 3 years ago

@miaoqiz also met the same problem. What's the version of your colmap? Thanks

miaoqiz commented 3 years ago

Hi @mangdian

I used a docker container that has cuda-10.0. "colmap" was then built correctly and the issue above was gone.

I just used the "colmap" that the installation script points to at that time.

Thanks!