Need advice on singular matrix problems.
Hi all,
We are using a custom edit of the BatchFixedLagSmoother
to do some optimization. In our unit tests, we are running into some singular matrix issues.
Issue 1: We initialize a synthetic bundle adjustment problem at ground truth except for one landmark that is put in a very bad place. Every factor has a Cauchy mEstimator. The optimizer reduces the error significantly, but eventually hits a local minima, and starts upping the LM lambda parameter. When lambda = 10000, the linear system solution fails at this check:
Why would the solution fail as lambda increases? My intuition is that a higher lambda will always make a better conditioned system.
Issue 2: sometimes marginalization fails for us when using eliminatePartialMultifrontal()
.
This fails at the same place as above. Here I note that the smoother is not using QR and also not using a special ordering for the marginalization.
--
Can you give us some general tips on how to think about and handle issues like this when they come up?
Thanks!
Comments (7)
-
reporter -
reporter - edited description
-
We have run into this problem when both very large and very small uncertainties are present in the same system. E.g., start with a tight constraint in GPS denied scenario: after a while the uncertainty on the most recent pose is so large it causes this error. We have not found a good solution (other than to switch to QR). Preconditioning might be one answer.
I also don't know whether we completely and fully understand the issue yet. Any insight this issue brings will be most welcome.
-
Did you figure out something more here?
-
reporter @tschneith, what was the outcome. As far as I remember, we did two things: A. Switched to QR (addressing (1) above), and B. Rigorously filtered outliers before marginalization (addressing (2) above).
Right?
-
Yes, the outlier filtering and the switch to QR seemed to improve the situation. I have a unit test in our framework that reproduces the error and will investigate the cause. If you are interested I can try to isolate a minimal test that reproduces the problem.
-
I am interested :-)
- Log in to comment
Wow! Issue 200! Do we get a prize? (I'm hoping for a free copy of GTSAM).