Problem
aiGait digitizes video-based gait assessment to reduce clinicians' manual workload. The model worked in development but was too slow on mobile/edge devices, and in clinics medical staff often stepped into the frame and blocked the patient.
Approach and decisions
- The model is a cascade that detects objects first and then estimates the skeleton; I moved inference from PyTorch to ONNX Runtime.
- Moved pre- and post-processing onto the device and vectorized it to cut overhead.
- Used frame sampling and skipping to reduce the frames needing full inference, and ran capture and inference asynchronously on multiple threads.
- Dropped frames where occlusion was detected, or interpolated them from neighboring frames, so bad skeletons would not distort gait parameters.
Result
- Inference on mobile/edge devices became about 300% faster.
- Also built an AI-assisted literature review workflow covering 100+ studies on gait disorders and rehabilitation, producing a method comparison table and an internal knowledge base.
