refine op• Data kinds: points × points → pose
• Call: import fullseye as fs; fs.ledger.icp_point2point_3d(src, dst, iters=50, init_R=None, init_t=None, tol=1e-06, max_corr_dist=None, trim_ratio=None, device='cpu', reproducible=False) (implementation को सीधे call करना हो तो import match3d; match3d.icp_point2point_3d(src, dst, iters=50, init_R=None, init_t=None, tol=1e-06, max_corr_dist=None, trim_ratio=None, device='cpu', reproducible=False), registry से लेना हो तो ops3d.get("icp_point2point_3d"))
point cloud को point-to-point ICP (Kabsch/SVD) से refine करता है।
मोटे match अनुमान (integer NCC / Fourier-Mellin±3° / Hough±0.5voxel) से मिले initial pose (init_R, init_t) से शुरू करके, src point cloud को dst point cloud पर rigid transform से align करता है। हर iteration में nearest neighbour correspondences (cKDTree) फिर से बनाता है, Kabsch algorithm (SVD) से relative rotation और translation निकालकर जोड़ता जाता है, इसलिए correspondences ज्ञात न होने पर भी sub-voxel सटीकता तक converge करता है।
partial overlap और outlier को Trimmed ICP (केवल कम दूरी वाले correspondences लिए जाते हैं) और absolute distance gate (max_corr_dist) से संभाला जाता है। अंतिम RMSE वास्तव में अपनाए गए correspondences (inliers) पर मापा जाता है, इसलिए partial observation में भी pose की गुणवत्ता सही दिखती है।
Arguments:
src: (N,3) चलने वाला point cloud (torch.Tensor या numpy.ndarray)।
dst: (M,3) स्थिर (reference) point cloud।
iters: iterations की अधिकतम संख्या।
init_R: (3,3) initial rotation। None होने पर identity matrix।
init_t: (3,) initial translation। None होने पर zero vector।
tol: RMSE का relative सुधार इस मान से कम होने पर convergence मानकर रुकता है।
max_corr_dist: इस दूरी से अधिक के correspondences outlier मानकर हटाए जाते हैं (None से बंद)।
trim_ratio: 0<r<=1। हर iteration में nearest neighbour दूरी सबसे कम वाले ऊपरी r हिस्से के correspondences ही
अपनाने वाला Trimmed ICP। partial overlap (overlap ratio r) के लिए उपयोगी। None से बंद।
device: torch device ("cpu" आदि)। SVD इसी device पर हल होता है।
reproducible: True होने पर reduction points के क्रम और BLAS threads की संख्या पर निर्भर नहीं करता (default False = पहले जैसा)।
mean के लिए math.fsum, cross-covariance H के लिए ozakimm (Ozaki scheme), pose element-wise लागू होता है, RMSE भी math.fsum से।
src points का क्रम बदलने पर भी R, t और rmse bit स्तर पर समान रहते हैं (उसी computer और उसी LAPACK पर)। trim_ratio की सीमा पर
ठीक बराबर दूरी वाले points क्रम के अनुसार अलग चुने जा सकते हैं। 200,000 points पर प्रति 1 iteration 0.7 ms से लगभग 170 ms हो जाता है।
Returns:
R: (3,3) rotation। dst ~= src @ R.T + t को संतुष्ट करता है। torch वाले environment में torch.Tensor, नहीं तो समान मानों वाला numpy.ndarray (2026-09-07 को
मुख्य भाग को numpy में बदलते समय भी compatibility के लिए type वही रखा गया)।
★उसी family का icp_point2plane हमेशा numpy लौटाता है — family के भीतर
types एक जैसे नहीं हैं, इसलिए downstream में np.asarray(R) से गुज़ारना सुरक्षित है
(दोनों चलते हैं। breaking change से बचने के लिए यह असमानता छोड़ी गई है)।
t: (3,) translation (R जैसा ही type)।
info: dict। "rmse" (अपनाए गए correspondences पर अंतिम RMSE), "iters" (वास्तविक iterations की संख्या),
"converged" (bool), "inliers" (अपनाए गए correspondences की संख्या), "rmse_history" (list)।
• Sample data catalog (DL URL / license) — 2-D के लिए skimage.data (BSD/public) + synthetic, 3-D के लिए real data sources (Stanford/PDS आदि) के DL URL।
• Operators का स्रोत और संदर्भ — इस op family के मूल research/methods के स्रोत।
• gicp_register — py -3.11 examples_3d/gicp_register.py
• itokawa_self_register — py -3.11 examples_3d/itokawa_self_register.py
• itokawa_shape_match — py -3.11 examples_3d/itokawa_shape_match.py
• partial_overlap_icp — py -3.11 examples_3d/partial_overlap_icp.py
pose को input के रूप में लेते हैं)fuse_to_voxel · pose_error · bundle_adjust · mean_reprojection_error · optimize_pose_graph · relative_pose · mean_edge_error · rotation_translation_error
refine)refine_peak_newton · refine_translation_lk · refine_lm · refine_rotation_z · icp_point2plane
*Provenance: match3d.py — 3D operator registry. यह per-op note tools/opdocs.py md से अपने-आप generate होता है (हाथ से edit न करें)।*
© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.