ultralytics 8.1.27__py3-none-any.whl → 8.1.28__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of ultralytics might be problematic. Click here for more details.
- ultralytics/__init__.py +1 -1
- ultralytics/engine/exporter.py +7 -4
- ultralytics/engine/predictor.py +1 -1
- ultralytics/models/rtdetr/model.py +0 -2
- ultralytics/models/yolo/model.py +3 -2
- ultralytics/nn/modules/head.py +1 -1
- {ultralytics-8.1.27.dist-info → ultralytics-8.1.28.dist-info}/METADATA +1 -1
- {ultralytics-8.1.27.dist-info → ultralytics-8.1.28.dist-info}/RECORD +12 -12
- {ultralytics-8.1.27.dist-info → ultralytics-8.1.28.dist-info}/WHEEL +1 -1
- {ultralytics-8.1.27.dist-info → ultralytics-8.1.28.dist-info}/LICENSE +0 -0
- {ultralytics-8.1.27.dist-info → ultralytics-8.1.28.dist-info}/entry_points.txt +0 -0
- {ultralytics-8.1.27.dist-info → ultralytics-8.1.28.dist-info}/top_level.txt +0 -0
ultralytics/__init__.py
CHANGED
ultralytics/engine/exporter.py
CHANGED
|
@@ -528,12 +528,12 @@ class Exporter:
|
|
|
528
528
|
f"or in {ROOT}. See PNNX repo for full installation instructions."
|
|
529
529
|
)
|
|
530
530
|
system = "macos" if MACOS else "windows" if WINDOWS else "linux-aarch64" if ARM64 else "linux"
|
|
531
|
-
|
|
532
|
-
|
|
531
|
+
_, assets = get_github_assets(repo="pnnx/pnnx", retry=True)
|
|
532
|
+
if assets:
|
|
533
533
|
url = [x for x in assets if f"{system}.zip" in x][0]
|
|
534
|
-
|
|
534
|
+
else:
|
|
535
535
|
url = f"https://github.com/pnnx/pnnx/releases/download/20240226/pnnx-20240226-{system}.zip"
|
|
536
|
-
LOGGER.warning(f"{prefix} WARNING ⚠️ PNNX GitHub assets not found
|
|
536
|
+
LOGGER.warning(f"{prefix} WARNING ⚠️ PNNX GitHub assets not found, using default {url}")
|
|
537
537
|
asset = attempt_download_asset(url, repo="pnnx/pnnx", release="latest")
|
|
538
538
|
if check_is_path_safe(Path.cwd(), asset): # avoid path traversal security vulnerability
|
|
539
539
|
unzip_dir = Path(asset).with_suffix("")
|
|
@@ -886,6 +886,9 @@ class Exporter:
|
|
|
886
886
|
def export_tfjs(self, prefix=colorstr("TensorFlow.js:")):
|
|
887
887
|
"""YOLOv8 TensorFlow.js export."""
|
|
888
888
|
check_requirements("tensorflowjs")
|
|
889
|
+
if ARM64:
|
|
890
|
+
# Fix error: `np.object` was a deprecated alias for the builtin `object` when exporting to TF.js on ARM64
|
|
891
|
+
check_requirements("numpy==1.23.5")
|
|
889
892
|
import tensorflow as tf
|
|
890
893
|
import tensorflowjs as tfjs # noqa
|
|
891
894
|
|
ultralytics/engine/predictor.py
CHANGED
|
@@ -151,7 +151,7 @@ class BasePredictor:
|
|
|
151
151
|
Returns:
|
|
152
152
|
(list): A list of transformed images.
|
|
153
153
|
"""
|
|
154
|
-
same_shapes =
|
|
154
|
+
same_shapes = len({x.shape for x in im}) == 1
|
|
155
155
|
letterbox = LetterBox(self.imgsz, auto=same_shapes and self.model.pt, stride=self.model.stride)
|
|
156
156
|
return [letterbox(image=x) for x in im]
|
|
157
157
|
|
|
@@ -7,8 +7,6 @@ hybrid encoder and IoU-aware query selection for enhanced detection accuracy.
|
|
|
7
7
|
For more information on RT-DETR, visit: https://arxiv.org/pdf/2304.08069.pdf
|
|
8
8
|
"""
|
|
9
9
|
|
|
10
|
-
from pathlib import Path
|
|
11
|
-
|
|
12
10
|
from ultralytics.engine.model import Model
|
|
13
11
|
from ultralytics.nn.tasks import RTDETRDetectionModel
|
|
14
12
|
|
ultralytics/models/yolo/model.py
CHANGED
|
@@ -71,8 +71,9 @@ class YOLOWorld(Model):
|
|
|
71
71
|
"""
|
|
72
72
|
super().__init__(model=model, task="detect")
|
|
73
73
|
|
|
74
|
-
# Assign default COCO class names
|
|
75
|
-
self.model
|
|
74
|
+
# Assign default COCO class names when there are no custom names
|
|
75
|
+
if not hasattr(self.model, "names"):
|
|
76
|
+
self.model.names = yaml_load(ROOT / "cfg/datasets/coco8.yaml").get("names")
|
|
76
77
|
|
|
77
78
|
@property
|
|
78
79
|
def task_map(self):
|
ultralytics/nn/modules/head.py
CHANGED
|
@@ -395,7 +395,7 @@ class RTDETRDecoder(nn.Module):
|
|
|
395
395
|
anchors.append(torch.cat([grid_xy, wh], -1).view(-1, h * w, 4)) # (1, h*w, 4)
|
|
396
396
|
|
|
397
397
|
anchors = torch.cat(anchors, 1) # (1, h*w*nl, 4)
|
|
398
|
-
valid_mask = ((anchors > eps)
|
|
398
|
+
valid_mask = ((anchors > eps) & (anchors < 1 - eps)).all(-1, keepdim=True) # 1, h*w*nl, 1
|
|
399
399
|
anchors = torch.log(anchors / (1 - anchors))
|
|
400
400
|
anchors = anchors.masked_fill(~valid_mask, float("inf"))
|
|
401
401
|
return anchors, valid_mask
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: ultralytics
|
|
3
|
-
Version: 8.1.
|
|
3
|
+
Version: 8.1.28
|
|
4
4
|
Summary: Ultralytics YOLOv8 for SOTA object detection, multi-object tracking, instance segmentation, pose estimation and image classification.
|
|
5
5
|
Author: Glenn Jocher, Ayush Chaurasia, Jing Qiu
|
|
6
6
|
Maintainer: Glenn Jocher, Ayush Chaurasia, Jing Qiu
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
ultralytics/__init__.py,sha256=
|
|
1
|
+
ultralytics/__init__.py,sha256=N_MN1oEZmRRJfw3IZEbRfucDpkFS1ka6ZAsZK9MGL4k,625
|
|
2
2
|
ultralytics/assets/bus.jpg,sha256=wCAZxJecGR63Od3ZRERe9Aja1Weayrb9Ug751DS_vGM,137419
|
|
3
3
|
ultralytics/assets/zidane.jpg,sha256=Ftc4aeMmen1O0A3o6GCDO9FlfBslLpTAw0gnetx7bts,50427
|
|
4
4
|
ultralytics/cfg/__init__.py,sha256=Dk0UPabXlPX5iCDzqf8MIxCNtY7HMhVRcd_B2tZw9_w,20767
|
|
@@ -73,9 +73,9 @@ ultralytics/data/explorer/utils.py,sha256=a6ugY8rKpFM8dIRcUwRyjRkRJ-zXEwe-NiJr6C
|
|
|
73
73
|
ultralytics/data/explorer/gui/__init__.py,sha256=mHtJuK4hwF8cuV-VHDc7tp6u6D1gHz2Z7JI8grmQDTs,42
|
|
74
74
|
ultralytics/data/explorer/gui/dash.py,sha256=a2s8oJKI8kqnWEcIyqCCzvIyvM_uZmfMaxrOdwmiq7k,10044
|
|
75
75
|
ultralytics/engine/__init__.py,sha256=mHtJuK4hwF8cuV-VHDc7tp6u6D1gHz2Z7JI8grmQDTs,42
|
|
76
|
-
ultralytics/engine/exporter.py,sha256=
|
|
76
|
+
ultralytics/engine/exporter.py,sha256=pwTQCo88Sd41NqYKx5Jp15fSqhFgaY3Z5gfLm8uzLR0,53882
|
|
77
77
|
ultralytics/engine/model.py,sha256=Kh5Bs3Rq6xJnpwCBtKFonNBLXYScg81uhj6zXx16bBw,39193
|
|
78
|
-
ultralytics/engine/predictor.py,sha256=
|
|
78
|
+
ultralytics/engine/predictor.py,sha256=wQRKdWGDTP5A6CS0gTC6U3RPDMhP3QkEzWSPm6eqCkU,17022
|
|
79
79
|
ultralytics/engine/results.py,sha256=SY3sn2OBMfAFaPoaDKo0Wu-jSi7avISYohjtR_bur9M,30120
|
|
80
80
|
ultralytics/engine/trainer.py,sha256=C04cEN9v-kvR2dIIjgAN8dBAx8XSTChlQkDxAxfwTlU,34527
|
|
81
81
|
ultralytics/engine/tuner.py,sha256=DzgTH3uk-VUUVoJ0K3tM4N5TJ6A3fMNlcDYr5g2I9lA,11763
|
|
@@ -96,7 +96,7 @@ ultralytics/models/nas/model.py,sha256=Nr1YHj0YQkBITp3xVVGliEcbrjpZemtBt0crz1h63
|
|
|
96
96
|
ultralytics/models/nas/predict.py,sha256=O7f92KE6hi5DENTRzXiMsm-qK-ndVoO1Bs3dugp8aLA,2136
|
|
97
97
|
ultralytics/models/nas/val.py,sha256=u35kVTVgGxK_rbHytUvFB4F3_nZn4MPv3PbZLFWSmkQ,1680
|
|
98
98
|
ultralytics/models/rtdetr/__init__.py,sha256=AZga1C3qlGTtgpAupDW4doijq5aZlQeF8e55_DP2Uas,197
|
|
99
|
-
ultralytics/models/rtdetr/model.py,sha256=
|
|
99
|
+
ultralytics/models/rtdetr/model.py,sha256=2VkppF1_581XmQ0UI7lo8fX7MqhAJPXVMr2jyMHXtbk,1988
|
|
100
100
|
ultralytics/models/rtdetr/predict.py,sha256=-NFBAv_4VIUcXycO7wA8IH6EHXrVyOir-5PZkd46qyo,3584
|
|
101
101
|
ultralytics/models/rtdetr/train.py,sha256=HdSC2x22Rks6qKNI7EGa6nWMZPhi_7VdQrbcayxk0ec,3684
|
|
102
102
|
ultralytics/models/rtdetr/val.py,sha256=6bNhHl_6JbpjuW4nlaojjDgmhbUNJy0J5Qz8FXZI9Gg,5555
|
|
@@ -115,7 +115,7 @@ ultralytics/models/utils/__init__.py,sha256=mHtJuK4hwF8cuV-VHDc7tp6u6D1gHz2Z7JI8
|
|
|
115
115
|
ultralytics/models/utils/loss.py,sha256=IMzcnDwwkgO9F6GDKVxrDdVdhUX_7d9uY4tX-AgtT0g,15134
|
|
116
116
|
ultralytics/models/utils/ops.py,sha256=sn1vdwIK2LaCvxvuuP31Yw2HXEMAmQdo7KD9JVh4GM4,13244
|
|
117
117
|
ultralytics/models/yolo/__init__.py,sha256=2mwHIBLgpsrrVgXPJiAWGQ1vIUIEdUT_fygaceicKRA,231
|
|
118
|
-
ultralytics/models/yolo/model.py,sha256=
|
|
118
|
+
ultralytics/models/yolo/model.py,sha256=88d-Jf2MBb8daLawuMtViegljifIwb4C0z20dFvbUVQ,3939
|
|
119
119
|
ultralytics/models/yolo/classify/__init__.py,sha256=t-4pUHmgI2gjhc-l3bqNEcEtKD1dO40nD4Vc6Y2xD6o,355
|
|
120
120
|
ultralytics/models/yolo/classify/predict.py,sha256=wFY4GIlWxe7idMndEw1RnDI63o53MTfiHKz0s2fOjAY,2513
|
|
121
121
|
ultralytics/models/yolo/classify/train.py,sha256=-DOLOM7OCN3RvH6iv8k7mMh7BDehsfJCO2LiwXMM0vU,6832
|
|
@@ -142,7 +142,7 @@ ultralytics/nn/tasks.py,sha256=JuXiYgnZBDC51MNTsaeSjz8H1ohio1Mx58l0EjdTm8c,42674
|
|
|
142
142
|
ultralytics/nn/modules/__init__.py,sha256=Ga3MDpwX6DeI7VSH8joti5uleP4mgkQGolbe8RLZ2T8,2326
|
|
143
143
|
ultralytics/nn/modules/block.py,sha256=yCHgCQTs2pIzCr7zqMJs8UF-3DM0-8X99k9vkEjv1ZA,25589
|
|
144
144
|
ultralytics/nn/modules/conv.py,sha256=ndUYNL2f9DK41y1vVbtEusMByXy-LMMsBKlcWjRQ9Z8,12722
|
|
145
|
-
ultralytics/nn/modules/head.py,sha256=
|
|
145
|
+
ultralytics/nn/modules/head.py,sha256=LonV2b7TrLx-zKhHQ2fCpKg7BfC-tUBtPlS5NNcfT_w,21728
|
|
146
146
|
ultralytics/nn/modules/transformer.py,sha256=AxD9uURpCl-EqvXe3DiG6JW-pBzB16G-AahLdZ7yayo,17909
|
|
147
147
|
ultralytics/nn/modules/utils.py,sha256=779QnnKp9v8jv251ESduTXJ0ol8HkIOLbGQWwEGQjhU,3196
|
|
148
148
|
ultralytics/solutions/__init__.py,sha256=mHtJuK4hwF8cuV-VHDc7tp6u6D1gHz2Z7JI8grmQDTs,42
|
|
@@ -189,9 +189,9 @@ ultralytics/utils/callbacks/neptune.py,sha256=5Z3ua5YBTUS56FH8VQKQG1aaIo9fH8GEyz
|
|
|
189
189
|
ultralytics/utils/callbacks/raytune.py,sha256=6OgGNuC35F29lw8Dl_d0lue4-iBR6dqrBVQnIRQDx4E,632
|
|
190
190
|
ultralytics/utils/callbacks/tensorboard.py,sha256=hRmWjbqdA4RNaLuSZznuDcpOBW-_-_Ga0u-B8UU-7ZI,4134
|
|
191
191
|
ultralytics/utils/callbacks/wb.py,sha256=4QI81nHdzgwhXHlmTiRxLqunvkKakLXYUhHTUY1ZeHA,6635
|
|
192
|
-
ultralytics-8.1.
|
|
193
|
-
ultralytics-8.1.
|
|
194
|
-
ultralytics-8.1.
|
|
195
|
-
ultralytics-8.1.
|
|
196
|
-
ultralytics-8.1.
|
|
197
|
-
ultralytics-8.1.
|
|
192
|
+
ultralytics-8.1.28.dist-info/LICENSE,sha256=DZak_2itbUtvHzD3E7GNUYSRK6jdOJ-GqncQ2weavLA,34523
|
|
193
|
+
ultralytics-8.1.28.dist-info/METADATA,sha256=z5ZtAppwngXhq_KIKb8DQ0b3Pp7v-OyHgqdLF2e2Rak,40330
|
|
194
|
+
ultralytics-8.1.28.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
|
|
195
|
+
ultralytics-8.1.28.dist-info/entry_points.txt,sha256=YM_wiKyTe9yRrsEfqvYolNO5ngwfoL4-NwgKzc8_7sI,93
|
|
196
|
+
ultralytics-8.1.28.dist-info/top_level.txt,sha256=XP49TwiMw4QGsvTLSYiJhz1xF_k7ev5mQ8jJXaXi45Q,12
|
|
197
|
+
ultralytics-8.1.28.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|