Skip to content

Commit

Permalink
Add V9 support (#85)
Browse files Browse the repository at this point in the history
  • Loading branch information
HonzaCuhel authored Aug 10, 2024
1 parent aee6434 commit e7bf4f3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "tools"
version = "0.1.2"
version = "0.1.3"
description = "Converter for YOLO models into .ONNX format."
readme = "README.md"
requires-python = ">=3.8"
Expand Down
8 changes: 5 additions & 3 deletions tools/utils/version_detection.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,15 @@ def detect_version(path: str, debug: bool = False) -> str:
print(data.decode(errors="replace"))
content = data.decode("latin1")

if (
if "yolov10" in content or "v10DetectLoss" in content:
return YOLOV10_CONVERSION
elif (
"YOLOv5u" in content
or "YOLOv8" in content
or "yolov8" in content
or ("v8DetectionLoss" in content and "ultralytics" in content)
or "yolov9" in content
or ("v9-model" and "ultralytics" in content)
):
return YOLOV8_CONVERSION
elif "yolov6" in content:
Expand All @@ -62,8 +66,6 @@ def detect_version(path: str, debug: bool = False) -> str:
return YOLOV6R3_CONVERSION
elif "yolov7" in content:
return YOLOV7_CONVERSION
elif "yolov10" in content:
return YOLOV10_CONVERSION
elif (
"SPPF" in content
or "yolov5" in content
Expand Down

0 comments on commit e7bf4f3

Please sign in to comment.