curve op• Data kinds: points → pairs
• Call: import fullseye as fs; fs.ledger.curvature_torsion(curve) (to call the implementation directly, import curve3d; curve3d.curvature_torsion(curve); from the registry, ops3d.get("curvature_torsion"))
• Return value through the ledger: fullseye.ledger.curvature_torsion(...) returns only the declared out type pairs (the underlying function also returns auxiliary values). When you need what was dropped, use fullseye.ledger.curvature_torsion.raw(...) or call curve3d.curvature_torsion directly.
• Underlying return: (kappa,tau) → (N,2) pairs
The curvature κ and torsion τ at each point (a reparameterisation-invariant closed form). → (kappa (N,), tau (N,)).
Under a uniform scale s of the coordinates, κ→κ/s and τ→τ/s scale correctly. The epsilon guarding against division by 0 is
relativised: an absolute 1e-12 dominates cross_norm² (~s⁴) and r1_norm³ (~s³) at small coordinate scales and destroys κ/τ, so a relative eps is used, normalised to the same dimension as each denominator with the representative scale L=median‖r'‖ (linear in the coordinate scale s). This is exactly equivalent to normalising the curve by L, computing, and scaling back by 1/L.
The computation takes the ordered point sequence (N,3), applies np.gradient 3 times with the index as parameter (central differences, one-sided differences at both ends) to get r', r'', r''', and computes
• κ = ‖r'×r''‖ / ‖r'‖³
• τ = (r'×r'')·r''' / ‖r'×r''‖²
from them. The unit of both κ and τ is 1/coordinate unit. The sign of τ is positive for the right-handed helix (a cosθ, a sinθ, bθ), b>0. On straight sections (‖r'×r''‖≈0), κ≈0, and τ is unreliable because its denominator becomes only eps.
• ValueError: when all points coincide and median‖r'‖ is 0 or non-finite.
• Where the point spacing changes abruptly the numerical derivatives get disturbed, so first make the spacing uniform with resample_uniform or smooth with fit_spline_curve before passing. The 2 points at each end lose accuracy from one-sided differences.
• For N<2 np.gradient raises ValueError. The (N,3) shape is not validated.
If you need the frame (T,N,B), use frenet_frame; take the arc length ds from arc_length.
• Sample-data catalog (download URLs / licences) — 2-D uses skimage.data (BSD/public domain) plus synthetic images; 3-D lists download URLs for real data sources (Stanford, PDS, …).
• Operator provenance and references — the sources of the research/methods this op family came from.
• space_curve — py -3.11 examples_3d/space_curve.py
• torus_knot_curve — py -3.11 examples_3d/torus_knot_curve.py
pairs as input)curve)frenet_frame · arc_length · resample_uniform · fit_spline_curve
*Provenance: curve3d.py — 3D operator registry. This per-op note is generated by tools/opdocs.py md (do not hand-edit).*
© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.