surface_fit op• Data kinds: image2d × image2d × image2d → poly_surface
• Call: import fullseye as fs; fs.ledger.fit_poly_surface(x, y, z, degree=2) (implementation को सीधे call करना हो तो import match3d; match3d.fit_poly_surface(x, y, z, degree=2), registry से लेना हो तो ops3d.get("fit_poly_surface"))
बिखरे (x,y,z) → z=f(x,y) polynomial least squares। return value model (coef/powers/degree/rms/pv)।
basis {x^i·y^j : i + j <= degree} (पदों की संख्या (degree+1)(degree+2)/2; degree=1 पर 3 पदों वाला plane, 2 पर 6 पदों वाली 2nd-order surface) को lstsq से fit करता है। x, y, z के तत्वों की संख्या समान हो तो shape से फर्क नहीं पड़ता (भीतर ravel होता है; grid हो तो np.mgrid का आउटपुट सीधे दें)। return value dict: coef (T,) गुणांक, powers हर गुणांक का (i, j) (पद x**i * y**j), degree, rms residual का RMS, pv residual का peak-to-valley (max − min)। इकाई z की है।
• बिंदुओं की संख्या पदों से कम हो तो minimum-norm हल चुपचाप लौटता है। x, y का परिमाण बड़ा हो तो उच्च order में conditioning बिगड़ती है
(पहले निर्देशांकों को center और normalise करें)। NaN की जाँच नहीं होती।
आगे: eval_poly_surface(model, x, y) से किसी भी बिंदु पर मान निकालें। grid पर height field के लिए surface_form_error / background_flatten इसे भीतर से call करते हैं।
• blas_threads_and_memory — Matrix decompositions धीमे क्यों हैं — BLAS threads, caches, memory layout
• 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 के स्रोत।
• contours_to_terrain — py -3.11 examples_3d/contours_to_terrain.py
poly_surface को input के रूप में लेते हैं)fuse_to_voxel · eval_poly_surface
surface_fit)eval_poly_surface · surface_form_error · background_flatten
*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.