Skip to content

pass use_pba to mapper to use GPU#197

Closed
oldshuren1 wants to merge 1 commit into
cvg:masterfrom
oldshuren1:master
Closed

pass use_pba to mapper to use GPU#197
oldshuren1 wants to merge 1 commit into
cvg:masterfrom
oldshuren1:master

Conversation

@oldshuren1
Copy link
Copy Markdown

No description provided.

@reynoldscem
Copy link
Copy Markdown

I've made a similar change locally. It's worth noting that if your problem gets big enough COLMAP will fall-back to the CPU version of PBA which is ~an order of magnitude slower. You can remove the check in COLMAP to always use the GPU if you are comfortable with risking the worse numerical stability.

@oldshuren1
Copy link
Copy Markdown
Author

Think you mean in controller/incremental_mapper.cc:68 checking for ParallelBundleAdjuster::IsSupported?

I also found that if the camera mode is single, pba is also not used. But using single camera itself can reduce a lot of time.

@reynoldscem
Copy link
Copy Markdown

No I don’t mean that. There’s a check on the number of residuals in the problem hardcoded. I’ll have a look for it on Monday if you can’t find it.

@sarlinpe
Copy link
Copy Markdown
Member

sarlinpe commented Jun 3, 2022

Since IncrementalMapperOptions has many other useful options, I would prefer to instead provide a flexible mechanism to modify any of these options from the command line, just like COLMAP accepts --Mapper.ba_global_pba_gpu_index 1. This could be later extended to the ImageReaderOptions.

@sarlinpe
Copy link
Copy Markdown
Member

This should be solved by #210. Can you please confirm that it works for you?

@sarlinpe sarlinpe closed this Jul 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants