superquadric op• 数据种类:points → primitive
• 调用: import fullseye as fs; fs.ledger.fit_superquadric(points) -> 'dict'(要直接调用实现,import superquadric; superquadric.fit_superquadric(points) -> 'dict';从台账取用则 ops3d.get("fit_superquadric"))
• GPU:无(仅 CPU 参考实现)
用 least_squares 对点群拟合超二次曲面,返回 dict{a,eps,R,t,residual}。
初始位姿 = 惯性张量特征向量,初始 a = 主轴 bbox 的一半,初始 eps=(1,1)。优化时 a 保持为正,eps 裁剪(clip)到 [0.1, 2.0]。
尺度:把点云移到重心,在除以外接框对角线长 L 的无量纲坐标中求解,再以 a = L·a'、t = 重心 + L·t'、residual = L³·residual' 还原(★2026-11-05 对抗验证 N5)。以前直接在原始坐标中求解,残差随长度的 1.5 次方缩小,因此 scipy 默认的 gtol 在第一次评估时就已满足,s <= 1e-4 的点云会原样返回 PCA 初始值(椭球 a=(2,1.5,1) 变成 1.979/1.495/1.001,中心偏移 0.17·s)。现在无论 s 如何都得到相同的解。所有点重合的点云(L == 0)抛出 ValueError。
dict: {'a': (3,), 'eps': (2,), 'R': (3,3), 't': (3,), 'residual': float}
• 示例数据目录(下载 URL / 许可证) —— 2-D 用 skimage.data(BSD/公有领域)加合成图,3-D 给出真实数据源(Stanford/PDS 等)的下载 URL。
• 算子来历与参考文献 —— 该算子族所依据的研究/方法出处。
• superquadric_fit — py -3.11 examples_3d/superquadric_fit.py
primitive 作为输入)fuse_to_voxel · angle_between_lines · angle_between_planes · angle_line_plane · distance_point_plane · distance_point_line · distance_line_line · distance_segment_segment
superquadric)sample_surface · inside_outside · superquadric_residual
*Provenance: superquadric.py — 3D 算子登记表。本条目由 tools/opdocs.py md 自动生成(请勿手工编辑)。*
© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.