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.matching

Core matching functions and RANSAC filtering for robust feature matching.

Functions

run_matching

Run image matching with specified matcher.
from imcui.ui import run_matching

result = run_matching(
    image0, image1,
    matcher_name="superpoint-lightglue",
    device="cuda"
)
Parameters:
ParameterTypeDescription
image0np.ndarrayFirst image (RGB numpy array)
image1np.ndarraySecond image (RGB numpy array)
matcher_namestrName of matcher from vismatch
devicestrDevice: “cuda”, “cpu”, “mps”
Returns: Dictionary containing keypoints, matches, and scores.

run_ransac

Run RANSAC filtering on matched points.
from imcui.ui import run_ransac

filtered_matches = run_ransac(
    kp0, kp1, matches,
    ransac_method="CV2_USAC_MAGSAC",
    threshold=8.0
)
Parameters:
ParameterTypeDescription
kp0np.ndarrayKeypoints from first image
kp1np.ndarrayKeypoints from second image
matchesnp.ndarrayMatched point pairs
ransac_methodstrRANSAC method for filtering
thresholdfloatRANSAC reprojection threshold
Returns: Filtered matches after RANSAC filtering.

filter_matches

Filter matches by confidence threshold.
from imcui.ui import filter_matches

clean_matches = filter_matches(matches, scores, threshold=0.2)
Parameters:
ParameterTypeDescription
matchesnp.ndarrayMatched point pairs
scoresnp.ndarrayConfidence scores
thresholdfloatMinimum confidence threshold
Returns: Filtered matches above threshold. Source Code: imcui/ui/matching.py