Skip to main content

Module respiration_rate_from_motion_trace

Module respiration_rate_from_motion_trace 

Source
Expand description

Respiratory rate from a motion energy / vertical displacement trace.

Pure spectral peak in the breath band (~0.1–0.5 Hz): demean → dense DFT power scan → residual-band SNR → optional parabolic refine → fail closed. No learned weights / training.

Functions§

respiration_rate_from_motion_trace
Estimate respiration (breaths/min) from per-frame scalar motion (chest ROI mean, vertical optical-flow energy, …).
spectral_rr_peak
Core spectral peak search in the respiratory band. Fail closed on low SNR.