AI EngineeringAI Engineering
AI Engineering2 min read

What is the YOLO algorithm? Introduction to Real-Time Object Detection

YOLO, Also Known as You Only Look Once is one of the most powerful real-time object detector algorithms. It is called that way because….

Updated Sep 01, 2021
What is the YOLO algorithm? Introduction to Real-Time Object Detection
Contents

Key takeaways

  • YOLO is useful because it frames object detection as one fast prediction over the image, which made real-time detection practical.
  • Speed is the headline, but the real test is whether detections stay reliable across lighting, scale, occlusion, and camera changes.
  • For builders, object detection is a product decision too: false positives, missed objects, latency, and deployment constraints all matter.

Watch the video and support me on YouTube!

YOLO, Also Known as You Only Look Once is one of the most powerful real-time object detector algorithms. It is called that way because unlike previous object detector algorithms, like R-CNN or its upgrade Faster R-CNN it only needs the image (or video) to pass one time through its network.

Visual example from What is the YOLO algorithm? Introduction to Real Time Object Detection

https://www.pyimagesearch.com/2018/11/12/yolo-object-detection-with-opencv/

These old methods were successively examining several regions of the image to find the objects present in it. YOLO changed that by reasoning at the level of the overall image. To do so, YOLO uses a unique neural network using the characteristics of the entire image to predict multiple boxes, each containing a specific object. All this simultaneously.

Visual example from What is the YOLO algorithm? Introduction to Real Time Object Detection

https://www.pyimagesearch.com/2018/11/12/yolo-object-detection-with-opencv/

To achieve this, the image is divided into ‘S’ x ‘S’ region. Then, if the center of an object is in one of these regions, the region in question is responsible for detecting the object. Each of the cells in this grid is responsible for predicting ‘B’ boxes all containing an object as well as a score representing the level of confidence for the object present in the box. If there are no objects in the cell, this score should be zero. Otherwise, if an object is in the cell, the score will be equal to the intersection over union (IoU) between the predicted box and the ground truth of the image.

Visual example from What is the YOLO algorithm? Introduction to Real Time Object Detection

https://stackoverflow.com/questions/50575301/yolo-object-detection-how-does-the-algorithm-predict-bounding-boxes-larger-than

Then, we need the class-specific confidence scores for each box which is done using a convolutional neural network based on the GoogLeNet network. The output of this algorithm will be the image (or video), sent as the input, with the objects localized and the class attached to it.

Visual example from What is the YOLO algorithm? Introduction to Real Time Object Detection

https://blog.paperspace.com/how-to-implement-a-yolo-object-detector-in-pytorch/

As previously discussed, YOLO reasons at the level of the overall picture, rather than examining successively several regions.
This allows a huge increase in detection speed but causes a small decrease in the accuracy of object detection compared to the other detection methods seen previously. It is actually one of the most powerful and used object detector algorithms right now in multiple fields like autonomous vehicles, poker cheat detection, and more.

Visual example from What is the YOLO algorithm? Introduction to Real Time Object Detection

If you want to learn more about this algorithm, check out the paper linked below!


References

Original YOLO paper: https://arxiv.org/abs/1506.02640

YOLOv4 paper: https://arxiv.org/abs/2004.10934

YOLOv4 code: https://github.com/AlexeyAB/darknet

Discussion

Comments

Loading

No account needed. Your name and comment will be public, so do not include private information. See the privacy page for details.

Keep learning

Want the practical side of AI, without the hype fog?

I share the useful parts on YouTube, Substack, and the AI engineering guides.

FAQ

What is YOLO in computer vision?

YOLO, or You Only Look Once, is an object detection approach that predicts objects and bounding boxes from an image in a single pass.

What is object detection?

Object detection finds where objects are in an image and identifies what category each object belongs to, usually with bounding boxes.

What should builders test before using YOLO?

Test different lighting, object sizes, camera angles, occlusion, false positives, missed detections, latency, and the exact deployment hardware.

How should beginners learn YOLO?

Start by understanding classification versus detection, then learn bounding boxes, confidence scores, non-maximum suppression, datasets, and evaluation metrics.