From cd3d0fb566214c13d78a25a4692c81c7df1ac5df Mon Sep 17 00:00:00 2001 From: rsasaki0109 Date: Thu, 22 Oct 2026 09:07:39 +0900 Subject: [PATCH 1/3] test(vision): characterize forward-backward LK pyramid reuse --- benchmarks/lk-pyramid-reuse-plan.json | 42 +++ crates/spatialrust-vision/src/odometry.rs | 4 + .../src/odometry_pair_tests.rs | 246 ++++++++++++++++++ crates/spatialrust-web/Cargo.toml | 4 + .../examples/lk_pyramid_reuse.rs | 128 +++++++++ docs/ROADMAP.md | 1 + 6 files changed, 425 insertions(+) create mode 100644 benchmarks/lk-pyramid-reuse-plan.json create mode 100644 crates/spatialrust-vision/src/odometry_pair_tests.rs create mode 100644 crates/spatialrust-web/examples/lk_pyramid_reuse.rs diff --git a/benchmarks/lk-pyramid-reuse-plan.json b/benchmarks/lk-pyramid-reuse-plan.json new file mode 100644 index 00000000..f03e17f6 --- /dev/null +++ b/benchmarks/lk-pyramid-reuse-plan.json @@ -0,0 +1,42 @@ +{ + "schema": "spatialrust.lk-pyramid-reuse-plan.v1", + "slice": "146AU", + "parent_merge": "fcdb9d6acb34cffd0c033db94960c45db67b4bd9", + "purpose": "Build each CPU LK image pyramid once and reuse the owned pair across forward/backward tracking for built-in scalar components.", + "contract": { + "math": "Keep option/shape/threshold error ordering, scalar conversion, floor-halved box pyramid, per-point LK arithmetic/order, guesses, status and round-trip hypot/threshold unchanged. Reuse only u8/u16/f32/f64; user-defined PixelComponent conversions keep the original two public calls and conversion observations. No public API, dependency, core, GPU or transfer change.", + "ownership": "A private owned pair retains two immutable f32 pyramids through both directions. No cross-call cache or caller alias. Four pyramid constructions become two for built-in robust calls; peak pyramid payload remains two. This is CPU preparation reuse, not a GPU kernel or RSS guarantee.", + "verification": "Characterize new two-public-call references before implementation; require exact coordinate/error bits and statuses across built-in dtypes, options, non-finite/duplicate/empty points, strided subviews, errors and observable custom conversions. Compare actual parent/candidate WASM complete reports and retain all existing browser/model controls. Use in-process interleaved frozen two-call versus candidate measurements, publish every row including adverse results, and verify independent parent executable camera reports.", + "preservation": "Preserve all prior camera/renderer files, isolated Cargo target, 493 scientific JSON, 42 frozen native artifacts, room/reference outputs, both existing raw WASM files and resolved lock. Build only feature-scoped vision/web code in a fresh isolated E-drive target with locked/offline installed toolchains. No sensor/model/SDK/browser/toolchain acquisition or sensor payload copies." + }, + "resources": { + "build_root": "E:/SpatialRustBuild/lk-pyramid-reuse-v1", + "cargo_cache": "E:/SpatialRustBuild/maturity-80-target", + "build_max_bytes": 1073741824, + "positive_cache_growth_max_bytes": 0, + "combined_new_and_positive_cache_growth_max_bytes": 1073741824, + "minimum_free_bytes": 21474836480, + "workers": 1, + "cargo_jobs": 2, + "command_timeout_seconds": 900, + "sampling_seconds": 5, + "asset_download_max_bytes": 0, + "public_verification_stream_max_bytes": 41943040, + "sensor_downloads": 0, + "new_sensor_payload_copies": 0, + "strategy": "Fresh isolated Cargo outputs, no compiler-output hardlinks. Reuse hash-checked vendor and parent package files. Sample bytes and preserve old artifacts before/after each owned command. Retry only transient vanished entries in the owned live Cargo subtree, at most three complete snapshots; fail on unrelated/persistent errors." + }, + "benchmark": { + "shapes": [[192,144],[256,192],[320,240]], + "point_counts": [0,8,80], + "surveys": 2, + "warmup_calls_per_function": 4, + "rounds": 4, + "order_per_round": ["baseline","candidate","candidate","baseline"], + "samples_per_function": 8, + "options": "radius 5, levels 3, 30 iterations, epsilon 0.001, minimum eigenvalue 0.0001, round-trip threshold 1", + "host_workers": 1, + "comparison": "Frozen original two-public-call flow and candidate robust API in the same process; compare complete coordinates/status/error bits outside timing. Keep all samples and adverse rows. CPU affinity/frequency, other host load and allocation effects are uncontrolled. No physical-phone, GPU or end-to-end speed claim." + }, + "remaining_80_percent": "Measured calibration/timing and independent motion, full-room accuracy, qualifying physical Linux hardware and integrated operational acceptance remain open." +} diff --git a/crates/spatialrust-vision/src/odometry.rs b/crates/spatialrust-vision/src/odometry.rs index dc1019df..e5ce581a 100644 --- a/crates/spatialrust-vision/src/odometry.rs +++ b/crates/spatialrust-vision/src/odometry.rs @@ -272,6 +272,10 @@ pub fn estimate_rgbd_odometry( }) } +#[cfg(test)] +#[path = "odometry_pair_tests.rs"] +mod pair_tests; + #[cfg(test)] mod tests { use super::{ diff --git a/crates/spatialrust-vision/src/odometry_pair_tests.rs b/crates/spatialrust-vision/src/odometry_pair_tests.rs new file mode 100644 index 00000000..9a6ea8ff --- /dev/null +++ b/crates/spatialrust-vision/src/odometry_pair_tests.rs @@ -0,0 +1,246 @@ +use super::*; +use spatialrust_image::{Image, ImageRegion}; + +// Frozen parent call graph: each public LK call constructs both pyramids. +fn parent( + previous: ImageView<'_, T, 1>, + next: ImageView<'_, T, 1>, + points: &[Vec2], + options: RobustTrackOptions, +) -> VisionResult { + if !options.max_forward_backward_error.is_finite() || options.max_forward_backward_error < 0.0 { + return Err(VisionError::InvalidParameter( + "forward/backward threshold must be finite and non-negative".into(), + )); + } + let forward = crate::track_points_lucas_kanade(previous, next, points, options.lucas_kanade)?; + let backward = crate::track_points_lucas_kanade( + next, + previous, + forward.next_points(), + options.lucas_kanade, + )?; + let mut status = Vec::with_capacity(points.len()); + let mut errors = Vec::with_capacity(points.len()); + for (index, point) in points.iter().enumerate() { + let valid = forward.status()[index] && backward.status()[index]; + let error = if valid { + let dx = backward.next_points()[index].x - point.x; + let dy = backward.next_points()[index].y - point.y; + dx.hypot(dy) + } else { + f64::INFINITY + }; + status.push(valid && error <= options.max_forward_backward_error); + errors.push(error); + } + Ok(RobustTracks { + next_points: forward.next_points().to_vec(), + status, + forward_backward_errors: errors, + }) +} + +fn compare( + a: ImageView<'_, T, 1>, + b: ImageView<'_, T, 1>, + points: &[Vec2], + options: RobustTrackOptions, +) { + let expected = parent(a, b, points, options); + let actual = track_points_forward_backward(a, b, points, options); + match (actual, expected) { + (Ok(actual), Ok(expected)) => { + assert_eq!(actual.status(), expected.status()); + let bits = |r: &RobustTracks| { + r.next_points().iter().map(|p| [p.x.to_bits(), p.y.to_bits()]).collect::>() + }; + assert_eq!(bits(&actual), bits(&expected)); + assert_eq!( + actual.forward_backward_errors().iter().map(|v| v.to_bits()).collect::>(), + expected.forward_backward_errors().iter().map(|v| v.to_bits()).collect::>() + ); + assert_eq!(actual.accepted_count(), expected.accepted_count()); + } + (Err(actual), Err(expected)) => assert_eq!(actual, expected), + _ => panic!("LK pair result admission differs"), + } +} + +fn texture(w: usize, h: usize, dx: i32, dy: i32) -> Image { + Image::try_new( + w, + h, + (0..w * h) + .map(|i| { + let x = (i % w) as i32 - dx; + let y = (i / w) as i32 - dy; + let hash = (x as u32).wrapping_mul(73856093) ^ (y as u32).wrapping_mul(19349663); + T::from_f64(f64::from((hash ^ (hash >> 13)) & 255)) + }) + .collect(), + ) + .unwrap() +} + +fn scalar_cases() { + for (w, h) in [(33, 35), (65, 79), (96, 80)] { + let a = texture::(w, h, 0, 0); + let b = texture::(w, h, 1, -1); + let points: Vec<_> = (0..12) + .map(|i| Vec2 { + x: 8.25 + ((i * 17) % (w - 16)) as f64, + y: 8.5 + ((i * 13) % (h - 16)) as f64, + }) + .collect(); + for levels in [1, 2, 3, 5] { + for threshold in [0., 0.5, 1.] { + compare( + a.view(), + b.view(), + &points, + RobustTrackOptions { + lucas_kanade: LucasKanadeOptions { + window_radius: 2, + pyramid_levels: levels, + max_iterations: 5, + ..Default::default() + }, + max_forward_backward_error: threshold, + }, + ); + } + } + } +} + +#[test] +fn builtin_scalar_coordinate_status_and_error_bits_match_two_calls() { + scalar_cases::(); + scalar_cases::(); + scalar_cases::(); + scalar_cases::(); +} + +#[test] +fn nonfinite_float_pixels_keep_original_decisions_and_bits() { + for value in [f64::NAN, f64::INFINITY, f64::NEG_INFINITY, -0., 1e300, 1e-300] { + let mut data = vec![value; 33 * 35]; + data[17 * 33 + 16] = 0.; + let a = Image::::try_new(33, 35, data.clone()).unwrap(); + let b = Image::::try_new(33, 35, data.iter().map(|&v| v as f32).collect()).unwrap(); + let points = [Vec2 { x: 16.25, y: 17.5 }]; + compare(a.view(), a.view(), &points, Default::default()); + compare(b.view(), b.view(), &points, Default::default()); + } +} + +#[test] +fn strided_subviews_keep_logical_pixel_sampling() { + let a = texture::(100, 90, 0, 0); + let b = texture::(100, 90, 1, -1); + let a = a.view().subview(ImageRegion::new(2, 3, 65, 79)).unwrap(); + let b = b.view().subview(ImageRegion::new(5, 6, 65, 79)).unwrap(); + assert!(a.as_packed_slice().is_none()); + compare(a, b, &[Vec2 { x: 32., y: 35. }, Vec2 { x: 40.25, y: 43.5 }], Default::default()); +} + +#[test] +fn option_shape_and_round_trip_error_priority_matches_parent() { + let small = Image::::try_new(2, 2, vec![0; 4]).unwrap(); + let image = texture::(8, 8, 0, 0); + let lk = LucasKanadeOptions::default(); + let invalid = [ + LucasKanadeOptions { window_radius: 0, ..lk }, + LucasKanadeOptions { pyramid_levels: 0, ..lk }, + LucasKanadeOptions { pyramid_levels: 33, ..lk }, + LucasKanadeOptions { max_iterations: 0, ..lk }, + LucasKanadeOptions { epsilon: f64::NAN, ..lk }, + LucasKanadeOptions { epsilon: 0., ..lk }, + LucasKanadeOptions { min_eigenvalue: f64::NAN, ..lk }, + LucasKanadeOptions { min_eigenvalue: -1., ..lk }, + LucasKanadeOptions { window_radius: usize::MAX, ..lk }, + lk, + ]; + for options in invalid { + for threshold in [-1., f64::NAN, f64::INFINITY, 0., 1.] { + let options = + RobustTrackOptions { lucas_kanade: options, max_forward_backward_error: threshold }; + compare(small.view(), image.view(), &[], options); + compare(small.view(), small.view(), &[], options); + compare(image.view(), image.view(), &[], options); + } + } +} + +#[test] +fn empty_nonfinite_duplicate_points_and_deep_pyramids_match_parent() { + let a = texture::(33, 35, 0, 0); + let points = [ + Vec2 { x: -0., y: 0. }, + Vec2 { x: 16.25, y: 17.5 }, + Vec2 { x: 16.25, y: 17.5 }, + Vec2 { x: f64::from_bits(0x7ff8000000000123), y: 1. }, + Vec2 { x: f64::INFINITY, y: f64::NEG_INFINITY }, + ]; + for levels in [1, 3, 32] { + for threshold in [-0., 0., 1e-6, 1., f64::MAX] { + let options = RobustTrackOptions { + lucas_kanade: LucasKanadeOptions { + window_radius: 1, + pyramid_levels: levels, + max_iterations: 2, + ..Default::default() + }, + max_forward_backward_error: threshold, + }; + compare(a.view(), a.view(), &[], options); + compare(a.view(), a.view(), &points, options); + } + } +} + +#[test] +fn stationary_texture_retains_accepted_identity_tracks() { + let a = texture::(96, 80, 0, 0); + let points = [Vec2 { x: 32., y: 32. }, Vec2 { x: 48., y: 40. }, Vec2 { x: 64., y: 48. }]; + let result = + track_points_forward_backward(a.view(), a.view(), &points, Default::default()).unwrap(); + assert!(result.accepted_count() > 0); + compare(a.view(), a.view(), &points, Default::default()); +} + +#[test] +fn custom_conversion_observations_keep_the_original_four_image_scans() { + use std::cell::Cell; + thread_local! {static CALLS: Cell = const {Cell::new(0)};} + #[derive(Clone, Copy)] + struct Observed(u8); + impl crate::PixelComponent for Observed { + fn to_f64(self) -> f64 { + CALLS.with(|c| { + let n = c.get(); + c.set(n + 1); + f64::from(self.0) + n as f64 * 1e-5 + }) + } + fn from_f64(v: f64) -> Self { + Self(v as u8) + } + } + let a = texture::(33, 35, 0, 0); + let points = [Vec2 { x: 16., y: 17. }]; + CALLS.with(|c| c.set(0)); + let expected = parent(a.view(), a.view(), &points, Default::default()).unwrap(); + assert_eq!(CALLS.with(Cell::get), 4 * 33 * 35); + CALLS.with(|c| c.set(0)); + let actual = + track_points_forward_backward(a.view(), a.view(), &points, Default::default()).unwrap(); + assert_eq!(CALLS.with(Cell::get), 4 * 33 * 35); + assert_eq!(actual.status(), expected.status()); + assert_eq!( + actual.next_points().iter().map(|p| [p.x.to_bits(), p.y.to_bits()]).collect::>(), + expected.next_points().iter().map(|p| [p.x.to_bits(), p.y.to_bits()]).collect::>() + ); + assert_eq!(actual.forward_backward_errors(), expected.forward_backward_errors()); +} diff --git a/crates/spatialrust-web/Cargo.toml b/crates/spatialrust-web/Cargo.toml index cf2aa204..369c6fed 100644 --- a/crates/spatialrust-web/Cargo.toml +++ b/crates/spatialrust-web/Cargo.toml @@ -55,3 +55,7 @@ web-sys = { workspace = true, optional = true, features = [ [[example]] name = "camera_mask_support" required-features = ["camera-tracking"] + +[[example]] +name = "lk_pyramid_reuse" +required-features = ["camera-tracking"] diff --git a/crates/spatialrust-web/examples/lk_pyramid_reuse.rs b/crates/spatialrust-web/examples/lk_pyramid_reuse.rs new file mode 100644 index 00000000..3bb72d93 --- /dev/null +++ b/crates/spatialrust-web/examples/lk_pyramid_reuse.rs @@ -0,0 +1,128 @@ +//! Synthetic in-process two-call versus robust LK comparison; no device access. +use spatialrust_image::Image; +use spatialrust_math::Vec2; +use spatialrust_vision::{ + track_points_forward_backward, track_points_lucas_kanade, RobustTrackOptions, VisionError, +}; +use std::{hint::black_box, time::Instant}; + +struct ParentTracks { + points: Vec>, + status: Vec, + errors: Vec, +} + +// Frozen parent public call graph, including original output allocations. +fn parent( + a: &Image, + b: &Image, + points: &[Vec2], + options: RobustTrackOptions, +) -> Result { + if !options.max_forward_backward_error.is_finite() || options.max_forward_backward_error < 0. { + return Err(VisionError::InvalidParameter( + "forward/backward threshold must be finite and non-negative".into(), + )); + } + let forward = track_points_lucas_kanade(a.view(), b.view(), points, options.lucas_kanade)?; + let backward = + track_points_lucas_kanade(b.view(), a.view(), forward.next_points(), options.lucas_kanade)?; + let mut status = Vec::with_capacity(points.len()); + let mut errors = Vec::with_capacity(points.len()); + for (i, p) in points.iter().enumerate() { + let valid = forward.status()[i] && backward.status()[i]; + let error = if valid { + (backward.next_points()[i].x - p.x).hypot(backward.next_points()[i].y - p.y) + } else { + f64::INFINITY + }; + status.push(valid && error <= options.max_forward_backward_error); + errors.push(error); + } + Ok(ParentTracks { points: forward.next_points().to_vec(), status, errors }) +} + +fn snapshot(points: &[Vec2], status: &[bool], errors: &[f64]) -> serde_json::Value { + serde_json::json!({"next_bits":points.iter().map(|p|[p.x.to_bits(),p.y.to_bits()]).collect::>(),"status":status,"error_bits":errors.iter().map(|v|v.to_bits()).collect::>()}) +} + +fn texture(w: usize, h: usize, dx: i32, dy: i32) -> Image { + Image::try_new( + w, + h, + (0..w * h) + .map(|i| { + let x = (i % w) as i32 - dx; + let y = (i / w) as i32 - dy; + let hash = (x as u32).wrapping_mul(73856093) ^ (y as u32).wrapping_mul(19349663); + ((hash ^ (hash >> 13)) & 255) as u8 + }) + .collect(), + ) + .unwrap() +} + +fn main() { + let mut rows = Vec::new(); + let options = RobustTrackOptions::default(); + for (width, height) in [(192, 144), (256, 192), (320, 240)] { + for count in [0, 8, 80] { + let a = texture(width, height, 0, 0); + let b = texture(width, height, 1, -1); + let points: Vec<_> = (0..count) + .map(|i| Vec2 { + x: (24 + (i * 17) % (width - 48)) as f64, + y: (24 + (i * 13) % (height - 48)) as f64, + }) + .collect(); + let expected = parent(&a, &b, &points, options).unwrap(); + let expected = snapshot(&expected.points, &expected.status, &expected.errors); + for _ in 0..4 { + let p = parent(&a, &b, &points, options).unwrap(); + assert_eq!(snapshot(&p.points, &p.status, &p.errors), expected); + let c = + track_points_forward_backward(a.view(), b.view(), &points, options).unwrap(); + assert_eq!( + snapshot(c.next_points(), c.status(), c.forward_backward_errors()), + expected + ); + } + let mut samples = Vec::new(); + for round in 0..4 { + for flavor in ["baseline", "candidate", "candidate", "baseline"] { + let (elapsed_ns, result) = if flavor == "baseline" { + let start = Instant::now(); + let p = black_box( + parent(black_box(&a), black_box(&b), black_box(&points), options) + .unwrap(), + ); + let ns = start.elapsed().as_nanos() as u64; + (ns, snapshot(&p.points, &p.status, &p.errors)) + } else { + let start = Instant::now(); + let c = black_box( + track_points_forward_backward( + black_box(a.view()), + black_box(b.view()), + black_box(&points), + options, + ) + .unwrap(), + ); + let ns = start.elapsed().as_nanos() as u64; + (ns, snapshot(c.next_points(), c.status(), c.forward_backward_errors())) + }; + assert_eq!(result, expected); + samples.push( + serde_json::json!({"round":round,"flavor":flavor,"elapsed_ns":elapsed_ns}), + ); + } + } + rows.push(serde_json::json!({"width":width,"height":height,"points":count,"samples":samples,"report":expected})); + } + } + println!( + "{}", + serde_json::json!({"schema":"spatialrust.lk-pyramid-reuse-benchmark.v1","synthetic_only":true,"rows":rows}) + ); +} diff --git a/docs/ROADMAP.md b/docs/ROADMAP.md index 5912dc93..c8e19307 100644 --- a/docs/ROADMAP.md +++ b/docs/ROADMAP.md @@ -1068,6 +1068,7 @@ evidence, and fail-closed acceptance gates live in | 146AR | Complete implementation: worker transport failure cleanup; physical fault qualification open | Complete readiness through cleanup, retain initialization send errors without unhandled rejections, and release messageerror sessions immediately; preserve old-event/replacement boundaries | Both parent transport failures reproduced; 84 JS, six asset and 82 real WASM/model browser controls. Reuse assets with zero compiler-cache growth and preserve 692 prior camera/renderer files plus scientific/native evidence. Message-error events are synthetic; physical phone/Safari and operational 80% remain open; `docs/MOBILE_CAMERA_DEMO.md` | | 146AS | Complete implementation: exact camera mask support summaries; physical performance open | Replace repeated support scans with owned empty/full states or bounded u32 prefixes, retaining inclusive support and validation/report semantics | 24 native tests; frozen native reports and 252 actual WASM report/84 rejection comparisons match. Existing 84 JS, six asset and 82 browser controls pass. Both native timing surveys retain adverse rows; isolated capped offline builds preserve shared artifacts. Phone/Safari and operational 80% remain open; `docs/CAMERA_MASK_SUPPORT.md` | | 146AT | Complete implementation: exact confidence-mask resize indexing; physical speed open | Hoist horizontal nearest-neighbor indices and retain strict threshold/full confidence validation plus independent transferable result storage | Parent/candidate 92 JS, six asset and 86 real WASM/model browser controls; all 102,400 horizontal size pairs and 42 browser masks match. Preserve all initial and interleaved timing rows plus a prelaunch guard rejection. Reuse tested WASM/vendor files with zero compilation/cache growth and preserve 2,354 earlier files. Phone/Safari and operational 80% remain open; docs/CAMERA_MASK_RESIZE.md | +| 146AU | In progress: reuse CPU LK pyramids across forward/backward passes | Share one private owned image-pyramid pair for built-in pixel components while preserving custom conversion observations, numerical order, validation and public APIs | Reserve before implementation: characterize the original two-call flow, compare exact coordinate/status/error bits, frozen native camera reports and actual parent/candidate WASM; retain all interleaved timing samples and cap fresh offline build storage. Physical-phone and operational acceptance remain open; benchmarks/lk-pyramid-reuse-plan.json | The operational maturity target is 80% on the explicitly requested real-data, multi-GPU/OS and public-release criteria. Historical engineering estimates in From 8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78 Mon Sep 17 00:00:00 2001 From: rsasaki0109 Date: Thu, 22 Oct 2026 09:14:09 +0900 Subject: [PATCH 2/3] perf(vision): reuse owned LK pyramids for robust tracking --- crates/spatialrust-vision/src/odometry.rs | 24 +++- crates/spatialrust-vision/src/optical_flow.rs | 120 +++++++++++------- 2 files changed, 95 insertions(+), 49 deletions(-) diff --git a/crates/spatialrust-vision/src/odometry.rs b/crates/spatialrust-vision/src/odometry.rs index e5ce581a..d4054899 100644 --- a/crates/spatialrust-vision/src/odometry.rs +++ b/crates/spatialrust-vision/src/odometry.rs @@ -125,9 +125,27 @@ pub fn track_points_forward_backward( "forward/backward threshold must be finite and non-negative".into(), )); } - let forward = track_points_lucas_kanade(previous, next, points, options.lucas_kanade)?; - let backward = - track_points_lucas_kanade(next, previous, forward.next_points(), options.lucas_kanade)?; + // Custom components may observe conversion calls; keep their original flow. + let scalar = std::any::TypeId::of::(); + let built_in = [ + std::any::TypeId::of::(), + std::any::TypeId::of::(), + std::any::TypeId::of::(), + std::any::TypeId::of::(), + ] + .contains(&scalar); + let (forward, backward) = if built_in { + let pair = + crate::optical_flow::LucasKanadePair::try_new(previous, next, options.lucas_kanade)?; + let forward = pair.track(points, false); + let backward = pair.track(forward.next_points(), true); + (forward, backward) + } else { + let forward = track_points_lucas_kanade(previous, next, points, options.lucas_kanade)?; + let backward = + track_points_lucas_kanade(next, previous, forward.next_points(), options.lucas_kanade)?; + (forward, backward) + }; let mut status = Vec::with_capacity(points.len()); let mut errors = Vec::with_capacity(points.len()); for (index, point) in points.iter().enumerate() { diff --git a/crates/spatialrust-vision/src/optical_flow.rs b/crates/spatialrust-vision/src/optical_flow.rs index 319c2611..f07e69ab 100644 --- a/crates/spatialrust-vision/src/optical_flow.rs +++ b/crates/spatialrust-vision/src/optical_flow.rs @@ -90,57 +90,85 @@ pub fn track_points_lucas_kanade( points: &[Vec2], options: LucasKanadeOptions, ) -> VisionResult { - let options = options.validate()?; - if previous.width() != next.width() || previous.height() != next.height() { - return Err(VisionError::ShapeMismatch( - "Lucas–Kanade frames must share width and height".into(), - )); - } - if previous.width() < 3 || previous.height() < 3 { - return Err(VisionError::InvalidDimensions( - "Lucas–Kanade requires at least 3x3 images".into(), - )); - } - let previous_pyramid = build_pyramid(previous, options.pyramid_levels)?; - let next_pyramid = build_pyramid(next, options.pyramid_levels)?; - let mut next_points = points.to_vec(); - let mut status = vec![true; points.len()]; - let scale = 1.0 / f64::from(1u32 << (options.pyramid_levels.saturating_sub(1) as u32)); - for point in &mut next_points { - point.x *= scale; - point.y *= scale; + let pair = LucasKanadePair::try_new(previous, next, options)?; + Ok(pair.track(points, false)) +} + +/// Owns the immutable CPU pyramids for one pair of frames. +pub(crate) struct LucasKanadePair { + previous_pyramid: Vec>, + next_pyramid: Vec>, + options: LucasKanadeOptions, +} + +impl LucasKanadePair { + pub(crate) fn try_new( + previous: ImageView<'_, T, 1>, + next: ImageView<'_, T, 1>, + options: LucasKanadeOptions, + ) -> VisionResult { + let options = options.validate()?; + if previous.width() != next.width() || previous.height() != next.height() { + return Err(VisionError::ShapeMismatch( + "Lucas–Kanade frames must share width and height".into(), + )); + } + if previous.width() < 3 || previous.height() < 3 { + return Err(VisionError::InvalidDimensions( + "Lucas–Kanade requires at least 3x3 images".into(), + )); + } + let previous_pyramid = build_pyramid(previous, options.pyramid_levels)?; + let next_pyramid = build_pyramid(next, options.pyramid_levels)?; + Ok(Self { previous_pyramid, next_pyramid, options }) } - let mut previous_guess = next_points.clone(); - for level in (0..options.pyramid_levels).rev() { - let level_scale = 1.0 / f64::from(1u32 << (level as u32)); - for (index, previous_point) in points.iter().enumerate() { - if !status[index] { - continue; - } - let mut guess = previous_guess[index]; - let target = - Vec2 { x: previous_point.x * level_scale, y: previous_point.y * level_scale }; - match track_one_level( - previous_pyramid[level].view(), - next_pyramid[level].view(), - target, - guess, - options, - ) { - Ok(updated) => { - guess = updated; - status[index] = true; + + pub(crate) fn track(&self, points: &[Vec2], reverse: bool) -> TrackedPoints { + let options = self.options; + let (previous_pyramid, next_pyramid) = if reverse { + (&self.next_pyramid, &self.previous_pyramid) + } else { + (&self.previous_pyramid, &self.next_pyramid) + }; + let mut next_points = points.to_vec(); + let mut status = vec![true; points.len()]; + let scale = 1.0 / f64::from(1u32 << (options.pyramid_levels.saturating_sub(1) as u32)); + for point in &mut next_points { + point.x *= scale; + point.y *= scale; + } + let mut previous_guess = next_points.clone(); + for level in (0..options.pyramid_levels).rev() { + let level_scale = 1.0 / f64::from(1u32 << (level as u32)); + for (index, previous_point) in points.iter().enumerate() { + if !status[index] { + continue; + } + let mut guess = previous_guess[index]; + let target = + Vec2 { x: previous_point.x * level_scale, y: previous_point.y * level_scale }; + match track_one_level( + previous_pyramid[level].view(), + next_pyramid[level].view(), + target, + guess, + options, + ) { + Ok(updated) => { + guess = updated; + status[index] = true; + } + Err(_) => status[index] = false, + } + previous_guess[index] = guess; + if level > 0 { + previous_guess[index].x *= 2.0; + previous_guess[index].y *= 2.0; } - Err(_) => status[index] = false, - } - previous_guess[index] = guess; - if level > 0 { - previous_guess[index].x *= 2.0; - previous_guess[index].y *= 2.0; } } + TrackedPoints { next_points: previous_guess, status } } - Ok(TrackedPoints { next_points: previous_guess, status }) } fn track_one_level( From 90d1e842c257dde0b1941ab0be8716eee7b32731 Mon Sep 17 00:00:00 2001 From: rsasaki0109 Date: Thu, 22 Oct 2026 09:33:55 +0900 Subject: [PATCH 3/3] docs(vision): record LK reuse parity and CPU timing evidence --- CHANGELOG.md | 6 + docs/ARCHITECTURE.md | 7 + docs/LK_PYRAMID_REUSE.md | 104 + docs/MOBILE_CAMERA_DEMO.md | 4 +- docs/ROADMAP.md | 2 +- .../receipts/2026-10-22_lk_pyramid_reuse.json | 2110 +++++++++++++++++ 6 files changed, 2231 insertions(+), 2 deletions(-) create mode 100644 docs/LK_PYRAMID_REUSE.md create mode 100644 docs/receipts/2026-10-22_lk_pyramid_reuse.json diff --git a/CHANGELOG.md b/CHANGELOG.md index c6455255..61d94383 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -19,6 +19,12 @@ removed no sooner than the next major (see `docs/API_STABILITY.md`). ## [Unreleased] +- Reuse one owned CPU image-pyramid pair across robust LK forward/backward + passes for standard pixel types. Preserve custom conversion observations, + exact tracking math, validation and public APIs. Add parent characterization, + frozen native/WASM parity and interleaved CPU timing evidence. See + [LK pyramid reuse](docs/LK_PYRAMID_REUSE.md). + - Reuse exact horizontal confidence-mask indices across rows and skip identity width transforms in the camera demo. Preserve complete confidence validation, strict threshold and independent transferable output. Add exhaustive size, diff --git a/docs/ARCHITECTURE.md b/docs/ARCHITECTURE.md index 6ccc84c2..34a5059d 100644 --- a/docs/ARCHITECTURE.md +++ b/docs/ARCHITECTURE.md @@ -75,6 +75,13 @@ indices need at most 640 logical bytes with no retained cache; frozen byte, ownership and actual-browser controls accompany both retained and interleaved timing observations. Device readbacks, model and Rust tracking stay unchanged. +[Forward/backward LK pyramid reuse](LK_PYRAMID_REUSE.md) owns two immutable +f32 pyramids per call and borrows them in both directions for built-in scalar +pixels. Custom components retain original conversion observations. Validation, +per-point numerical operations and public APIs remain; no cross-call cache or +implicit device copy is added. Frozen native and actual WASM reports establish +parity; CPU timing retains all conditions with physical qualification separate. + [Marching-tetrahedra topology](MESH_SURFACE_TOPOLOGY.md) orders quadrilateral cut vertices around their boundary and orients all changed cases toward increasing field values for the existing positive-oriented cube tetrahedra. diff --git a/docs/LK_PYRAMID_REUSE.md b/docs/LK_PYRAMID_REUSE.md new file mode 100644 index 00000000..f5bfac08 --- /dev/null +++ b/docs/LK_PYRAMID_REUSE.md @@ -0,0 +1,104 @@ +# Forward/backward LK pyramid reuse (146AU) + +Robust CPU LK tracking now builds one private owned pair of f32 image pyramids +and borrows it in both directions. For built-in u8/u16/f32/f64 pixels, four +pyramid constructions become two. The one-direction public API uses the same +private preparation and tracking code. Public signatures, dependencies, core, +device transfers, pyramid sampling and per-point numerical operations remain. + +PixelComponent is open to custom implementations whose scalar conversion may +have observable effects. A safe TypeId check selects only the four built-in +types; custom components retain the original two public calls and conversion +observations. There is no unsafe code or new trait restriction. + +Each call owns its pyramids with no retained cache or caller alias. At 320x320 +with three levels, each f32 pyramid contains 537,600 logical payload bytes; +the pair contains 1,075,200. Peak pyramid payload remains two pyramids. Halving +construction work does not promise half the tracker time or resident memory. + +## Compatibility evidence + +The [source-bound receipt](receipts/2026-10-22_lk_pyramid_reuse.json) records +90 passing vision tests before implementation and 90 afterward, +plus 24 web tests and a no-feature vision build (zero tests). Seven new characterization +tests retain the original two-public-call reference unchanged across both runs. +They compare exact coordinate/error bits and statuses for four pixel types, +odd dimensions, levels 1/2/3/5/32, strided subviews, nonfinite values, signed +zero, repeated/empty points, accepted identity tracks, options/shape/threshold +error priority and an observable custom converter. Source comparison also +checks unchanged point-loop operations, interpolation, pyramid construction +kernels and existing optical-flow tests. + +An independent frozen native executable from the previous Rust implementation +matches all 126 complete camera reports over 18 conditions. Its source has no +Rust changes through the parent merge. Actual parent and candidate WASM match +252 complete reports and 84 rejected calls over 42 conditions, including reset +and state recovery. Existing 92 JS controls, six asset checks and 86 actual +WASM/model browser controls pass. Captures are synthetic. Physical-phone and +iOS Safari qualification remain open. + +Both feature-scoped Clippy checks deny warnings, and workspace formatting passes. +One launcher failed before child creation because its version-suffix parser +also split the word vision. Preserve that original owner and failure record; +a fresh corrected owner runs all 19 successful guarded local commands. +Exact-head CI, merge and the matching public Pages/browser checks follow the +local receipt. + +## Interleaved CPU observations + +The prospective protocol is +C:/Users/rsasa/Workspace/SpatialRust/benchmarks/lk-pyramid-reuse-plan.json. +The driver is +C:/Users/rsasa/Workspace/SpatialRust/crates/spatialrust-web/examples/lk_pyramid_reuse.rs. +Run it with: + +```text +cargo run -p spatialrust-web --release --no-default-features --features camera-tracking --example lk_pyramid_reuse --locked --offline +``` + +Two fresh native release processes compare the frozen two-public-call flow +with the candidate robust API in the same executable. Each condition has four +checked warmups per function, then four baseline/candidate/candidate/baseline +rounds: eight timed calls per function. Every timed and warmup result is checked +outside the timer. Inputs, output ownership and result allocations are retained. + +The table shows milliseconds per robust call; ratios below 1 favor reuse. Keep +all samples and every condition, including adverse observations, in the receipt. +One Windows host worker is used. CPU affinity/frequency, other host load and +allocation effects are uncontrolled; there are no confidence intervals. These +measurements cover CPU LK, without proving physical-phone, GPU, AI-inference +or end-to-end browser speed. + +| Image | Points | Parent 1 ms | New 1 ms | New/parent 1 | Parent 2 ms | New 2 ms | New/parent 2 | +| --- | ---: | ---: | ---: | ---: | ---: | ---: | ---: | +| 192x144 | 0 | 0.677 | 0.331 | 0.489 | 0.657 | 0.326 | 0.496 | +| 192x144 | 8 | 10.555 | 10.099 | 0.957 | 10.061 | 10.019 | 0.996 | +| 192x144 | 80 | 77.125 | 76.683 | 0.994 | 73.148 | 76.354 | 1.044 | +| 256x192 | 0 | 1.006 | 0.501 | 0.498 | 1.184 | 0.595 | 0.503 | +| 256x192 | 8 | 8.198 | 7.787 | 0.950 | 9.054 | 8.694 | 0.960 | +| 256x192 | 80 | 93.479 | 96.306 | 1.030 | 124.876 | 118.447 | 0.949 | +| 320x240 | 0 | 1.478 | 0.726 | 0.491 | 1.749 | 0.864 | 0.494 | +| 320x240 | 8 | 12.166 | 11.207 | 0.921 | 14.125 | 13.539 | 0.959 | +| 320x240 | 80 | 111.254 | 117.147 | 1.053 | 106.745 | 97.264 | 0.911 | + +Of 18 paired medians, 15 are lower and +3 higher for the candidate. Empty-point calls still prepare the images, +preserving admission/conversion behavior; they isolate preparation overhead +and do not represent a useful tracking workload. + +## Storage and remaining qualification + +Fresh offline Cargo builds use a dedicated E-drive target with a prospective +1GiB logical-file limit, zero permitted shared-cache growth, two Cargo jobs, +one owned command at a time, five-second samples and a 900-second deadline. +The final local root contains 866,316,622 logical bytes, including +41,087,603 bytes of reused vendor hardlinks. Shared-cache growth is zero. +Preserve all 2,437 earlier camera/renderer files, 493 scientific JSON, +42 frozen native artifacts, room/reference outputs, both previous raw WASM +files and the resolved lock. No sensor, model, SDK, browser or toolchain +acquisition occurs. Public verification streams at most 40MiB. + +Operational 80% acceptance still needs calibration/timing and independent +motion, full-room accuracy, qualifying physical Linux hardware and integrated +mapping/semantics/viewer/interchange/release evidence. This CPU preparation +optimization does not close those gates. diff --git a/docs/MOBILE_CAMERA_DEMO.md b/docs/MOBILE_CAMERA_DEMO.md index 9a2afdd9..43939156 100644 --- a/docs/MOBILE_CAMERA_DEMO.md +++ b/docs/MOBILE_CAMERA_DEMO.md @@ -17,7 +17,9 @@ browser never requests a microphone, records a clip or persists a frame. ## Boundary and ownership Only the optional `spatialrust-web/camera-tracking` feature adds image and vision -odometry dependencies. Existing core and vision algorithms are unchanged. The +odometry dependencies. Core remains unchanged; [LK preparation reuse](LK_PYRAMID_REUSE.md) +shares the two CPU pyramids across the forward/backward passes while preserving +tracking math, validation and public APIs. The native `CameraTracker` accepts 64–320 pixels per axis and at most 80 tracks. Its copy-named WASM method validates lengths before copying JavaScript input. Invalid sizes, mask labels and nonfinite or non-increasing times fail before retained diff --git a/docs/ROADMAP.md b/docs/ROADMAP.md index c8e19307..8ae2e8be 100644 --- a/docs/ROADMAP.md +++ b/docs/ROADMAP.md @@ -1068,7 +1068,7 @@ evidence, and fail-closed acceptance gates live in | 146AR | Complete implementation: worker transport failure cleanup; physical fault qualification open | Complete readiness through cleanup, retain initialization send errors without unhandled rejections, and release messageerror sessions immediately; preserve old-event/replacement boundaries | Both parent transport failures reproduced; 84 JS, six asset and 82 real WASM/model browser controls. Reuse assets with zero compiler-cache growth and preserve 692 prior camera/renderer files plus scientific/native evidence. Message-error events are synthetic; physical phone/Safari and operational 80% remain open; `docs/MOBILE_CAMERA_DEMO.md` | | 146AS | Complete implementation: exact camera mask support summaries; physical performance open | Replace repeated support scans with owned empty/full states or bounded u32 prefixes, retaining inclusive support and validation/report semantics | 24 native tests; frozen native reports and 252 actual WASM report/84 rejection comparisons match. Existing 84 JS, six asset and 82 browser controls pass. Both native timing surveys retain adverse rows; isolated capped offline builds preserve shared artifacts. Phone/Safari and operational 80% remain open; `docs/CAMERA_MASK_SUPPORT.md` | | 146AT | Complete implementation: exact confidence-mask resize indexing; physical speed open | Hoist horizontal nearest-neighbor indices and retain strict threshold/full confidence validation plus independent transferable result storage | Parent/candidate 92 JS, six asset and 86 real WASM/model browser controls; all 102,400 horizontal size pairs and 42 browser masks match. Preserve all initial and interleaved timing rows plus a prelaunch guard rejection. Reuse tested WASM/vendor files with zero compilation/cache growth and preserve 2,354 earlier files. Phone/Safari and operational 80% remain open; docs/CAMERA_MASK_RESIZE.md | -| 146AU | In progress: reuse CPU LK pyramids across forward/backward passes | Share one private owned image-pyramid pair for built-in pixel components while preserving custom conversion observations, numerical order, validation and public APIs | Reserve before implementation: characterize the original two-call flow, compare exact coordinate/status/error bits, frozen native camera reports and actual parent/candidate WASM; retain all interleaved timing samples and cap fresh offline build storage. Physical-phone and operational acceptance remain open; benchmarks/lk-pyramid-reuse-plan.json | +| 146AU | Complete implementation: reuse CPU LK pyramids; physical speed open | Share one private owned pair for both directions with built-in scalar types; preserve custom conversion observations, validation and exact tracking math | 90 vision, 24 web tests plus a no-feature vision build; seven parent-characterized controls, 126 frozen native camera reports and 252 actual WASM reports/84 rejections match. Existing 92 JS, six asset and 86 browser controls pass. Retain all 18 paired timing rows and the prelaunch failure; capped offline build preserves shared artifacts. Phone/Safari and operational 80% remain open; docs/LK_PYRAMID_REUSE.md | The operational maturity target is 80% on the explicitly requested real-data, multi-GPU/OS and public-release criteria. Historical engineering estimates in diff --git a/docs/receipts/2026-10-22_lk_pyramid_reuse.json b/docs/receipts/2026-10-22_lk_pyramid_reuse.json new file mode 100644 index 00000000..2a33d176 --- /dev/null +++ b/docs/receipts/2026-10-22_lk_pyramid_reuse.json @@ -0,0 +1,2110 @@ +{ + "schema": "spatialrust.lk-pyramid-reuse-receipt.v1", + "slice": "146AU", + "date": "2026-10-22", + "recorded_at_utc": "2026-10-22T00:32:07.837589+00:00", + "parent_merge": "fcdb9d6acb34cffd0c033db94960c45db67b4bd9", + "baseline_source_commit": "cd3d0fb566214c13d78a25a4692c81c7df1ac5df", + "tested_source_commit": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "plan": { + "path": "C:\\Users\\rsasa\\Workspace\\SpatialRust\\benchmarks\\lk-pyramid-reuse-plan.json", + "bytes": 3793, + "sha256": "ebf8664a80fd5e6089a4d658726e5796e4f8d111f632a15173b9888a3a279cb4" + }, + "preflight": { + "path": "C:\\Users\\rsasa\\Workspace\\SpatialRust\\target\\automation\\lk-pyramid-reuse-preflight.json", + "bytes": 716796, + "sha256": "0d6acd3607c94ae12a66b88c03abcd34c0a340052fd4ede052c4f1c1f87b9981" + }, + "audit_script": { + "path": "C:\\Users\\rsasa\\Workspace\\SpatialRust\\target\\automation\\audit-lk-pyramid-reuse.py", + "bytes": 11328, + "sha256": "2bf82d9744786d115edb2a1146d5ca25eea3d36a615c358d855534aae39d30ca" + }, + "commands": { + "assets": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\assets.command.json", + "bytes": 194254, + "sha256": "9312bea16f4554d6b8ca5e633119d65d01a8f62ed56ec871e318742be5a34c91" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\assets.log", + "bytes": 109, + "sha256": "59753171660350c6735ee4b12925f50e7f8606c102caf33752e5551608bad819" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "base": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\base.command.json", + "bytes": 195532, + "sha256": "c231dea2385ce1b3fbbd82c580c66689705e914f4f804540354184509e32f0fc" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\base.log", + "bytes": 536, + "sha256": "ebeddabeae77284228351c8380d233ca96500d0a9a0400c5d0f87504e0568a2e" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "baseline-vision": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\baseline-vision.command.json", + "bytes": 200672, + "sha256": "689460cceb83886c483815e55ba00b927f9cac5b06baddcfe3a693adac0e4323" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\baseline-vision.log", + "bytes": 10632, + "sha256": "ec1f4c6696bdb734ae0af5414678ba6a10cdf3335ef5fc5898ba2e7a0faa35a3" + }, + "source_head": "cd3d0fb566214c13d78a25a4692c81c7df1ac5df", + "child_exit_status": 0 + }, + "benchmark-1": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\benchmark-1.command.json", + "bytes": 194594, + "sha256": "feca2a454de92da3b4afc57060dfa3daa4219ede2e588f2e90861910120f0329" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\benchmark-1.log", + "bytes": 26642, + "sha256": "682198200503fd469ebd2968763f960c955d15b598147dd428b2a350d6ad65f0" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "benchmark-2": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\benchmark-2.command.json", + "bytes": 194594, + "sha256": "782d86a25b3b4d3d08b2221d2f4c777284ff7f48dba0f29ffc511fc01f283c74" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\benchmark-2.log", + "bytes": 26651, + "sha256": "ba37d753a098d8dd05466c063fc52ff1ddbb262dc603a12bfa992ea38079ac39" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "browser": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser.command.json", + "bytes": 198673, + "sha256": "33181b4e26b5f20a56b9b51b6ba0765baabc2dd538a9989514c385b8321b5cf4" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser.log", + "bytes": 5746, + "sha256": "f80e3ea095f6f4f201fb135838cc77a11eb1e0e27aad9b3add93175ed333aab2" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "build-site": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\build-site.command.json", + "bytes": 194497, + "sha256": "53504e906f30ac4600608fedfb711587bee0f3c8456cd3d5087243db4377cd28" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\build-site.log", + "bytes": 133, + "sha256": "7e3e94d14c4cbf44d3f394bae8a059dff69dadd818ddb00458998f16fc0d4042" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "build": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\build.command.json", + "bytes": 196052, + "sha256": "04454135c5c4a1db281b4f4b1f5d949491b7014165372f4d692234c1db7e4381" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\build.log", + "bytes": 1859, + "sha256": "4dca8628e2c7a302b619621cde094203b2459c811b18fe2684f056e3fd305208" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "camera-build": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\camera-build.command.json", + "bytes": 194535, + "sha256": "386de22cbdaef8f76c0b52855cb1d3d81792b18bb3287cfea35a1ee7264759a8" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\camera-build.log", + "bytes": 569, + "sha256": "9059fea4c988dbe03231699b2cf8b930e04ca0c48274f3c007b4b675d774c778" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "candidate-camera": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\candidate-camera.command.json", + "bytes": 196900, + "sha256": "b0ac3b2106152108ad445a70c9e75c434dfcd44dc5ca9c5aac72526129e76f98" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\candidate-camera.log", + "bytes": 115316, + "sha256": "eef10d0736b70d90722997692108c6e754d7f8ed6114e5d4251636009774b5a6" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "clippy-vision": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\clippy-vision.command.json", + "bytes": 195357, + "sha256": "bdebdb15f6d04a1437bfba7a54aae393a8b91dc1d751ae608e68b11489ed70e7" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\clippy-vision.log", + "bytes": 2607, + "sha256": "7bb2028f37630929efac5c9cbc077315e47bdfdf00294d75be74c6c3363976bc" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "clippy-web": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\clippy-web.command.json", + "bytes": 194596, + "sha256": "a24d942687c716d09a0ce6ab844133b302c3747478531187990790c5a4c194be" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\clippy-web.log", + "bytes": 1450, + "sha256": "f6e2c9d759cef3e7033c32c761434706d8ae789dc7169f1ec00e9c7b4b8a8a40" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "fmt": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\fmt.command.json", + "bytes": 194394, + "sha256": "d92c8df1497ac72187e8b4bd9dcca7a92fb42f6154af849d8bb6583294b55dc4" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\fmt.log", + "bytes": 0, + "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "native": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\native.command.json", + "bytes": 196591, + "sha256": "240a436c6cee523ad4579a9be1e5061e44c25edf6368dbbfc0c4b8a9025a06c9" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\native.log", + "bytes": 7910, + "sha256": "b2b97d94ce4fd70955e199536a635d3fbf28e8d22ca89d926a5bdb7adc4f5da3" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "parent-camera": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\parent-camera.command.json", + "bytes": 196923, + "sha256": "9802643d41c09c042f980a632896e10b0fabb48d4b8b9600d8a135d7a6d85d6d" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\parent-camera.log", + "bytes": 115312, + "sha256": "6b5626babaaaa0615b8fd4b1293467bb021581d08b04f30ab375027cfdf2db17" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "parity": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\parity.command.json", + "bytes": 195103, + "sha256": "c433d67d8e792fdb398cfc7bb2096f4ec8eacaa5a8e0e889d90f7303328af65f" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\parity.log", + "bytes": 59, + "sha256": "2d8b0352f4d8c13a1a0dc3b0a33f52dd7378fcfd5179dcbc291c9171436380cf" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "unit": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\unit.command.json", + "bytes": 194218, + "sha256": "149ae0f21df687ce6f4b322048515d99b5682d292a4cb2a6e4fcd7e5b7847019" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\unit.log", + "bytes": 7330, + "sha256": "00cabe3ec516f0613e421862861d72706ca801cf7619d0de21b3c946b2c7c1a1" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "wasm": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\wasm.command.json", + "bytes": 197134, + "sha256": "9b979f4e17c35c936ce0855e5aa06b251bf06eefa567807bbebbc0ef1b35ed8a" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\wasm.log", + "bytes": 2249, + "sha256": "4fed338dd044739d1444dfd741e3108a7179d6871494b5875e0d87e136f2a372" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + }, + "web": { + "command": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\web.command.json", + "bytes": 195827, + "sha256": "69fb43117b1a84d69b4a3150532fd58565c8b1e0b1b15954d5b4081c433818fc" + }, + "log": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\web.log", + "bytes": 3448, + "sha256": "d354e2d1af4d8b955985843ac941940a4592102e1603318d636773d0b868bb1d" + }, + "source_head": "8b0fa1c1d7a18567d9cc61316cf1e16011e9fd78", + "child_exit_status": 0 + } + }, + "owned_commands": 19, + "successful_guarded_commands": 19, + "all_commands_terminal": true, + "retained_prelaunch_failure": { + "path": "C:\\Users\\rsasa\\Workspace\\SpatialRust\\target\\automation\\lk-pyramid-reuse-launch-failure.json", + "bytes": 566, + "sha256": "a8fee5385bbb7d8217f6808843fe79669bacc64ed792adc797c188593300d7bd" + }, + "baseline_vision_tests": 90, + "vision_tests": 90, + "web_tests": 24, + "base_tests": 0, + "new_parent_characterization_tests": 7, + "unit_tests": 92, + "asset_controls": 6, + "browser_controls": 86, + "wasm_report_comparisons": 252, + "wasm_rejection_comparisons": 84, + "wasm_cases": 42, + "wasm_parity_report": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\parity-artifacts\\report.json", + "bytes": 9299, + "sha256": "3c296a4293d02c71c1011122b608ee3d776de6fa9245dad82f0e24272fd39dc1" + }, + "browser_report": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\report.json", + "bytes": 12535, + "sha256": "b1d06c573c9084b398ae2e744342934f82368de20078e9ba515e60d46c4b0503" + }, + "screenshots": [ + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-idle.png", + "bytes": 218678, + "sha256": "95637b49b81d23999c2b29f148f317a79a4c021b31648a9f1e0617df49aeb38c" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-tracking.png", + "bytes": 283371, + "sha256": "e9bc9dec91c2761332014e3c02dd1b6ce759fc511ea388cb81310605f6476c06" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-ai.png", + "bytes": 284355, + "sha256": "91562590b7c08e7f1c4ecef9ab5d9eb4cd08d3173af00ea9b3aba9bcf8e71b8b" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\desktop-idle.png", + "bytes": 437103, + "sha256": "bb4e7619a7b023d0f18c9324a7d3db7d42ae7e51274401ddc37d4bd9a99b9ecb" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-portrait-camera-256.png", + "bytes": 186752, + "sha256": "fc1dc82a497f908b545ce574a5ef74824f49ad0df2ba97cc53a8792b5e7dc40b" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-light-sample.png", + "bytes": 272832, + "sha256": "284320d623d395c89c5a3f662d2a14d754c6ba36cb6d0f2382f8eefdd4bf3afb" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-portrait-camera-192.png", + "bytes": 187771, + "sha256": "808117113d7a962ff90032085ad1329320de18e83e7b6bb6ef848daa39940bc6" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-capture-rate.png", + "bytes": 263319, + "sha256": "b515d0b4fe97d6f22e35a51639700c0b6f97adc66eb3df84a04e0438ec8ebfd9" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-source-recovery.png", + "bytes": 272904, + "sha256": "24339d4b1a4d715037802c9ee191581f036fb7574bf4dfed89c0af7eca6367d0" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-progress-timeout.png", + "bytes": 223512, + "sha256": "407f9fb64a39dead84be64b1b9a775af2abb7673109358c3f38c00e5de3cb0d2" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-progress-restart.png", + "bytes": 174315, + "sha256": "1aca03a4f1ed4a0c774a19f37aa823da20d139aaf41fb78441380ac69fa9742c" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-result-timeout.png", + "bytes": 223214, + "sha256": "981db1fb413285c2533c220e7085bebff51c52f0c22087672feb191ea07027ff" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-result-restart.png", + "bytes": 175451, + "sha256": "3d176331ce6a412d078db2eb849f86f42a7fb13d9bc2b951ea983065781f54cc" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-capture-timeout.png", + "bytes": 223848, + "sha256": "5273760ba0ae3cba6823fd84cdb5bf0fb91b79a7809b95e5aee417482670cf14" + }, + { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\browser-artifacts\\mobile-capture-restart.png", + "bytes": 175332, + "sha256": "738b3f6021db8ff275e6b795f28d9652b485837e643027972c283c78dd8249e2" + } + ], + "site_build": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\site\\camera\\build.json", + "bytes": 4192, + "sha256": "cf968095b865b1ba889d1af0beaf67c3e3b22296a8cbbbb38f4e1d7ed70224ad" + }, + "baseline_camera_executable": { + "path": "E:\\SpatialRustBuild\\camera-mask-support-v1\\candidate-camera-mask-support.exe", + "bytes": 302080, + "sha256": "9953ff64c0b3d35b978a6e7e2b567b7356869c9b608b6c2752a16c062cd74a08" + }, + "baseline_camera_source": "749008ca2148ede42579ea53aa10bbf7cf9c3cb3", + "candidate_camera_executable": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\camera_mask_support.exe", + "bytes": 302080, + "sha256": "49101ecd1d6bb452f011f41f398fcbf8b051725b859703bfe035bdefafa134e7" + }, + "native_camera_report_comparisons": 126, + "benchmark_executable": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\lk_pyramid_reuse.exe", + "bytes": 246272, + "sha256": "3c7cb2f2f707469b9612358f640fbbaa4568199cfba06daf9f7b88e4867f8912" + }, + "baseline_raw_wasm": { + "path": "E:\\SpatialRustBuild\\camera-mask-support-v1\\cargo\\wasm32-unknown-unknown\\release\\spatialrust_web.wasm", + "bytes": 1029275, + "sha256": "a397a70417941766400276c3580f1cd53808ed76690cdecb9ad73b3e6068d74a" + }, + "candidate_raw_wasm": { + "path": "E:\\SpatialRustBuild\\lk-pyramid-reuse-v1\\cargo\\wasm32-unknown-unknown\\release\\spatialrust_web.wasm", + "bytes": 1028728, + "sha256": "e4b2be1a5c833e4ad30b3e31f6fba8cd4124b89d7dda739726177247a020800a" + }, + "unchanged_lock": { + "path": "C:\\Users\\rsasa\\Workspace\\SpatialRust\\Cargo.lock", + "bytes": 118086, + "sha256": "e9d0a244c69b4ea193c7ebcd61e404de8071a53b71ff269c2c8dbe0f506484cc" + }, + "benchmark_rows": [ + { + "survey": 1, + "width": 192, + "height": 144, + "points": 0, + "samples": [ + { + "elapsed_ns": 638200, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 321600, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 330200, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 659300, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 677000, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 332100, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 328600, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 672800, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 696400, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 344800, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 350000, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 706700, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 717800, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 341200, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 326100, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 676300, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 676650.0, + "candidate_median_ns": 331150.0, + "candidate_over_baseline": 0.4893962905490283 + }, + { + "survey": 1, + "width": 192, + "height": 144, + "points": 8, + "samples": [ + { + "elapsed_ns": 10581700, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 10097300, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 10222400, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 10599800, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 10791100, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 10200200, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 10114000, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 10616900, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 10527700, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 10100900, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 9877100, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 8161400, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 7994400, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 7448200, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 7631700, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 8029800, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 10554700.0, + "candidate_median_ns": 10099100.0, + "candidate_over_baseline": 0.9568343960510484 + }, + { + "survey": 1, + "width": 192, + "height": 144, + "points": 80, + "samples": [ + { + "elapsed_ns": 78732800, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 86507500, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 95414500, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 75516800, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 72675000, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 75296700, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 72375000, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 79123500, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 75109500, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 74432100, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 78068300, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 86487000, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 83073500, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 73713300, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 86798700, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 73904800, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 77124800.0, + "candidate_median_ns": 76682500.0, + "candidate_over_baseline": 0.9942651390992262 + }, + { + "survey": 1, + "width": 256, + "height": 192, + "points": 0, + "samples": [ + { + "elapsed_ns": 978900, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 495600, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 638800, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 1027300, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 1014700, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 480200, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 487100, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 997500, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 993700, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 500700, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 513100, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 989200, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 1019400, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 502300, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 509900, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 1019600, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 1006100.0, + "candidate_median_ns": 501500.0, + "candidate_over_baseline": 0.49845939767418745 + }, + { + "survey": 1, + "width": 256, + "height": 192, + "points": 8, + "samples": [ + { + "elapsed_ns": 7815500, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 7599700, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 7523100, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 8246400, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 8034100, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 7948000, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 7625400, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 8208700, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 8146100, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 8008700, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 7607300, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 8491900, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 8186600, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 8666900, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 8277000, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 8460700, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 8197650.0, + "candidate_median_ns": 7786700.0, + "candidate_over_baseline": 0.9498697797539539 + }, + { + "survey": 1, + "width": 256, + "height": 192, + "points": 80, + "samples": [ + { + "elapsed_ns": 112353500, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 93773600, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 126412500, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 100264600, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 77793500, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 92991000, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 98839200, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 85113000, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 108382400, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 85393800, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 126928000, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 104087100, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 83118700, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 101145400, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 81535600, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 86694100, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 93479350.0, + "candidate_median_ns": 96306400.0, + "candidate_over_baseline": 1.030242508104731 + }, + { + "survey": 1, + "width": 320, + "height": 240, + "points": 0, + "samples": [ + { + "elapsed_ns": 1608000, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 972400, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 686000, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 1455800, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 1489300, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 700200, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 655500, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 1467200, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 1426600, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 751200, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 780400, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 1524100, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 1515000, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 681200, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 859200, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 1454600, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 1478250.0, + "candidate_median_ns": 725700.0, + "candidate_over_baseline": 0.4909183155758498 + }, + { + "survey": 1, + "width": 320, + "height": 240, + "points": 8, + "samples": [ + { + "elapsed_ns": 10280600, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 8479200, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 8980300, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 10643000, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 12417600, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 10773500, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 12089400, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 13496400, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 9719300, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 11640200, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 10682700, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 11919500, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 16251900, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 11657800, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 14200500, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 12413500, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 12166500.0, + "candidate_median_ns": 11206850.0, + "candidate_over_baseline": 0.9211235770353019 + }, + { + "survey": 1, + "width": 320, + "height": 240, + "points": 80, + "samples": [ + { + "elapsed_ns": 102622400, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 115520100, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 111898100, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 126214500, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 112179700, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 116153800, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 165211200, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 133010700, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 111950600, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 126728300, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 118140500, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 110556600, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 96582000, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 133268200, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 96108200, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 80576200, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 111253600.0, + "candidate_median_ns": 117147150.0, + "candidate_over_baseline": 1.0529740161217256 + }, + { + "survey": 2, + "width": 192, + "height": 144, + "points": 0, + "samples": [ + { + "elapsed_ns": 684800, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 327800, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 331800, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 726000, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 643600, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 328800, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 328100, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 678500, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 659100, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 310900, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 323800, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 651000, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 655300, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 310700, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 303700, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 621000, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 657200.0, + "candidate_median_ns": 325800.0, + "candidate_over_baseline": 0.4957395009129641 + }, + { + "survey": 2, + "width": 192, + "height": 144, + "points": 8, + "samples": [ + { + "elapsed_ns": 8420600, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 8842500, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 10221700, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 10369700, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 9190400, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 8862400, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 9815900, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 9751600, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 11579200, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 17906700, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 12791500, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 10850200, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 9523900, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 11076500, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 9692800, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 10788100, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 10060650.0, + "candidate_median_ns": 10018800.0, + "candidate_over_baseline": 0.995840229011048 + }, + { + "survey": 2, + "width": 192, + "height": 144, + "points": 80, + "samples": [ + { + "elapsed_ns": 89387700, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 88178300, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 91829800, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 70754200, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 72565300, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 73565500, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 75943400, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 72867800, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 72949200, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 79294500, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 76763700, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 75044100, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 73346000, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 73297100, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 74732100, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 96821400, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 73147600.0, + "candidate_median_ns": 76353550.0, + "candidate_over_baseline": 1.0438285056515866 + }, + { + "survey": 2, + "width": 256, + "height": 192, + "points": 0, + "samples": [ + { + "elapsed_ns": 8164100, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 1088300, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 842200, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 2029000, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 1166700, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 580100, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 587100, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 1182900, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 1119600, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 538400, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 562500, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 1171900, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 1184500, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 603200, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 612700, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 1264500, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 1183700.0, + "candidate_median_ns": 595150.0, + "candidate_over_baseline": 0.5027878685477739 + }, + { + "survey": 2, + "width": 256, + "height": 192, + "points": 8, + "samples": [ + { + "elapsed_ns": 9646300, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 8541400, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 9364300, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 8704900, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 9261700, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 8088800, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 8144000, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 8846300, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 8769800, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 8847300, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 7997100, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 8711400, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 9507800, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 10382200, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 10662500, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 11286300, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 9054000.0, + "candidate_median_ns": 8694350.0, + "candidate_over_baseline": 0.9602772255356748 + }, + { + "survey": 2, + "width": 256, + "height": 192, + "points": 80, + "samples": [ + { + "elapsed_ns": 138610800, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 137715800, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 203786600, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 153757100, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 128236400, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 99177200, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 179436200, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 119064000, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 102972900, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 93643900, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 81740400, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 109811000, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 121516400, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 89643000, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 140740100, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 146807100, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 124876400.0, + "candidate_median_ns": 118446500.0, + "candidate_over_baseline": 0.9485098865758462 + }, + { + "survey": 2, + "width": 320, + "height": 240, + "points": 0, + "samples": [ + { + "elapsed_ns": 1539000, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 801900, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 796800, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 1745400, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 2503500, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 898500, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 794400, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 1732100, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 1666400, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 902500, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 896300, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 1752200, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 1906700, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 831900, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 941600, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 2055600, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 1748800.0, + "candidate_median_ns": 864100.0, + "candidate_over_baseline": 0.4941102470265325 + }, + { + "survey": 2, + "width": 320, + "height": 240, + "points": 8, + "samples": [ + { + "elapsed_ns": 24859900, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 15550700, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 14755500, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 14201200, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 14048300, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 10894700, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 10199200, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 15309000, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 15747300, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 12322000, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 9215400, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 12085600, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 13234900, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 15791300, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 20349400, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 11457200, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 14124750.0, + "candidate_median_ns": 13538750.0, + "candidate_over_baseline": 0.9585125400449566 + }, + { + "survey": 2, + "width": 320, + "height": 240, + "points": 80, + "samples": [ + { + "elapsed_ns": 144987400, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 121483800, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 88313100, + "flavor": "candidate", + "round": 0 + }, + { + "elapsed_ns": 104322500, + "flavor": "baseline", + "round": 0 + }, + { + "elapsed_ns": 102066500, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 109181600, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 89210000, + "flavor": "candidate", + "round": 1 + }, + { + "elapsed_ns": 109167200, + "flavor": "baseline", + "round": 1 + }, + { + "elapsed_ns": 87621000, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 80457700, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 95921100, + "flavor": "candidate", + "round": 2 + }, + { + "elapsed_ns": 113418400, + "flavor": "baseline", + "round": 2 + }, + { + "elapsed_ns": 93499600, + "flavor": "baseline", + "round": 3 + }, + { + "elapsed_ns": 160367500, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 98607600, + "flavor": "candidate", + "round": 3 + }, + { + "elapsed_ns": 155858900, + "flavor": "baseline", + "round": 3 + } + ], + "baseline_median_ns": 106744850.0, + "candidate_median_ns": 97264350.0, + "candidate_over_baseline": 0.9111854108184142 + } + ], + "timing_summary": { + "paired_rows": 18, + "lower_candidate_median_rows": 15, + "higher_candidate_median_rows": 3, + "minimum_ratio": 0.4893962905490283, + "maximum_ratio": 1.0529740161217256 + }, + "timing_scope": "Frozen original two-public-call flow and candidate robust API in the same process; compare complete coordinates/status/error bits outside timing. Keep all samples and adverse rows. CPU affinity/frequency, other host load and allocation effects are uncontrolled. No physical-phone, GPU or end-to-end speed claim.", + "pyramid_constructions_before": 4, + "pyramid_constructions_after": 2, + "peak_pyramids": 2, + "logical_pair_payload_bytes_at_320_square_three_levels": 1075200, + "storage": { + "owned_metadata_bytes": 866316622, + "cache_bytes": 13386648799, + "positive_cache_growth_bytes": 0, + "combined_bytes": 866316622, + "free_bytes": { + "C": 69269852160, + "E": 874743611392 + } + }, + "vendor_hardlink_bytes": 41087603, + "non_vendor_owned_bytes": 825229019, + "preserved_scientific_json": 493, + "preserved_frozen_native": 42, + "preserved_previous_camera_files": 2437, + "forbidden_adapter_matches": 0, + "sdk_model_acquisition_bytes": 0, + "sensor_downloads": 0, + "real_user_camera_reads": 0, + "physical_phone_tested": false, + "ios_safari_tested": false, + "operational_80_percent_proven": false, + "release_verification": "Exact-head CI, merge and matching Pages/public browser checks follow this source-bound receipt." +}