mapillary / OpenSfM

Open source Structure-from-Motion pipeline
https://www.opensfm.org/
BSD 2-Clause "Simplified" License
3.37k stars 855 forks source link

Obtaining a more crisp point cloud #1034

Open arv8315 opened 9 months ago

arv8315 commented 9 months ago

I am having difficulty with the SFM. It is always generating a fuzzy looking point cloud across multiple datasets. I have attached one example.

3D_point_cloud_buddha

It is based on an orbit shot for a sequence of images for which one image looks as follows: output_0002_bk_rmvd_with_prompt_1

I am not able to easily find information to make this point cloud come out looking nicer. I have tried increasing the number of frames and the camera has relatively high resolution. I can clean up any motion blur a bit more with some of the shots. However, when trying on other datasets where there is a significant number of frames and no motion blur, this fuzzy point cloud issue persists. Can someone suggest a way to fix this?

There are too many parameters in this config file: https://opensfm.org/docs/_modules/opensfm/config.html. I am doing some checking but not totally sure which adjustment is going to make the difference yet.

arv8315 commented 9 months ago

module 'cv2' has no attribute 'xfeatures2d' is the error when trying SURF in place of HAHOG. There might be a fix but have not implemented it and tested that. Using SIFT results in .ply with no data in it! HAHOG takes a shorter time to parse compared to SIFT! Otherwise tried to increase the 'depthmap_min_consistent_views' to a number larger than 3 but it resulted in the 'feature' parts of the point cloud being gouged which is not desirable. Trying to change bundle_outlier_filtering_type from FIXED to AUTO does not make much difference. I have to look further into the source to understand the difference. I tried to change triangulation_type to ROBUST but it did not make much difference.

In contrast, when I tried to use colmap, I got a better sparse point cloud without as many distortions. To get to a Dense PC, it requires a GPU, so I will try that when I get one sorted out shortly. Meanwhile, it would be good if someone has a suggestion to overcome the OpenSFM limitation with generating noisy PCs. I might still be overlooking changing the right setting to improve the outcome.

arv8315 commented 9 months ago

I got this as the mesh btw:

image

The facial features are not very clear and all the detail is fuzzy.

arv8315 commented 9 months ago

Akaze works but same issue with noisy Point cloud. Does it come down to issue with incomplete EXIF camera parameters? Going to see if that makes a difference.