Skip to content

FilmonMeharii/Counting-People-Using-Video-Camera

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

People Counting System Using Video Camera

A real-time people counting system that uses Intel RealSense camera and YOLO object detection to detect and count people in a classroom. The system also leverages accuracy and logs occupancy data for analysis.

Features

  • Real-Time People Detection and Tracking:
    • Uses YOLO object detection to identify and track people in video frames.
  • Depth-Based Filtering:
    • Uses depth data from RealSense cameras to filter out false positives.
  • Automatic Image Capture:
    • Captures and saves combined images (RGB, IR, depth, and detection overlays) every 15 minutes.
  • Data Logging:
    • Logs occupancy data (timestamp, current count, max count) to CSV files.
  • Visualization:
    • Displays real-time visual feedback, including bounding boxes, counts, and detection overlays.
  • Occupancy Analysis:
    • Analyzes logged data to display recent occupancy statistics and generate data tables.

Requirements

  • Hardware:
    • Intel RealSense camera (or a regular webcam).
  • Software:
    • Python 3.8+
    • OpenCV
    • Pyrealsense2
    • Ultralytics YOLO
    • NumPy
    • MediaPipe (optional for pose detection)

Installation

  1. Clone the repository:
git clone https://github.com/yourusername/Counting-People-Using-Video-Camera.git
cd Counting-People-Using-Video-Camera
  1. Install required packages:
pip install -r requirements.txt
  1. Download YOLO model weights:
    • Place the YOLO model file (e.g., yolov8m.pt) in the appropriate directory.

Usage

  1. Run the program:
cd src
python people_counter.py
  1. Controls:
  • Press 'q' to quit the program
  1. Analyze logged data:
    • Use the occupancy_analysis.py script to analyze logged data and generate statistics:
      python occupancy_analysis.py

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages