YOLOv8<T>

Models & Types · AiDotNet.ComputerVision.Detection.ObjectDetection.YOLO

YOLOv8 object detector - anchor-free, decoupled head architecture.

Inheritance: ModelBase<T, Tensor<T>, Tensor<T>> → VisionTaskModelBase<T> → ObjectDetectorBase<T> → YOLOv8<T>

Implements: IDetectionTrainingModel<T>

For Beginners

YOLOv8 is a state-of-the-art real-time object detector developed by Ultralytics. It’s faster and more accurate than previous YOLO versions, using an anchor-free design that simplifies training and improves generalization.

How It Works

Key improvements over YOLOv5:

  • Anchor-free design eliminates anchor tuning
  • Decoupled head separates classification and localization
  • Distribution Focal Loss (DFL) for better box regression
  • C2f modules for improved feature extraction

Reference: Jocher et al., “YOLOv8” Ultralytics, 2023

Constructors

Constructor Summary
YOLOv8(ObjectDetectionOptions<T> options) Creates a new YOLOv8 detector.

Properties

Property Summary
string Name { get; }

Methods

Method Summary
DetectionResult<T> Detect(Tensor<T> image, double confidenceThreshold, double nmsThreshold)
Task LoadWeightsAsync(string pathOrUrl, CancellationToken cancellationToken)
void SaveWeights(string path)
void TrainDetections(Tensor<T> input, DetectionTrainingBatch<T> targets) Trains the head with task-aligned assignment, BCE classification, CIoU and distribution focal loss.