ultralytics 8.1.29__py3-none-any.whl → 8.1.30__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.
ultralytics/__init__.py CHANGED
@@ -1,6 +1,6 @@
1
1
  # Ultralytics YOLO 🚀, AGPL-3.0 license
2
2
 
3
- __version__ = "8.1.29"
3
+ __version__ = "8.1.30"
4
4
 
5
5
  from ultralytics.data.explorer.explorer import Explorer
6
6
  from ultralytics.models import RTDETR, SAM, YOLO, YOLOWorld
@@ -0,0 +1,22 @@
1
+ # Ultralytics YOLO 🚀, AGPL-3.0 license
2
+ # Brain-tumor dataset by Ultralytics
3
+ # Documentation: https://docs.ultralytics.com/datasets/detect/brain-tumor/
4
+ # Example usage: yolo train data=brain-tumor.yaml
5
+ # parent
6
+ # ├── ultralytics
7
+ # └── datasets
8
+ # └── brain-tumor ← downloads here (4.05 MB)
9
+
10
+ # Train/val/test sets as 1) dir: path/to/imgs, 2) file: path/to/imgs.txt, or 3) list: [path/to/imgs1, path/to/imgs2, ..]
11
+ path: ../datasets/brain-tumor # dataset root dir
12
+ train: train/images # train images (relative to 'path') 893 images
13
+ val: valid/images # val images (relative to 'path') 223 images
14
+ test: # test images (relative to 'path')
15
+
16
+ # Classes
17
+ names:
18
+ 0: negative
19
+ 1: positive
20
+
21
+ # Download script/URL (optional)
22
+ download: https://ultralytics.com/assets/brain-tumor.zip
@@ -124,7 +124,7 @@ class Model(nn.Module):
124
124
  # Check if Ultralytics HUB model from https://hub.ultralytics.com
125
125
  if self.is_hub_model(model):
126
126
  # Fetch model from HUB
127
- checks.check_requirements("hub-sdk>0.0.2")
127
+ checks.check_requirements("hub-sdk>=0.0.5")
128
128
  self.session = self._get_hub_session(model)
129
129
  model = self.session.model_file
130
130
 
@@ -170,10 +170,19 @@ class HUBTrainingSession:
170
170
 
171
171
  return api_key, model_id, filename
172
172
 
173
- def _set_train_args(self, **kwargs):
174
- """Initializes training arguments and creates a model entry on the Ultralytics HUB."""
173
+ def _set_train_args(self):
174
+ """
175
+ Initializes training arguments and creates a model entry on the Ultralytics HUB.
176
+
177
+ This method sets up training arguments based on the model's state and updates them with any additional
178
+ arguments provided. It handles different states of the model, such as whether it's resumable, pretrained,
179
+ or requires specific file setup.
180
+
181
+ Raises:
182
+ ValueError: If the model is already trained, if required dataset information is missing, or if there are
183
+ issues with the provided training arguments.
184
+ """
175
185
  if self.model.is_trained():
176
- # Model is already trained
177
186
  raise ValueError(emojis(f"Model is already trained and uploaded to {self.model_url} 🚀"))
178
187
 
179
188
  if self.model.is_resumable():
@@ -182,26 +191,16 @@ class HUBTrainingSession:
182
191
  self.model_file = self.model.get_weights_url("last")
183
192
  else:
184
193
  # Model has no saved weights
185
- def get_train_args(config):
186
- """Parses an identifier to extract API key, model ID, and filename if applicable."""
187
- return {
188
- "batch": config["batchSize"],
189
- "epochs": config["epochs"],
190
- "imgsz": config["imageSize"],
191
- "patience": config["patience"],
192
- "device": config["device"],
193
- "cache": config["cache"],
194
- "data": self.model.get_dataset_url(),
195
- }
196
-
197
- self.train_args = get_train_args(self.model.data.get("config"))
194
+ self.train_args = self.model.data.get("train_args") # new response
195
+
198
196
  # Set the model file as either a *.pt or *.yaml file
199
197
  self.model_file = (
200
198
  self.model.get_weights_url("parent") if self.model.is_pretrained() else self.model.get_architecture()
201
199
  )
202
200
 
203
- if not self.train_args.get("data"):
204
- raise ValueError("Dataset may still be processing. Please wait a minute and try again.") # RF fix
201
+ if "data" not in self.train_args:
202
+ # RF bug - datasets are sometimes not exported
203
+ raise ValueError("Dataset may still be processing. Please wait a minute and try again.")
205
204
 
206
205
  self.model_file = checks.check_yolov5u_filename(self.model_file, verbose=False) # YOLOv5->YOLOv5u
207
206
  self.model_id = self.model.id
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: ultralytics
3
- Version: 8.1.29
3
+ Version: 8.1.30
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=7UA9LH2W9UWNw5SAvHbloCjYzJAGxqcg52Yz3eQ9wjc,625
1
+ ultralytics/__init__.py,sha256=y3rrZQyZ7nf8yoKZN7enFZlfdqblvoOfLg-fRMhep5Q,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
@@ -12,6 +12,7 @@ ultralytics/cfg/datasets/Objects365.yaml,sha256=kiiV4KLMH2mcPPRrg6cQGygnbiTrHxwt
12
12
  ultralytics/cfg/datasets/SKU-110K.yaml,sha256=geRkccBRl2eKgfNYTOPYwD9mTfqktTBGiMJoE3PZEnA,2493
13
13
  ultralytics/cfg/datasets/VOC.yaml,sha256=3-CDpjIq_s5pkbsJ9TjrYIeV24rYGuJGu4Qg6uktEZE,3655
14
14
  ultralytics/cfg/datasets/VisDrone.yaml,sha256=NfrbjVnE48E7TPbxtF7rtQHvVBO0DchFJFEuGrG1VRU,3073
15
+ ultralytics/cfg/datasets/brain-tumor.yaml,sha256=o1rX1_iw97HjiG904l4u42x13jyHOGvfmWEzz0BpOZg,795
15
16
  ultralytics/cfg/datasets/carparts-seg.yaml,sha256=pvTi3EH2j6UuG0LHoQJ7JjQv_cJoO8UKSXPptUTnl8U,1207
16
17
  ultralytics/cfg/datasets/coco-pose.yaml,sha256=w7H-J2e87GIV_PZdRDgqEFa75ObScpBK_l85U4ZMsMo,1603
17
18
  ultralytics/cfg/datasets/coco.yaml,sha256=xbim-GcWpvF_uwlStjbPjxXFhVfL0U_WNQI99b5gjdY,2584
@@ -74,7 +75,7 @@ ultralytics/data/explorer/gui/__init__.py,sha256=mHtJuK4hwF8cuV-VHDc7tp6u6D1gHz2
74
75
  ultralytics/data/explorer/gui/dash.py,sha256=a2s8oJKI8kqnWEcIyqCCzvIyvM_uZmfMaxrOdwmiq7k,10044
75
76
  ultralytics/engine/__init__.py,sha256=mHtJuK4hwF8cuV-VHDc7tp6u6D1gHz2Z7JI8grmQDTs,42
76
77
  ultralytics/engine/exporter.py,sha256=pwTQCo88Sd41NqYKx5Jp15fSqhFgaY3Z5gfLm8uzLR0,53882
77
- ultralytics/engine/model.py,sha256=Kh5Bs3Rq6xJnpwCBtKFonNBLXYScg81uhj6zXx16bBw,39193
78
+ ultralytics/engine/model.py,sha256=SD9bLH30PGqnIxXT1uxgHu5xlrgca8jV2luErK9Fh8w,39194
78
79
  ultralytics/engine/predictor.py,sha256=wQRKdWGDTP5A6CS0gTC6U3RPDMhP3QkEzWSPm6eqCkU,17022
79
80
  ultralytics/engine/results.py,sha256=SY3sn2OBMfAFaPoaDKo0Wu-jSi7avISYohjtR_bur9M,30120
80
81
  ultralytics/engine/trainer.py,sha256=C04cEN9v-kvR2dIIjgAN8dBAx8XSTChlQkDxAxfwTlU,34527
