@@ -22,7 +22,7 @@ keywords: Ultralytics HUB, YOLO models, mobile app, iOS, Android, hardware accel
@@ -22,7 +22,7 @@ keywords: Ultralytics, iOS App, YOLO models, real-time object detection, Apple N

-

+
diff --git a/docs/en/hub/index.md b/docs/en/hub/index.md
index 24dbdd3f5..c2ebbce55 100644
--- a/docs/en/hub/index.md
+++ b/docs/en/hub/index.md
@@ -7,7 +7,7 @@ keywords: Ultralytics HUB, YOLO models, train YOLO, YOLOv5, YOLOv8, object detec
# Ultralytics HUB
👋 Hello from the [Ultralytics](https://www.ultralytics.com/) Team! We've been working hard these last few months to launch [Ultralytics HUB](https://www.ultralytics.com/hub), a new web tool for training and deploying all your YOLOv5 and YOLOv8 🚀 models from one spot!
-We hope that the resources here will help you get the most out of HUB. Please browse the HUB Docs for details, raise an issue on
GitHub for support, and join our
Discord community for questions and discussions!
+We hope that the resources here will help you get the most out of HUB. Please browse the HUB
Docs for details, raise an issue on
GitHub for support, and join our
Discord community for questions and discussions!
## Introduction
@@ -61,7 +61,7 @@ We hope that the resources here will help you get the most out of HUB. Please br
Watch: Train Your Custom YOLO Models In A Few Clicks with Ultralytics HUB
-We hope that the resources here will help you get the most out of HUB. Please browse the HUB
Docs for details, raise an issue on
GitHub for support, and join our
Discord community for questions and discussions!
+We hope that the resources here will help you get the most out of HUB. Please browse the HUB
Docs for details, raise an issue on
GitHub for support, and join our
Discord community for questions and discussions!
- [**Quickstart**](quickstart.md): Start training and deploying models in seconds.
- [**Datasets**](datasets.md): Learn how to prepare and upload your datasets.
diff --git a/docs/en/hub/quickstart.md b/docs/en/hub/quickstart.md
index 3fbcf23af..ad10e26e9 100644
--- a/docs/en/hub/quickstart.md
+++ b/docs/en/hub/quickstart.md
@@ -98,4 +98,4 @@ You can report a bug, request a feature, or ask a question on
Discord community for questions and discussions!
+ You can join our
Discord community for questions and discussions!
diff --git a/docs/en/index.md b/docs/en/index.md
index 73ac1cd07..8217f972d 100644
--- a/docs/en/index.md
+++ b/docs/en/index.md
@@ -6,24 +6,24 @@ keywords: Ultralytics, YOLO, YOLO11, object detection, image segmentation, deep
## Where to Start
diff --git a/docs/en/models/yolo11.md b/docs/en/models/yolo11.md
index 4460042b1..0c755147a 100644
--- a/docs/en/models/yolo11.md
+++ b/docs/en/models/yolo11.md
@@ -8,7 +8,7 @@ keywords: YOLO11, state-of-the-art object detection, YOLO series, Ultralytics, c
## Overview
-YOLO11 is the latest iteration in the [Ultralytics](https://www.ultralytics.com) YOLO series of real-time object detectors, redefining what's possible with cutting-edge [accuracy](https://www.ultralytics.com/glossary/accuracy), speed, and efficiency. Building upon the impressive advancements of previous YOLO versions, YOLO11 introduces significant improvements in architecture and training methods, making it a versatile choice for a wide range of [computer vision](https://www.ultralytics.com/glossary/computer-vision-cv) tasks.
+YOLO11 is the latest iteration in the [Ultralytics](https://www.ultralytics.com/) YOLO series of real-time object detectors, redefining what's possible with cutting-edge [accuracy](https://www.ultralytics.com/glossary/accuracy), speed, and efficiency. Building upon the impressive advancements of previous YOLO versions, YOLO11 introduces significant improvements in architecture and training methods, making it a versatile choice for a wide range of [computer vision](https://www.ultralytics.com/glossary/computer-vision-cv) tasks.

diff --git a/docs/en/yolov5/index.md b/docs/en/yolov5/index.md
index 360505846..17be5e24a 100644
--- a/docs/en/yolov5/index.md
+++ b/docs/en/yolov5/index.md
@@ -8,7 +8,7 @@ keywords: YOLOv5, Ultralytics, object detection, computer vision, deep learning,
-
+
@@ -80,7 +80,7 @@ This badge indicates that all [YOLOv5 GitHub Actions](https://github.com/ultraly

-

+
## Connect and Contribute
diff --git a/docs/en/yolov5/tutorials/train_custom_data.md b/docs/en/yolov5/tutorials/train_custom_data.md
index aa093e4b8..8b465c523 100644
--- a/docs/en/yolov5/tutorials/train_custom_data.md
+++ b/docs/en/yolov5/tutorials/train_custom_data.md
@@ -18,7 +18,7 @@ pip install -r requirements.txt # install
## Train On Custom Data
-
+
diff --git a/ultralytics/engine/exporter.py b/ultralytics/engine/exporter.py
index 73ee545f3..26ca541c1 100644
--- a/ultralytics/engine/exporter.py
+++ b/ultralytics/engine/exporter.py
@@ -183,11 +183,10 @@ class Exporter:
# Get the closest match if format is invalid
matches = difflib.get_close_matches(fmt, fmts, n=1, cutoff=0.6) # 60% similarity required to match
- if matches:
- LOGGER.warning(f"WARNING ⚠️ Invalid export format='{fmt}', updating to format='{matches[0]}'")
- fmt = matches[0]
- else:
+ if not matches:
raise ValueError(f"Invalid export format='{fmt}'. Valid formats are {fmts}")
+ LOGGER.warning(f"WARNING ⚠️ Invalid export format='{fmt}', updating to format='{matches[0]}'")
+ fmt = matches[0]
flags = [x == fmt for x in fmts]
if sum(flags) != 1:
raise ValueError(f"Invalid export format='{fmt}'. Valid formats are {fmts}")
diff --git a/ultralytics/utils/__init__.py b/ultralytics/utils/__init__.py
index 3edfac116..7605a01e4 100644
--- a/ultralytics/utils/__init__.py
+++ b/ultralytics/utils/__init__.py
@@ -989,55 +989,56 @@ def set_sentry():
Additionally, the function sets custom tags and user information for Sentry events.
"""
if (
- SETTINGS["sync"]
- and RANK in {-1, 0}
- and Path(ARGV[0]).name == "yolo"
- and not TESTS_RUNNING
- and ONLINE
- and IS_PIP_PACKAGE
- and not IS_GIT_DIR
+ not SETTINGS["sync"]
+ or RANK not in {-1, 0}
+ or Path(ARGV[0]).name != "yolo"
+ or TESTS_RUNNING
+ or not ONLINE
+ or not IS_PIP_PACKAGE
+ or IS_GIT_DIR
):
- # If sentry_sdk package is not installed then return and do not use Sentry
- try:
- import sentry_sdk # noqa
- except ImportError:
- return
-
- def before_send(event, hint):
- """
- Modify the event before sending it to Sentry based on specific exception types and messages.
+ return
+ # If sentry_sdk package is not installed then return and do not use Sentry
+ try:
+ import sentry_sdk # noqa
+ except ImportError:
+ return
+
+ def before_send(event, hint):
+ """
+ Modify the event before sending it to Sentry based on specific exception types and messages.
- Args:
- event (dict): The event dictionary containing information about the error.
- hint (dict): A dictionary containing additional information about the error.
+ Args:
+ event (dict): The event dictionary containing information about the error.
+ hint (dict): A dictionary containing additional information about the error.
- Returns:
- dict: The modified event or None if the event should not be sent to Sentry.
- """
- if "exc_info" in hint:
- exc_type, exc_value, _ = hint["exc_info"]
- if exc_type in {KeyboardInterrupt, FileNotFoundError} or "out of memory" in str(exc_value):
- return None # do not send event
-
- event["tags"] = {
- "sys_argv": ARGV[0],
- "sys_argv_name": Path(ARGV[0]).name,
- "install": "git" if IS_GIT_DIR else "pip" if IS_PIP_PACKAGE else "other",
- "os": ENVIRONMENT,
- }
- return event
-
- sentry_sdk.init(
- dsn="https://888e5a0778212e1d0314c37d4b9aae5d@o4504521589325824.ingest.us.sentry.io/4504521592406016",
- debug=False,
- auto_enabling_integrations=False,
- traces_sample_rate=1.0,
- release=__version__,
- environment="production", # 'dev' or 'production'
- before_send=before_send,
- ignore_errors=[KeyboardInterrupt, FileNotFoundError],
- )
- sentry_sdk.set_user({"id": SETTINGS["uuid"]}) # SHA-256 anonymized UUID hash
+ Returns:
+ dict: The modified event or None if the event should not be sent to Sentry.
+ """
+ if "exc_info" in hint:
+ exc_type, exc_value, _ = hint["exc_info"]
+ if exc_type in {KeyboardInterrupt, FileNotFoundError} or "out of memory" in str(exc_value):
+ return None # do not send event
+
+ event["tags"] = {
+ "sys_argv": ARGV[0],
+ "sys_argv_name": Path(ARGV[0]).name,
+ "install": "git" if IS_GIT_DIR else "pip" if IS_PIP_PACKAGE else "other",
+ "os": ENVIRONMENT,
+ }
+ return event
+
+ sentry_sdk.init(
+ dsn="https://888e5a0778212e1d0314c37d4b9aae5d@o4504521589325824.ingest.us.sentry.io/4504521592406016",
+ debug=False,
+ auto_enabling_integrations=False,
+ traces_sample_rate=1.0,
+ release=__version__,
+ environment="production", # 'dev' or 'production'
+ before_send=before_send,
+ ignore_errors=[KeyboardInterrupt, FileNotFoundError],
+ )
+ sentry_sdk.set_user({"id": SETTINGS["uuid"]}) # SHA-256 anonymized UUID hash
class JSONDict(dict):