Sudden violent incidents such as gunfire require a rapid protective response. Traditional protective barriers require cognitive processing to recognize the threat before physically closing the barrier. This end-to-end process takes approximately 30-60 seconds. Studies show that reducing protective response time to sub-second can reduce casualty risk significantly. The purpose of this research was to design, implement, and evaluate an automatic barrier deployment system triggered by machine-learning-based threat detection to reduce protective response time to sub-second levels.
The system integrates gunshot acoustics and vision-based shooter detection using machine learning (ML) models that are executed on an edge computing platform. Audio signals are processed into log-mel spectrograms and classified using a convolutional neural network (CNN), while video frames from a USB camera are analyzed using another CNN-based object detection model. Upon threat detection, a wireless command is transmitted to ESP32, activating a relay to control the robotic system's motors and deploying a polycarbonate protective barrier.
Experimental data were collected across multiple trials under home-based conditions. Threat detection accuracy averaged about 90%. ML-only detection latency averaged approximately 52.9 milliseconds for gunshot sound and 118.5 milliseconds for visual detection. Deployment time from threat detection to barrier deployment averaged 650 milliseconds, about 50-70 times faster than traditional barriers. System performance was evaluated as a function of distance and background noise, demonstrating gradual degradation rather than abrupt failure. The results show that automatic deployment consistently provides a better, more reliable response, which could potentially drastically reduce fatalities.