Yolo Vision Shenzhen
Шэньчжэнь
Присоединиться сейчас
Глоссарий

Полнота (Recall)

Узнайте, что такое Recall в машинном обучении, почему это важно и как это обеспечивает эффективный захват AI-моделями критически важных положительных экземпляров.

Recall, also known as sensitivity or the true positive rate, is a fundamental performance metric in machine learning that measures the ability of a model to identify all relevant instances within a dataset. In the context of object detection or classification, it specifically answers the question: "Out of all the actual positive cases, how many did the model correctly find?" Achieving high recall is critical in scenarios where missing a positive instance—often referred to as a false negative—carries significant consequences. Unlike accuracy, which can be misleading when dealing with imbalanced data, recall provides a focused view on the model's effectiveness at "capturing" the target class.

Важность высокого значения Recall

In many artificial intelligence applications, the cost of failing to detect an object is far higher than the cost of a false alarm. A model optimized for recall minimizes false negatives, ensuring that the system casts a wide enough net to catch potential threats, anomalies, or critical conditions. This often involves a trade-off, as increasing recall can sometimes lead to a lower precision score, meaning the model might flag more non-relevant items as positive. Understanding this balance is key to developing robust machine learning solutions.

Применение в реальном мире

Вспоминаемость — это ключевой показатель, лежащий в основе многих критически важных для безопасности решений искусственного интеллекта. Вот два ярких примера, когда чувствительность имеет приоритетное значение:

  • Медицинская диагностика: при анализе медицинских изображений, например при скрининге рентгеновских снимков на ранние признаки заболевания, высокая точность распознавания является обязательным условием. Если ИИ в системе здравоохранения используется для обнару detect опухолей, то для системы гораздо лучше отметить подозрительную тень, которая окажется доброкачественной (ложноположительный результат), чем полностью пропустить злокачественную опухоль. Врачи полагаются на эти инструменты как на своего рода «страховочную сетку», которая гарантирует, что никакие потенциальные риски для здоровья не будут упущены из виду.
  • Безопасность и наблюдение: для системы охранной сигнализации основной целью является detect попытки вторжения. Система, оптимизированная для высокой точности, гарантирует, что при входе человека в зону ограниченного доступа сработает сигнализация. Хотя это может привести к случайным ложным срабатываниям сигнализации, вызванным дикими животными, это предпочтительнее, чем неспособность системы detect реального detect . Модели обнаружения объектов в этих сценариях настроены так, чтобы обеспечить максимальную чувствительность к потенциальным угрозам.

Recall vs. Precision

It is essential to distinguish recall from its counterpart, precision. While recall measures the quantity of relevant cases found (completeness), precision measures the quality of the positive predictions (exactness).

  • Recall: Focuses on avoiding missed detections. "Did we find all the apples?"
  • Precision: Focuses on minimizing false alarms. "Are all the things we called apples actually apples?"

These two metrics often share an inverse relationship, visualized through a Precision-Recall curve. To evaluate the overall balance between them, developers often look at the F1-score, which is the harmonic mean of both. In imbalanced datasets, looking at recall alongside the confusion matrix gives a much clearer picture of performance than accuracy alone.

Измерение запоминания с помощью Ultralytics YOLO

When training models like the cutting-edge YOLO26, recall is automatically computed during the validation phase. The framework calculates recall for each class and the mean Average Precision (mAP), helping developers gauge how well the model finds objects.

Вы можете легко проверить обученную модель и просмотреть ее показатели воспроизведения с помощью Python. Этот фрагмент кода демонстрирует, как загрузить модель и проверить ее производительность на стандартном наборе данных:

from ultralytics import YOLO

# Load a pretrained YOLO26 model
model = YOLO("yolo26n.pt")

# Validate the model on the COCO8 dataset
# The results object contains metrics like Precision, Recall, and mAP
metrics = model.val(data="coco8.yaml")

# Access and print the mean recall score for box detection
print(f"Mean Recall: {metrics.results_dict['metrics/recall(B)']:.4f}")

This code utilizes the Ultralytics API to run validation. If the recall is lower than required for your project, you might consider techniques like data augmentation to create more varied training examples or hyperparameter tuning to adjust the model's sensitivity. Using the Ultralytics Platform can also streamline the process of managing datasets and tracking these metrics over multiple training runs.

Improving Model Recall

To boost a model's recall, data scientists often adjust the confidence threshold used during inference. Lowering the threshold makes the model more "optimistic," accepting more predictions as positive, which increases recall but may decrease precision. Additionally, collecting more diverse training data helps the model learn to recognize hard negatives and obscure instances. For complex tasks, employing advanced architectures like Transformer blocks or exploring ensemble methods can also improve the system's ability to detect subtle features that simpler models might miss.

Присоединяйтесь к сообществу Ultralytics

Присоединяйтесь к будущему ИИ. Общайтесь, сотрудничайте и развивайтесь вместе с мировыми новаторами

Присоединиться сейчас