nx_deadair.nx
buildroot/runtime/nx_deadair.nx
about
nx_deadair.nx -- per-interval temporal-activity metric for cam-stream
dead-air detection / TiVo-style trimming. R0 of the MEDIA-STUDIO arc.
"Dead air" = the subject/scene is not changing (static hold, frozen
recording, empty room). We measure the FRACTION of pixels whose
frame-to-frame luma change exceeds a sensor-noise floor, expressed in
per-mille (parts per thousand, 0..1000).
Why a noise floor is REQUIRED (not optional):
Real sensor noise makes nearly every pixel differ by a small amount
frame-to-frame. A naive sum/count of |a-b| therefore reads a static
but noisy frame as "active" -- a false positive that would defeat
trimming. Flooring counts a pixel as "changed" only when its luma
delta exceeds the noise floor, so only genuine subject/scene motion
survives. The gate proves this with floor=0 vs floor=N contrast.
Thresholds are CALLER-SUPPLIED -- the metric carries NO magic numbers.
Callers source noise_floor and active_permille from svc-config.
genealogy_id: frame_differencing + scene_change_detection
(commercial/dead-air advance lineage -- attribution
UNVERIFIED, record-hint only; do not cite as sourced)
lineage_id: frame_difference + noise_floor + changed_pixel_fraction
nx_safety_envelope:
intended_use: "Temporal activity classification for recording
trim/cut. Foundation for the media-studio editor."
verdict: NOT_YET_EVALUATED
license_tier: ORIGINAL
dependencies 2 imports · 1 importers
imports: syscalls.nxnx_image.nx
imported by: nx_deadair_gate.nx
structs
| none |
consts
| 34 | const NX_DEADAIR_ACTIVE: i64 = 1 |
| 35 | const NX_DEADAIR_DEAD: i64 = 0 |
functions
| 40 | func nx_deadair_activity_permille(a: *Image, b: *Image, noise_floor: i64) -> i64 |
| 62 | func nx_deadair_classify(activity_permille: i64, active_permille: i64) -> i64 |