Needed covariance blocks by processors
Now, Problem
has a std::map
in which has some covariance matrix blocks stored. But it only contains the covariance matrix blocks that have been computed by the solver. The blocks that are computed are set by the arguments given when calling SolverManager::computeCovariances()
from the "outside" (for example the ROS node).
However, some processors may need some covariance matrix blocks to be computed.
Now SolverManager
contains a pointer to Problem
, but not the opposite. So, from the wolf tree, we are not able to ask for some covariance blocks to be computed..
In my opinion, adding in Problem
a pointer to the SolverManager
is not desirable. It would make multi-threading quite more complicated. Also, it is dangerous allowing the threads of the processors to call SolverManager
expensive functions like computeCovariance()
or solve()
.
I think we should add some notification (analogous to the new/removed StateBlocks
and Factors
) or any other Problem
attribute to be read and handled by the SolverManager
when its thread calls solve()
.