Object Detection with YOLO in 2026: Ultralytics (60k Stars) Tutorial - Detect Objects in Images and Video with 10 Lines

๐Ÿ“˜ Tutorials 2026-08-05 2 min read

Ultralytics YOLO (60,218 stars, AGPL-3.0) is the easiest object detection library: 10 lines of Python detect 80+ object classes in images, video and live webcam feeds - free and GPU or CPU friendly.

💡 What You Will Learn

Ultralytics YOLO (60,218 stars, AGPL-3.0) is the easiest object detection library: 10 lines of Python detect 80+ object classes in images, video and live webcam feeds - free and GPU or CPU friendly.

📜 Table of Contents

The short answer

Ultralytics YOLO (60,218 stars, AGPL-3.0) bundles the YOLOv8/YOLO11 model family with a dead-simple Python API. Detection, segmentation, classification and pose estimation are each a few lines - no model architecture knowledge required.

Detect objects in an image

pip install ultralytics
from ultralytics import YOLO

model = YOLO("yolo11n.pt")           # nano model: fast, small
results = model("bus.jpg")           # returns detections

for r in results:
    for box in r.boxes:
        print(r.names[int(box.cls)], round(float(box.conf), 2))

Detect in video or webcam

model = YOLO("yolo11s.pt")           # small model: better accuracy
model.predict("video.mp4", save=True)          # annotated video file
model.predict(source="0", show=True)           # live webcam

Beyond detection

Task One-liner
Instance segmentation model("image.jpg", task="segment")
Pose estimation model("image.jpg", task="pose")
Classification model("image.jpg", task="classify")
Training your own dataset model.train(data="custom.yaml", epochs=100)

Real numbers

FAQ

Q: Do I need to train it? A: No - the pretrained COCO model works immediately. Train only when you need custom classes (e.g., specific products).

Q: License concerns? A: AGPL-3.0 for the library; Ultralytics also sells enterprise licenses. For commercial closed-source use, check their licensing terms.

Q: Can I export to other formats? A: Yes - model.export(format="onnx") exports to ONNX, TensorRT, CoreML, TFLite and more.

❓ FAQ

Do I need to train it?

No - the pretrained COCO model works immediately. Train only when you need custom classes (e.g., specific products).

License concerns?

AGPL-3.0 for the library; Ultralytics also sells enterprise licenses. For commercial closed-source use, check their licensing terms.

Can I export to other formats?

Yes - `model.export(format="onnx")` exports to ONNX, TensorRT, CoreML, TFLite and more.

Related Articles
2026-08-05
Local LLM Setup for Coding in 2026: Ollama (178k Stars) + Continue + Cline - Private AI Pair Programmer
2026-08-05
AI Meeting Scheduling Assistant in 2026: Cal.com (47k Stars) Self-Hosted + LLM - End the Email Ping-Pong
2026-07-16
AI Agent Health Check 2026

Written by our editorial team; tools listed here are tested or verified against public sources. Links point to official sites or GitHub repos for reference only โ€” no paid placements.

๐Ÿ’ฌ Comments (0)

No comments yet. Be the first!

Login to comment