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

a problem about iris_lama(2) #36

Open
alonly2024 opened this issue Nov 7, 2024 · 2 comments
Open

a problem about iris_lama(2) #36

alonly2024 opened this issue Nov 7, 2024 · 2 comments

Comments

@alonly2024
Copy link

@eupedrosa but I encountered a problem abut the sover,I want to add weights to different points。
I don't know how to add weights to different points in solve。Can I add *k in residuals[i]?Can i need change the J->row(i)?

@alonly2024
Copy link
Author

@eupedrosa My approach is to analyze the curvature of each point. For points with smaller curvature or farther distances, the weights will be set relatively high when solving. But I don't know how to put this weight into the solving. My current approach is to modify residues [i] multiplied by k , J ->row (i) multiplied by k.in loc::MatchSurface2D::eval().
I don't know if it's correct?

@eupedrosa
Copy link
Member

Assuming that W is a NxN diagonal matrix, I think you need the following changes:

VectorXd g = J.transpose() * W * residuals;
// and
MatrixXd A = J.transpose() * W * J;

Nonetheless, lama already does robust fitting. The goal is to reduce the weight of points with higher error. Maybe it already does what you want.

If you want to use the weighted strategy, you may need to change the solver.cpp to remove the parts where a weight is calculated for the robust fitting.

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

No branches or pull requests

2 participants