Skip to main content

Documentation Index

Fetch the complete documentation index at: https://imcui.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

imcui.ui.geometry

Geometry estimation functions for computing transformation matrices between matched points.

Functions

compute_geometry

Compute geometric transformation between matched keypoints.
from imcui.ui import compute_geometry

H, mask = compute_geometry(
    kp0, kp1, matches,
    geometry_type="homography",
    ransac_method="CV2_USAC_MAGSAC"
)
Parameters:
ParameterTypeDescription
kp0np.ndarrayKeypoints from first image, shape (N, 2)
kp1np.ndarrayKeypoints from second image, shape (M, 2)
matchesnp.ndarrayMatched point pairs, shape (K, 2)
geometry_typestrGeometry type: “homography”, “fundamental”, “essential”
ransac_methodstrRANSAC method: “RANSAC”, “CV2_USAC_MAGSAC”, “LMEDS”
Returns:
  • H: Transformation matrix (3x3 for homography/fundamental)
  • mask: Boolean mask indicating inliers
Source Code: imcui/ui/geometry.py