Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compute pose covariance in BA #207

Open
HeatherHu opened this issue Sep 18, 2017 · 1 comment
Open

Compute pose covariance in BA #207

HeatherHu opened this issue Sep 18, 2017 · 1 comment
Labels

Comments

@HeatherHu
Copy link

I want to get the covariance corresponding to the camera pose during projection optimization. I did in following steps:
(1) add the current camera pose as a vertex
setId(0) ; setEstimate(initial value); setMarginalize(false); setFixed(false);
(2) add points
setId(i+1) ; setEstimate(initial value); setMarginalize(true); setFixed(true);
(3) add edge:
setMeasurements(position in image); setInformation(Identity); setRobustKernel(Huber);setDelta(sqrt(5.991)); set camera params(fx,fy,cx,cy)
(4) Get covariance after optimization by using the following code:
g2o::SparseBlockMatrixXd spinv;
optimizer.computeMarginals(spinv,optimizer.vertex(0));
The pose covariance is spinv.block(0,0)->eval().
I did not understand marginalize very well. I am not sure that setMarginalize as true affect the result of optimization or not.
I just worried I did something wrong. Is anyone familiar with this? Could you have a look to see if it is a problem anywhere?
Thanks very much for your help.

Copy link

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days.

@github-actions github-actions bot added the Stale label Jan 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant