AI信頼度スコアの定義モデルが予測の確実性を測定する方法、信頼性のしきい値を設定する方法、信頼性と精度を区別する方法を学ぶ。
Confidence, in the context of Artificial Intelligence (AI) and Machine Learning (ML), represents a score assigned by a model to its prediction, indicating how certain the model is about that specific output. For tasks like object detection or image classification, each detected object or assigned class label comes with a confidence score, typically ranging from 0 to 1 (or 0% to 100%). This score helps users gauge the reliability of individual predictions made by models such as Ultralytics YOLO. A higher score suggests the model is more certain about its prediction based on the patterns learned during training. Understanding confidence is crucial for interpreting model outputs and making informed decisions based on AI predictions, especially in safety-critical applications like AI in automotive solutions.
Confidence scores are usually derived from the output layer of a neural network (NN). For classification tasks, this often involves applying an activation function like Softmax or Sigmoid to the raw outputs (logits) to produce probability-like values for each class. In object detection models like YOLO, the confidence score might combine the probability of an object being present in a proposed bounding box (often called an "objectness score") and the probability of that object belonging to a specific class, conditioned on an object being present. It's a key output used during the inference process to assess the validity of detections. This score is calculated based on the model weights learned from datasets like COCO.
In practice, not all predictions from a model are equally useful or reliable. Predictions with very low confidence scores often represent background noise or uncertain classifications. To filter these out, a "confidence threshold" is typically applied. This is a user-defined value (e.g., 0.5 or 50%); only predictions with a confidence score above this threshold are considered valid outputs. Setting an appropriate threshold is vital and often depends on the specific application:
The confidence threshold often works in conjunction with techniques like Non-Maximum Suppression (NMS) to refine the final set of detections by removing overlapping bounding boxes for the same object. You can easily configure this threshold when using Ultralytics models via the command-line interface (CLI) or Python API. Finding the optimal threshold may involve hyperparameter tuning.
Confidence scores are fundamental in deploying AI models responsibly and effectively:
It's important not to confuse the confidence score of an individual prediction with overall model evaluation metrics. While related, they measure different aspects of performance:
In summary, confidence is a valuable output for assessing the certainty of individual AI predictions, enabling better filtering, prioritization, and decision-making in real-world applications. It complements, but is distinct from, metrics that evaluate the overall performance of a model like those tracked in Ultralytics HUB.