code wiki / (root) / nx_essential3d.nx

nx_essential3d.nx

buildroot/runtime/nx_essential3d.nx

8150 B217 linesdepth 3pulls 5 transitivereach 5 importersview sourcekind library
docsdependenciesstructsconstsfunctions

about

nx_essential3d.nx -- ESSENTIAL MATRIX estimation (8-point algorithm), the piece that recovers relative camera pose from 2D image correspondences with UNKNOWN poses = the front of two-view SfM (cadtwin P1). Reuses the SVD-FREE power-iteration null-space tool proven in nx_register3d: the 8-point solves A f = 0 (f = smallest eigenvector of A^T A), found by power-iterating a Gershgorin-shifted (cI - A^T A). Calibrated cameras -> ESSENTIAL matrix E s.t. x'^T E x = 0 for corresponding normalized image points x,x'. Benchmarked by the HELD-OUT epipolar residual (E must satisfy the constraint on points it was NOT fit to = not overfit). Composes with nx_recon3d (E -> pose -> triangulate). All Q14 fixed-point, deterministic. license_tier: ORIGINAL

dependencies 2 imports · 2 importers

nx_recon3d.nx nx_vecmath.nx nx_essential3d.nx nx_photogram_front.nx nx_recon2view_gate.nx

imports: nx_recon3d.nxnx_vecmath.nx

imported by: nx_photogram_front.nxnx_recon2view_gate.nx

structs

none

consts

10const E3_MAGIC_23170: i64 = 23170
11const E3_MAGIC_1024: i64 = 1024
12const E3_MAGIC_2048: i64 = 2048
14const E3_Q: i64 = 16384

functions

17func e3_projn(cx: i64, cy: i64, cz: i64, basis: *i64, x: i64, y: i64, z: i64, out2: *i64) -> i64
32func e3_row(nx: i64, ny: i64, nxp: i64, nyp: i64, out9: *i64) -> i64
called by 1: e3_estimate_norm
46func e3_abs(a: i64) -> i64 { if a < 0 { return 0 - a } return a }
47func e3_isqrt(n: i64) -> i64 { return vm_isqrt(n) }
50func e3_estimate(a: *i64, nrows: i64, out_e9: *i64) -> i64
called by 1: e3_estimate_norm calls 2: e3_abse3_isqrt
126func e3_normset(c: *i64, n: i64, cn: *i64, t: *i64) -> i64
called by 1: e3_estimate_norm calls 1: e3_isqrt
155func e3_mat3T(a: *i64, o: *i64) -> i64
called by 1: e3_estimate_norm
161func e3_mat3mul(a: *i64, b: *i64, o: *i64) -> i64
called by 1: e3_estimate_norm
174func e3_estimate_norm(c0: *i64, c1: *i64, n: i64, out_e: *i64) -> i64
209func e3_residual(e9: *i64, nx: i64, ny: i64, nxp: i64, nyp: i64) -> i64
called by 2: pf_ransac_emain calls 1: e3_abs