@@ -82,7 +83,7 @@ ultralytics/engine/tuner.py,sha256=DzgTH3uk-VUUVoJ0K3tM4N5TJ6A3fMNlcDYr5g2I9lA,1
82
83
  ultralytics/engine/validator.py,sha256=rcmJSGrsAfj-ryQktv6-fe0hAT7Z8CLNhUUUf0VsPYI,14645
83
84
  ultralytics/hub/__init__.py,sha256=hNKAjBFZAi8_ZYasurDpDMlEOmFw0GrXCV7kLb2A-zE,5068
84
85
  ultralytics/hub/auth.py,sha256=hc97pJ01OfI8oQ7uw3ubKbiVCDSGxSGJHoo9W6hrrNw,5403
85
- ultralytics/hub/session.py,sha256=DXPQcPHFS84DlSbXnsfwUfCgjv5W4F3ioA7ADMWzm7w,14703
86
+ ultralytics/hub/session.py,sha256=kFwufDIY7TeV79DdEQBKYrU5883WxgCrpJoTr1S5QuE,14649
86
87
  ultralytics/hub/utils.py,sha256=BoqNvi7yLUGrTNVEugFALhJkmpobW87gMVZ2dzDckRk,9734
87
88
  ultralytics/models/__init__.py,sha256=xrzn2dcLBG6Ujxll8LtlTIblPar2gjNhAwjAQg7u8sk,197
88
89
  ultralytics/models/fastsam/__init__.py,sha256=0dt65jZ_5b7Q-mdXN8MSEkgnFRA0FIwlel_LS2RaOlU,254
@@ -189,9 +190,9 @@ ultralytics/utils/callbacks/neptune.py,sha256=5Z3ua5YBTUS56FH8VQKQG1aaIo9fH8GEyz
189
190
  ultralytics/utils/callbacks/raytune.py,sha256=6OgGNuC35F29lw8Dl_d0lue4-iBR6dqrBVQnIRQDx4E,632
190
191
  ultralytics/utils/callbacks/tensorboard.py,sha256=hRmWjbqdA4RNaLuSZznuDcpOBW-_-_Ga0u-B8UU-7ZI,4134
191
192
  ultralytics/utils/callbacks/wb.py,sha256=4QI81nHdzgwhXHlmTiRxLqunvkKakLXYUhHTUY1ZeHA,6635
192
- ultralytics-8.1.29.dist-info/LICENSE,sha256=DZak_2itbUtvHzD3E7GNUYSRK6jdOJ-GqncQ2weavLA,34523
193
- ultralytics-8.1.29.dist-info/METADATA,sha256=1OiGudI0YbTVUtgIC8sG-0FyPFhnx5e20ZDamo8wGyo,40330
194
- ultralytics-8.1.29.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
195
- ultralytics-8.1.29.dist-info/entry_points.txt,sha256=YM_wiKyTe9yRrsEfqvYolNO5ngwfoL4-NwgKzc8_7sI,93
196
- ultralytics-8.1.29.dist-info/top_level.txt,sha256=XP49TwiMw4QGsvTLSYiJhz1xF_k7ev5mQ8jJXaXi45Q,12
197
- ultralytics-8.1.29.dist-info/RECORD,,
193
+ ultralytics-8.1.30.dist-info/LICENSE,sha256=DZak_2itbUtvHzD3E7GNUYSRK6jdOJ-GqncQ2weavLA,34523
194
+ ultralytics-8.1.30.dist-info/METADATA,sha256=jcr1FoTfvyZJje_RUgRa9cLOykDJET_PeiwWrYg70Ys,40330
195
+ ultralytics-8.1.30.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
196
+ ultralytics-8.1.30.dist-info/entry_points.txt,sha256=YM_wiKyTe9yRrsEfqvYolNO5ngwfoL4-NwgKzc8_7sI,93
197
+ ultralytics-8.1.30.dist-info/top_level.txt,sha256=XP49TwiMw4QGsvTLSYiJhz1xF_k7ev5mQ8jJXaXi45Q,12
198
+ ultralytics-8.1.30.dist-info/RECORD,,