Estimate absolute pose
- limap.estimators.absolute_pose.pl_estimate_absolute_pose(cfg, l3ds, l3d_ids, l2ds, p3ds, p2ds, camera, campose=None, inliers_line=None, inliers_point=None, jointloc_cfg=None, silent=True, logger=None)
Estimate absolute camera pose of a image from matched 2D-3D line and point correspondences.
- Parameters:
cfg (dict) – Localization config, fields refer to “localization” section in
cfgs/localization/default.yaml
l3ds (list[
limap.base.Line3d
]) – Matched 3D line segmentsl3d_ids (list[int]) – Indices into l3ds for match of each
limap.base.Line3d
in l2ds, same length of l2dsl2ds (list[
limap.base.Line2d
]) – Matched 2d lines, same length of l3d_idsp3ds (list[
np.array
]) – Matched 3D points, same length of p2dsp2ds (list[
np.array
]) – Matched 2D points, same length of p3dscamera (
limap.base.Camera
) – Camera of the query imagecampose (
limap.base.CameraPose
, optional) – Initial camera pose, only useful for pose refinement (whencfg["ransac"]["method"]
isNone
)inliers_line (list[int], optional) – Indices of line inliers, only useful for pose refinement
inliers_point (list[int], optional) – Indices of point inliers, only useful for pose refinement
jointloc_cfg (dict, optional) – Config for joint optimization, fields refer to
limap.optimize.LineLocConfig
, passNone
for defaultsilent (bool, optional) – Turn off to print logs during Ceres optimization
logger (
logging.Logger
) – Logger to print logs for information
- Returns:
Estimated pose and ransac statistics.
- Return type:
tuple[
limap.base.CameraPose
,limap.estimators.RansacStatistics
]