# vaibhavgovindwar/yolov8-multiple-object-detection architecture

> Architecture diagram of the GitHub repository vaibhavgovindwar/yolov8-multiple-object-detection, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-21). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/vaibhavgovindwar/yolov8-multiple-object-detection
- Repository: https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection

## Overview

A single Python script implements the product: it selects an inference device, opens a recorded MP4, runs YOLOv8 frame by frame, annotates detections and FPS, then writes and displays the result. The README also documents early stopping with Q and automatic weight downloading through Ultralytics. The graph reflects the shown script and documented behavior; it does not imply separate tracking or counting features, which are explicitly future work.

Main entry points: [`yolov8_detection.py`](https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection/blob/main/yolov8_detection.py) (Detection pipeline)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_processing["Video detection"]
  node_pipeline["Detection pipeline"]
  node_device["CUDA or CPU"]
  node_input["Recorded MP4"]
  node_model["YOLOv8 model"]
  node_output["Annotated MP4"]
  node_display["Preview window"]
end

node_user(("Video operator"))

node_user -->|"runs script"| node_pipeline
node_pipeline -->|"selects device"| node_device
node_pipeline -->|"loads and invokes"| node_model
node_pipeline -->|"reads frames"| node_input
node_pipeline -->|"writes annotations"| node_output
node_pipeline -->|"shows frames"| node_display
node_user -->|"stops with Q"| node_display

click node_pipeline "https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection/blob/main/yolov8_detection.py"
click node_device "https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection/blob/main/yolov8_detection.py"
click node_input "https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection/blob/main/yolov8_detection.py"
click node_model "https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection/blob/main/yolov8_detection.py"
click node_output "https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection/blob/main/yolov8_detection.py"
click node_display "https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection/blob/main/yolov8_detection.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_pipeline,node_device,node_input,node_model,node_output,node_display toneBlue
class node_user toneIndigo
```

## Components

### Video detection

- [Detection pipeline](https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection/blob/main/yolov8_detection.py): `yolov8_detection.py`
- [CUDA or CPU](https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection/blob/main/yolov8_detection.py): `yolov8_detection.py`
- [Recorded MP4](https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection/blob/main/yolov8_detection.py): `yolov8_detection.py`
- [YOLOv8 model](https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection/blob/main/yolov8_detection.py): `yolov8_detection.py`
- [Annotated MP4](https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection/blob/main/yolov8_detection.py): `yolov8_detection.py`
- [Preview window](https://github.com/vaibhavgovindwar/yolov8-multiple-object-detection/blob/main/yolov8_detection.py): `yolov8_detection.py`

### Other components

- **Video operator**

## Connections

- Video operator → Detection pipeline: runs script (evidence: `README.md`)
- Detection pipeline → CUDA or CPU: selects device (evidence: `yolov8_detection.py`)
- Detection pipeline → YOLOv8 model: loads and invokes (evidence: `yolov8_detection.py`)
- Detection pipeline → Recorded MP4: reads frames (evidence: `yolov8_detection.py`)
- Detection pipeline → Annotated MP4: writes annotations (evidence: `yolov8_detection.py`)
- Detection pipeline → Preview window: shows frames (evidence: `yolov8_detection.py`)
- Video operator → Preview window: stops with Q (evidence: `README.md`)
