Point-line localization

class limap.runners.PointLineLocalizationOptions(workspace_path: Path | str = 'tmp', skip_exists: bool = False, weight_path: Path = <factory>, max_image_dim: int | None = None, _image_description: ImageDescriptionOptions = <factory>, _image_association: ImageAssociationOptions = <factory>, pose_estimation: PointLineAbsolutePoseOptions = <factory>, n_retrieval: int = 10, use_points_only: bool = False)

Options for point-line visual localization.

__init__(workspace_path: Path | str = 'tmp', skip_exists: bool = False, weight_path: Path = <factory>, max_image_dim: int | None = None, _image_description: ImageDescriptionOptions = <factory>, _image_association: ImageAssociationOptions = <factory>, pose_estimation: PointLineAbsolutePoseOptions = <factory>, n_retrieval: int = 10, use_points_only: bool = False) None
property image_association: ImageAssociationOptions

Image association options with propagated skip_exists/weight_path.

property image_description: ImageDescriptionOptions

Image description options with propagated skip_exists/weight_path.

property line_detection

Line detection options with propagated skip_exists/weight_path.

property line_matching

Line matching options with propagated skip_exists/weight_path.

max_image_dim: int | None = None
n_retrieval: int = 10
property point_detection: PointDetectionOptions

Point detection options.

property point_matching: PointMatcherOptions

Point matching options.

pose_estimation: PointLineAbsolutePoseOptions
skip_exists: bool = False
use_points_only: bool = False
weight_path: Path
workspace_path: Path | str = 'tmp'
limap.runners.point_line_localization(options: PointLineLocalizationOptions, holistic_recon: HolisticReconstruction, query_images: dict[int, tuple[Path, Camera]], retrieval: dict[str, list[str]], results_path: Path, id_to_name: dict[int, str] | None = None) dict[int, Rigid3d]

Point-line visual localization.

Takes a single HolisticReconstruction containing the database: - point_recon: COLMAP reconstruction with 3D points - structure_recon: Lines3D and 2D structures per image

Computes point and line correspondences on the fly for each query image. Intermediate outputs (detections, descriptors, matches) are stored in options.workspace_path and can be reused when options.skip_exists=True.

Parameters:
  • options – Localization options containing: - workspace_path: Directory for intermediate outputs - skip_exists: Reuse cached detections/matches if they exist - weight_path: Path to neural network weights - point_detection/matching: Point detector/matcher configuration - line_detection/matching: Line detector/matcher configuration - pose_estimation: C++ PointLineAbsolutePoseOptions

  • holistic_recon – Database reconstruction with both points and lines

  • query_images – Dict mapping query image ID to (image_path, camera)

  • retrieval – Query image name -> list of database image names

  • results_path – Path to write final localization results file

  • id_to_name – Optional dict mapping image IDs to image names (used for retrieval lookup and results output). If None, uses image_path.name which may not match retrieval format.

Returns:

Mapping of query image IDs to estimated poses (pycolmap.Rigid3d)