ReadMe for Surveillance System with Edge to Cloud Video Processing
Overview
This project demonstrates a video processing surveillance system designed to enhance safety in residential areas and along roads by identifying and alerting residents and authorities to the presence of dangerous animals. The system integrates edge devices and cloud servers to ensure quick and accurate responses while minimizing data transmission to the cloud. A feedback mechanism is implemented to monitor, understand, and adjust to changing conditions, ensuring the system adheres to defined Service Level Objectives (SLOs).
System Components
Camera
- Function: Captures video frames from a camera or video file.
- Process: Resizes frames, serializes them using pickle, and sends them over the network.
- Connection: Establishes a connection with the Motion Detection service to send video frames for motion detection.
Motion Detection (Edge)
- Technology Used: OpenCV and socket programming.
- Function: Continuously receives video frames from cameras, applies motion detection algorithms to detect significant changes in consecutive frames.
- Alert: Triggers alerts when motion is detected and forwards relevant frames to the Object Recognition component for further analysis.
Object Recognition (Cloud)
- Technology Used: YOLOv3 model.
- Function: Receives video frames from Motion Detection. Performs object detection to identify dangerous animals.
- Alert: Notifies affected areas if a dangerous animal is detected.
Scenarios Affecting Performance
Normal Conditions
- Description: System detects and processes video frames efficiently, meeting all SLOs without any issues.
High Traffic Load
- Description: During peak hours or significant increase in video feeds, the system experiences higher traffic load.
- Impact: Potential decrease in frame rate frequency.
High Processing Time
- Description: Some nodes may experience longer processing times due to a lack of computational resources.
Large Distance
- Description: Motion Detection deployed far from cameras.
- Impact: Delay in frame transmission.
Metrics Collected
- Number of frames received per second.
- Execution time.
- Duration of Edge-to-Cloud transmission.
- CPU usage.
Actions
- Scaling CPU on Cloud: Adjusting computational resources on the cloud to handle increased load.
- Moving an instance of Motion Detector: Repositioning the Motion Detection service to optimize performance.
Service Level Objectives (SLOs)
- Response Time: The time taken to detect and respond to an event.
- Frame Dropping Rate: The frequency of dropped frames during transmission or processing.
Feedback Mechanism
- Role: Monitors the application’s status in real-time, evaluates against SLOs, and identifies metrics significantly affecting SLOs.
- Action: In critical situations, applies corrective actions and records the impact on metrics to ensure optimal performance.
Diagram
Figure 1: Real-time detection system for identifying and alerting dangerous animals.
References
- OpenCV library for motion detection.
- YOLOv3 model for object recognition.
Ensure all components are properly configured and connected before deploying the system. Regularly monitor performance metrics and utilize the feedback mechanism to maintain efficient and effective surveillance operations.