ICP prior covariance from the prior-free innovation¶
Overview¶
The registration residual against the prediction shrinks when the ICP prior pulls the solution toward the prediction, so a prior covariance learned from it confirms itself. The prior-free innovation removes that pull: it is the registration the pairings alone would give, relative to the prediction. Its per-axis statistics give a prior covariance that does not depend on how strong the prior was, nor on the scale of the registration covariance.
Vectors are in the solver tangent of the prior mean: translation, then rotation-vector components (see IcpPrior.h).
// structs struct mola::PriorInnovationRates; // global functions std::optional<Eigen::Matrix<double, 6, 1>> mola::prior_free_innovation( const mrpt::poses::CPose3D& solution, const mrpt::poses::CPose3D& priorMean, const Eigen::Matrix<double, 6, 6>& H, const Eigen::Matrix<double, 6, 6>& P ); std::optional<mrpt::math::CMatrixDouble66> mola::prior_information_from_rates( const std::array<double, 6>& varRate, double dt, double floorLin, double floorAng, const std::optional<Eigen::Matrix<double, 6, 6>>& anchorCov = std::nullopt );
Global Functions¶
std::optional<Eigen::Matrix<double, 6, 1>> mola::prior_free_innovation( const mrpt::poses::CPose3D& solution, const mrpt::poses::CPose3D& priorMean, const Eigen::Matrix<double, 6, 6>& H, const Eigen::Matrix<double, 6, 6>& P )
The prior-free innovation of a registration that used a prior, to first order: nu = e + H^-1 P e, with e = log(prior^-1 * solution) the prior residual at the solution, H the information of the pairings and P that of the prior, both in the tangent of the prior mean. Exact when both costs are quadratic in that tangent. Empty if H or P are not finite, H is not positive (semi)definite, or the result is not finite.
std::optional<mrpt::math::CMatrixDouble66> mola::prior_information_from_rates( const std::array<double, 6>& varRate, double dt, double floorLin, double floorAng, const std::optional<Eigen::Matrix<double, 6, 6>>& anchorCov = std::nullopt )
The information of the ICP prior for a prediction dt seconds after the last registration: covariance diag(varRate) dt^2, plus anchorCov if given (e.g. the last registration covariance carried to the prediction), plus floorLin^2 and floorAng^2 on the translation and rotation diagonals. Empty if dt <= 0 or the covariance cannot be inverted.