Covariance computation fails for 'unused' parameter blocks

90 Aufrufe
Direkt zur ersten ungelesenen Nachricht

Wannes Van Loock

ungelesen,
02.12.2015, 05:41:1402.12.15
an Ceres Solver
Hi,

When computing the covariance for problems that have unused parameter blocks, i.e. blocks that do not appear in any residual, the covariance computation fails due to rank deficiency. Is this behavior intentional or a bug? As a workaround I now set these blocks constant and set them variable again after the computation. If considered a bug, I'm happy to fix it. However, I'm not really sure in which of the existing functions this code should go.

Wannes

Sameer Agarwal

ungelesen,
02.12.2015, 10:26:3502.12.15
an Ceres Solver

Wannes,
Mathematically this is not a bug. 

But given that we handle structural rank deficiency in the estimator, it should be considered a bug.

The problem is at 

https://ceres-solver.googlesource.com/ceres-solver/+/master/internal/ceres/covariance_impl.cc#270

where we look for structurally sparse columns of the jacobian by looking for constant parameter blocks. This test should be extended to include parameter blocks that do not have any residual blocks associated with them. 

This code is a bit old and is now starting to overlap with the refactored code for preprocessing a Program object before optimization is performed on it.

The right way to do this should likely use 

https://ceres-solver.googlesource.com/ceres-solver/+/master/internal/ceres/program.h#146

Program::CreateReducedProgram

Sameer


--
You received this message because you are subscribed to the Google Groups "Ceres Solver" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ceres-solver...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ceres-solver/e99d0c31-04db-4778-8bda-b1e730d17a4d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Sameer Agarwal

ungelesen,
02.12.2015, 10:33:1602.12.15
an Ceres Solver

Sameer Agarwal

ungelesen,
03.12.2015, 20:05:3403.12.15
an Ceres Solver
Wannes,
are you working on this? I already have a patch in the works. I need to add some tests and it should be good to go.
Sameer

Wannes Van Loock

ungelesen,
04.12.2015, 01:11:3504.12.15
an Ceres Solver
Hi Sameer,
I had a look, but couldn't figure out all internals yet. So feel free to push your patch.
Wannes

Sameer Agarwal

ungelesen,
04.12.2015, 10:31:5604.12.15
an Ceres Solver

Wannes Van Loock

ungelesen,
15.01.2016, 05:11:5515.01.16
an Ceres Solver
The same issue pops up when there are unused variables within a single ParameterBlock. Not sure if there is a simple fix for it in Ceres.

Wannes

Sameer Agarwal

ungelesen,
15.01.2016, 08:31:4115.01.16
an Ceres Solver

This one is harder because there is no way of knowing if you are using a parameter or not. That requires understanding cost function code.

A simpler fix is, if you as a user know this. Mark the parameter as constant using a subset parameterization. But that may not always be possible.

Sameer


--
You received this message because you are subscribed to the Google Groups "Ceres Solver" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ceres-solver...@googlegroups.com.
Allen antworten
Antwort an Autor
Weiterleiten
0 neue Nachrichten