ultralytics 8.2.1__py3-none-any.whl → 8.2.2__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/cfg/__init__.py +2 -2
- ultralytics/cfg/default.yaml +1 -1
- ultralytics/engine/trainer.py +1 -1
- ultralytics/engine/validator.py +1 -1
- ultralytics/nn/autobackend.py +5 -2
- ultralytics/utils/__init__.py +3 -3
- ultralytics/utils/plotting.py +1 -6
- {ultralytics-8.2.1.dist-info → ultralytics-8.2.2.dist-info}/METADATA +2 -2
- {ultralytics-8.2.1.dist-info → ultralytics-8.2.2.dist-info}/RECORD +14 -14
- {ultralytics-8.2.1.dist-info → ultralytics-8.2.2.dist-info}/LICENSE +0 -0
- {ultralytics-8.2.1.dist-info → ultralytics-8.2.2.dist-info}/WHEEL +0 -0
- {ultralytics-8.2.1.dist-info → ultralytics-8.2.2.dist-info}/entry_points.txt +0 -0
- {ultralytics-8.2.1.dist-info → ultralytics-8.2.2.dist-info}/top_level.txt +0 -0
ultralytics/__init__.py
CHANGED
ultralytics/cfg/__init__.py
CHANGED
|
@@ -66,13 +66,13 @@ CLI_HELP_MSG = f"""
|
|
|
66
66
|
See all ARGS at https://docs.ultralytics.com/usage/cfg or with 'yolo cfg'
|
|
67
67
|
|
|
68
68
|
1. Train a detection model for 10 epochs with an initial learning_rate of 0.01
|
|
69
|
-
yolo train data=
|
|
69
|
+
yolo train data=coco8.yaml model=yolov8n.pt epochs=10 lr0=0.01
|
|
70
70
|
|
|
71
71
|
2. Predict a YouTube video using a pretrained segmentation model at image size 320:
|
|
72
72
|
yolo predict model=yolov8n-seg.pt source='https://youtu.be/LNwODJXcvt4' imgsz=320
|
|
73
73
|
|
|
74
74
|
3. Val a pretrained detection model at batch-size 1 and image size 640:
|
|
75
|
-
yolo val model=yolov8n.pt data=
|
|
75
|
+
yolo val model=yolov8n.pt data=coco8.yaml batch=1 imgsz=640
|
|
76
76
|
|
|
77
77
|
4. Export a YOLOv8n classification model to ONNX format at image size 224 by 128 (no TASK required)
|
|
78
78
|
yolo export model=yolov8n-cls.pt format=onnx imgsz=224,128
|
ultralytics/cfg/default.yaml
CHANGED
|
@@ -6,7 +6,7 @@ mode: train # (str) YOLO mode, i.e. train, val, predict, export, track, benchmar
|
|
|
6
6
|
|
|
7
7
|
# Train settings -------------------------------------------------------------------------------------------------------
|
|
8
8
|
model: # (str, optional) path to model file, i.e. yolov8n.pt, yolov8n.yaml
|
|
9
|
-
data: # (str, optional) path to data file, i.e.
|
|
9
|
+
data: # (str, optional) path to data file, i.e. coco8.yaml
|
|
10
10
|
epochs: 100 # (int) number of epochs to train for
|
|
11
11
|
time: # (float, optional) number of hours to train for, overrides epochs if supplied
|
|
12
12
|
patience: 100 # (int) epochs to wait for no observable improvement for early stopping of training
|
ultralytics/engine/trainer.py
CHANGED
ultralytics/engine/validator.py
CHANGED
ultralytics/nn/autobackend.py
CHANGED
|
@@ -234,8 +234,11 @@ class AutoBackend(nn.Module):
|
|
|
234
234
|
logger = trt.Logger(trt.Logger.INFO)
|
|
235
235
|
# Read file
|
|
236
236
|
with open(w, "rb") as f, trt.Runtime(logger) as runtime:
|
|
237
|
-
|
|
238
|
-
|
|
237
|
+
try:
|
|
238
|
+
meta_len = int.from_bytes(f.read(4), byteorder="little") # read metadata length
|
|
239
|
+
metadata = json.loads(f.read(meta_len).decode("utf-8")) # read metadata
|
|
240
|
+
except UnicodeDecodeError:
|
|
241
|
+
f.seek(0) # engine file may lack embedded Ultralytics metadata
|
|
239
242
|
model = runtime.deserialize_cuda_engine(f.read()) # read engine
|
|
240
243
|
|
|
241
244
|
# Model context
|
ultralytics/utils/__init__.py
CHANGED
|
@@ -61,7 +61,7 @@ HELP_MSG = """
|
|
|
61
61
|
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
|
62
62
|
|
|
63
63
|
# Use the model
|
|
64
|
-
results = model.train(data="
|
|
64
|
+
results = model.train(data="coco8.yaml", epochs=3) # train the model
|
|
65
65
|
results = model.val() # evaluate model performance on the validation set
|
|
66
66
|
results = model('https://ultralytics.com/images/bus.jpg') # predict on an image
|
|
67
67
|
success = model.export(format='onnx') # export the model to ONNX format
|
|
@@ -78,13 +78,13 @@ HELP_MSG = """
|
|
|
78
78
|
See all ARGS at https://docs.ultralytics.com/usage/cfg or with 'yolo cfg'
|
|
79
79
|
|
|
80
80
|
- Train a detection model for 10 epochs with an initial learning_rate of 0.01
|
|
81
|
-
yolo detect train data=
|
|
81
|
+
yolo detect train data=coco8.yaml model=yolov8n.pt epochs=10 lr0=0.01
|
|
82
82
|
|
|
83
83
|
- Predict a YouTube video using a pretrained segmentation model at image size 320:
|
|
84
84
|
yolo segment predict model=yolov8n-seg.pt source='https://youtu.be/LNwODJXcvt4' imgsz=320
|
|
85
85
|
|
|
86
86
|
- Val a pretrained detection model at batch-size 1 and image size 640:
|
|
87
|
-
yolo detect val model=yolov8n.pt data=
|
|
87
|
+
yolo detect val model=yolov8n.pt data=coco8.yaml batch=1 imgsz=640
|
|
88
88
|
|
|
89
89
|
- Export a YOLOv8n classification model to ONNX format at image size 224 by 128 (no TASK required)
|
|
90
90
|
yolo export model=yolov8n-cls.pt format=onnx imgsz=224,128
|
ultralytics/utils/plotting.py
CHANGED
|
@@ -440,12 +440,9 @@ class Annotator:
|
|
|
440
440
|
text_x = self.im.shape[1] - int(self.im.shape[1] * 0.025 + max_text_width)
|
|
441
441
|
text_y = int(self.im.shape[0] * 0.025)
|
|
442
442
|
|
|
443
|
-
# Calculate dynamic gap between each count value based on the width of the image
|
|
444
|
-
dynamic_gap = max(1, self.im.shape[1] // 100) * tf
|
|
445
|
-
|
|
446
443
|
for i, count in enumerate(counts):
|
|
447
444
|
text_x_pos = text_x
|
|
448
|
-
text_y_pos = text_y + i *
|
|
445
|
+
text_y_pos = text_y + i * (max_text_height + 25 * tf)
|
|
449
446
|
|
|
450
447
|
# Draw the border
|
|
451
448
|
cv2.rectangle(
|
|
@@ -468,8 +465,6 @@ class Annotator:
|
|
|
468
465
|
lineType=cv2.LINE_AA,
|
|
469
466
|
)
|
|
470
467
|
|
|
471
|
-
text_y_pos += tf * max_text_height
|
|
472
|
-
|
|
473
468
|
@staticmethod
|
|
474
469
|
def estimate_pose_angle(a, b, c):
|
|
475
470
|
"""
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: ultralytics
|
|
3
|
-
Version: 8.2.
|
|
3
|
+
Version: 8.2.2
|
|
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
|
|
@@ -168,7 +168,7 @@ model = YOLO("yolov8n.yaml") # build a new model from scratch
|
|
|
168
168
|
model = YOLO("yolov8n.pt") # load a pretrained model (recommended for training)
|
|
169
169
|
|
|
170
170
|
# Use the model
|
|
171
|
-
model.train(data="
|
|
171
|
+
model.train(data="coco8.yaml", epochs=3) # train the model
|
|
172
172
|
metrics = model.val() # evaluate model performance on the validation set
|
|
173
173
|
results = model("https://ultralytics.com/images/bus.jpg") # predict on an image
|
|
174
174
|
path = model.export(format="onnx") # export the model to ONNX format
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
ultralytics/__init__.py,sha256=
|
|
1
|
+
ultralytics/__init__.py,sha256=cL4PVaHbKje8it1MXrZE9VsBIJTpuATEUI5p2I7YuEo,632
|
|
2
2
|
ultralytics/assets/bus.jpg,sha256=wCAZxJecGR63Od3ZRERe9Aja1Weayrb9Ug751DS_vGM,137419
|
|
3
3
|
ultralytics/assets/zidane.jpg,sha256=Ftc4aeMmen1O0A3o6GCDO9FlfBslLpTAw0gnetx7bts,50427
|
|
4
|
-
ultralytics/cfg/__init__.py,sha256=
|
|
5
|
-
ultralytics/cfg/default.yaml,sha256=
|
|
4
|
+
ultralytics/cfg/__init__.py,sha256=4ZnvY2ULMGofFhjaRIzKQlGC5YVkvWkEAYAhnsKC1Po,21312
|
|
5
|
+
ultralytics/cfg/default.yaml,sha256=KoXq5DHQK-Voge9DbkySd2rRpDizG6Oq-A4Byqz5Exc,8211
|
|
6
6
|
ultralytics/cfg/datasets/Argoverse.yaml,sha256=FyeuJT5CHq_9d4hlfAf0kpZlnbUMO0S--UJ1yIqcdKk,3134
|
|
7
7
|
ultralytics/cfg/datasets/DOTAv1.5.yaml,sha256=YDsyFPI6F6-OQXLBM3hOXo3vADYREwZzmMQfJNdpWyM,1193
|
|
8
8
|
ultralytics/cfg/datasets/DOTAv1.yaml,sha256=dxLUliHvJOW4q4vJRu5qIYVvNfjvXWB7GVh_Fhk--dM,1163
|
|
@@ -82,9 +82,9 @@ ultralytics/engine/exporter.py,sha256=KW3PwxgzlNBj44oiYAKT4PVS4uexLZT5H8Qevc2Q8q
|
|
|
82
82
|
ultralytics/engine/model.py,sha256=4zSVSBP8Ex49bJjnOXm7g3Qr_NgbplHPCjdnVfZwfxM,40019
|
|
83
83
|
ultralytics/engine/predictor.py,sha256=wQRKdWGDTP5A6CS0gTC6U3RPDMhP3QkEzWSPm6eqCkU,17022
|
|
84
84
|
ultralytics/engine/results.py,sha256=MvrOBrBlRF7kbL-QwysMf9mIDy_lwQBTTYvy1x1FMME,30667
|
|
85
|
-
ultralytics/engine/trainer.py,sha256=
|
|
85
|
+
ultralytics/engine/trainer.py,sha256=FK2PkQyUThIU5RYr8Qa38JZDRB3iOl85Sdbi4HrlQ5U,34987
|
|
86
86
|
ultralytics/engine/tuner.py,sha256=iZrgMmXSDpfuDu4bdFRflmAsscys2-8W8qAGxSyOVJE,11844
|
|
87
|
-
ultralytics/engine/validator.py,sha256=
|
|
87
|
+
ultralytics/engine/validator.py,sha256=Y21Uo8_Zto4qjk_YqQk6k7tyfpq_Qk9cfjeXeyDRxs8,14643
|
|
88
88
|
ultralytics/hub/__init__.py,sha256=U4j-2QPdwSDlxw6RgFYnnJXOoIzLtwke4TkY2A8q4ws,5068
|
|
89
89
|
ultralytics/hub/auth.py,sha256=FID58NE6fh7Op_B45QOpWBw1qoBN0ponL16uvyb2dZ8,5399
|
|
90
90
|
ultralytics/hub/session.py,sha256=Oly3bKjLkW08iOm3QoSr6Yy57aLZ4AmAmF6Pp9Y_q5g,15197
|
|
@@ -145,7 +145,7 @@ ultralytics/models/yolo/world/__init__.py,sha256=3VTH0q4NOt2EWRom15yCymvmvm0Etp2
|
|
|
145
145
|
ultralytics/models/yolo/world/train.py,sha256=acYN2-onL69LrL4av6_hY2r5AY0urC0WViDstn7npfI,3686
|
|
146
146
|
ultralytics/models/yolo/world/train_world.py,sha256=ICPsYNbuPkq_qf3FHl2YJ-q3g7ik0pI-zhMpLmHa5-4,4805
|
|
147
147
|
ultralytics/nn/__init__.py,sha256=4BPLHY89xEM_al5uK0aOmFgiML6CMGEZbezxOvTjOEs,587
|
|
148
|
-
ultralytics/nn/autobackend.py,sha256=
|
|
148
|
+
ultralytics/nn/autobackend.py,sha256=6amaXnbDlvh0kTIbeHV3kIM6X7P1r0T3le1GPxIgkOs,30864
|
|
149
149
|
ultralytics/nn/tasks.py,sha256=a3FSkIUErlE7qI506ye5vGggqzMxqXWDkIbbLD4AGyI,43623
|
|
150
150
|
ultralytics/nn/modules/__init__.py,sha256=KzLoyn2ldfReiQL8H8xsMC49Xvtb8Kv9ikE5Q3OBoAs,2326
|
|
151
151
|
ultralytics/nn/modules/block.py,sha256=smIz3oNTDA7UKrAH5FfSMh08C12-avgWTeIkbgZIv18,25251
|
|
@@ -169,7 +169,7 @@ ultralytics/trackers/utils/__init__.py,sha256=mHtJuK4hwF8cuV-VHDc7tp6u6D1gHz2Z7J
|
|
|
169
169
|
ultralytics/trackers/utils/gmc.py,sha256=vwcPA1n5zjPaBGhCDt8ItN7rq_6Sczsjn4gsXJfRylU,13688
|
|
170
170
|
ultralytics/trackers/utils/kalman_filter.py,sha256=0oqhk59NKEiwcJ2FXnw6_sT4bIFC6Wu5IY2B-TGxJKU,15168
|
|
171
171
|
ultralytics/trackers/utils/matching.py,sha256=UxhSGa5pN6WoYwYSBAkkt-O7xMxUR47VuUB6PfVNkb4,5404
|
|
172
|
-
ultralytics/utils/__init__.py,sha256=
|
|
172
|
+
ultralytics/utils/__init__.py,sha256=BdmRL2UhbmzmWuhaB1iDUTOyQ3fTwOrB0aUijAgpOUg,39286
|
|
173
173
|
ultralytics/utils/autobatch.py,sha256=ygZ3f2ByIkcujB89ENcTnGWWnAQw5Pbg6nBuShg-5t4,3863
|
|
174
174
|
ultralytics/utils/benchmarks.py,sha256=dVAQ7GjZmgjvGL9JglKA3d9HAnvGoyX2TaEmZJjk0HA,18539
|
|
175
175
|
ultralytics/utils/checks.py,sha256=UDrcHiTMjSHSyUZflTRGuyYRj0uz9-RQ-xfDq_lsXZo,27971
|
|
@@ -182,7 +182,7 @@ ultralytics/utils/loss.py,sha256=ejXnPEIAzNEoNz2UjW0_fcdeUs9Hy-jPzUrJ3FiIIwE,327
|
|
|
182
182
|
ultralytics/utils/metrics.py,sha256=XPD-xP0fchR8KgCuTcihV2-n0EK1cWi3-53BWN_pLuA,53518
|
|
183
183
|
ultralytics/utils/ops.py,sha256=wZCWx7dm5GJNIJHyZaFJRetGcQ7prdv-anplqq9figQ,33309
|
|
184
184
|
ultralytics/utils/patches.py,sha256=SgMqeMsq2K6JoBJP1NplXMl9C6rK0JeJUChjBrJOneo,2750
|
|
185
|
-
ultralytics/utils/plotting.py,sha256=
|
|
185
|
+
ultralytics/utils/plotting.py,sha256=bmuQIlH8wJRp9ASRmVfiXJrr4iDwEPTS_8WniCzyqVc,47332
|
|
186
186
|
ultralytics/utils/tal.py,sha256=xuIyryUjaaYHkHPG9GvBwh1xxN2Hq4y3hXOtuERehwY,16017
|
|
187
187
|
ultralytics/utils/torch_utils.py,sha256=y1qJniyii0sJFg8dpP-yjYh8AMOoFok9NEZcRi669Jo,25916
|
|
188
188
|
ultralytics/utils/triton.py,sha256=gg1finxno_tY2Ge9PMhmu7PI9wvoFZoiicdT4Bhqv3w,3936
|
|
@@ -198,9 +198,9 @@ ultralytics/utils/callbacks/neptune.py,sha256=5Z3ua5YBTUS56FH8VQKQG1aaIo9fH8GEyz
|
|
|
198
198
|
ultralytics/utils/callbacks/raytune.py,sha256=ODVYzy-CoM4Uge0zjkh3Hnh9nF2M0vhDrSenXnvcizw,705
|
|
199
199
|
ultralytics/utils/callbacks/tensorboard.py,sha256=Z1veCVcn9THPhdplWuIzwlsW2yF7y-On9IZIk3khM0Y,4135
|
|
200
200
|
ultralytics/utils/callbacks/wb.py,sha256=woCQVuZzqtM5KnwxIibcfM3sFBYojeMPnv11jrRaIQA,6674
|
|
201
|
-
ultralytics-8.2.
|
|
202
|
-
ultralytics-8.2.
|
|
203
|
-
ultralytics-8.2.
|
|
204
|
-
ultralytics-8.2.
|
|
205
|
-
ultralytics-8.2.
|
|
206
|
-
ultralytics-8.2.
|
|
201
|
+
ultralytics-8.2.2.dist-info/LICENSE,sha256=DZak_2itbUtvHzD3E7GNUYSRK6jdOJ-GqncQ2weavLA,34523
|
|
202
|
+
ultralytics-8.2.2.dist-info/METADATA,sha256=CnxRE4dEVOgykApuwfT8TswCppWNigG1efP-1Ut3Ptc,40448
|
|
203
|
+
ultralytics-8.2.2.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
|
|
204
|
+
ultralytics-8.2.2.dist-info/entry_points.txt,sha256=YM_wiKyTe9yRrsEfqvYolNO5ngwfoL4-NwgKzc8_7sI,93
|
|
205
|
+
ultralytics-8.2.2.dist-info/top_level.txt,sha256=XP49TwiMw4QGsvTLSYiJhz1xF_k7ev5mQ8jJXaXi45Q,12
|
|
206
|
+
ultralytics-8.2.2.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|