What is YOLO? A widely used object detection model for robots
Atlasbot · 18/8/2026 · 11 min read
When robots need to "see and name" objects around — people, cargo boxes, and real-time obstacles — YOLO (You Only Look Once) is almost the first option mentioned in the robotics/AI community. This is a family of object detection models known for their fast processing speed, sufficient to run in real time even on embedded computers.
Key concepts
Previous object detection methods often required scanning the image multiple times with multiple sliders of various sizes to find the — object, which was slow and resource - intensive. YOLO changes the approach: processing the entire frame in a single pass through neural networks, returning simultaneously the bounding box and labels of all detectable objects — which is why YOLO is so much faster than the old methods and suited for real-time applications such as robotics.
How it works
For each object detected, YOLO returns bounding box (the rectangular frame coordinates surrounding the object), class (the object type name, depending on the trained model data set), and confidence score (the prediction confidence, from 0 to 1).
from ultralytics import YOLO
model = YOLO("yolov8n.pt") # lightweight "nano" — version, embedded computer compliant
results = model("frame.jpg")
for box in results[0].boxes:
print(box.cls, box.conf, box.xyxy) # label, reliability, box coordinates
YOLO has multiple versions (v5, v8, v11...) and each version has multiple model sizes (nano, small, medium, large) — the larger the model is accurate but the slower.
Technical details
Formulas
The inference time per frame determines the maximum pipeline achievable FPS — critical when integrated into ROS2 running in parallel with other tasks:
Maximum_FPS = 1 / Inference_time_per_frame
Example: yolov8n on Jetson Orin Nano (GPU), inference ~15ms/frame
Maximum_FPS ≈ 1/0.015 ≈ 66 FPS (ample for a typical 30fps camera)
Example: yolov8n on CPU only (Raspberry Pi 4), inference ~200ms/frame
Maximum_FPS ≈ 1/0.2 = 5 FPS (cannot keep up with a 30fps camera; frames must be skipped)
Parameters
| Model size | speed | Accuracy | Matching |
|---|---|---|---|
| Nano | Fastest | Lowest | Embedded Machine, needs realtime |
| Small | Nhanh | Medium | Balance speed/precision |
| Medium/Large | Slower | Highest | Strong GPU, no absolute real - time |
Practical applications
For embedded computers such as the Jetson Orin Nano or Raspberry Pi, the nano/small version is often the logical choice to balance accuracy and real - time processing speed; machines with GPUs (such as the Jetson) leverage CUDA to run significantly faster than just running on — CPUs as calculated in the Form factor, the difference in speed between GPUs and net CPUs can be up to 10 times greater, directly determining which SBC to choose (as learned in Computer Select for AMR) for applications requiring real - time visual AI.
Practical example
import time
from ultralytics import YOLO
model = YOLO("yolov8n.pt")
start = time.time()
results = model("frame.jpg", verbose=False)
elapsed = time.time() - start
print(f"Thời gian inference: {elapsed*1000:.1f}ms")
print(f"FPS tối đa ước lượng: {1/elapsed:.1f}")
for box in results[0].boxes:
cls_name = model.names[int(box.cls)]
print(f" {cls_name}: {float(box.conf):.2f}")
Typical output on Jetson Orin Nano:
Thời gian inference: 14.2ms
FPS tối đa ước lượng: 70.4
person: 0.91
box: 0.87
Measuring real-world inference time on the correct hardware intended to implement — rather than relying on a generic benchmark figure — is a key validation step before designing a complete ROS2 pipeline.
Common mistakes
- Select medium/large size models for net embedded CPU— computers as calculated in the Formula section, the inference time far exceeds the required real-time processing capability.
- Non-measurement of real-world inference time on the correct implementation hardware— believes in generic benchmarks from model developers, which may not properly reflect performance on the particular hardware in use.
- Run YOLO on CPU without considering the available GPU — if hardware has a GPU (Jetson) but is not properly configured to take advantage of CUDA, speeds much slower than unnecessary.
- Bypassing the selection of the correct speed/accuracy required model version — using default nano for applications requiring high accuracy, or vice versa using large for applications requiring absolute real-time on weak hardware.
Conclusion
YOLO is a powerful tool for real-time multi-object recognition — Choosing the correct model size according to real-world hardware capability (measured by inference time, not guess) is the most important decision on implementation. The next two articles in the column delve into the concept of Object Detection in general and how to integrate YOLO into a complete ROS2 pipeline.
Get new articles and lessons by email
When a new technical article or course module is published, Atlas Robotics sends you a short email. No spam.
Unsubscribe any time with the link in each email. See our Privacy policy.