Ultralytics YOLO
tensoris.lib.integrations.ultralytics ¶
Ultralytics YOLO Integration Helper.
Classes¶
UltralyticsIntegration ¶
Ultralytics YOLO model helper for object detection, segmentation, and classification workflows.
References
Ultralytics Documentation: https://docs.ultralytics.com/
Source code in src/tensoris/lib/integrations/ultralytics.py
Attributes¶
Methods:¶
__init__ ¶
Initialize Ultralytics YOLO model.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model_name
|
str
|
Pretrained YOLO weight file or config path (e.g. 'yolov8n.pt', 'yolov8x-seg.pt'). |
'yolov8n.pt'
|
Source code in src/tensoris/lib/integrations/ultralytics.py
export ¶
Export trained YOLO model to deployment format (ONNX, TorchScript, Engine).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
format
|
str
|
Output target format ('onnx', 'torchscript', 'engine', 'openvino'). |
'onnx'
|
Returns:
| Type | Description |
|---|---|
str
|
String path of exported model weight file. |
Source code in src/tensoris/lib/integrations/ultralytics.py
load_model ¶
Instantiate Ultralytics YOLO model class.
Source code in src/tensoris/lib/integrations/ultralytics.py
train ¶
Train YOLO model on dataset.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
data_yaml
|
str | Path
|
Path to dataset configuration YAML file. |
required |
epochs
|
int
|
Training epoch count. |
50
|
imgsz
|
int
|
Target image resolution size. |
640
|
batch
|
int
|
Training batch size. |
16
|
Returns:
| Type | Description |
|---|---|
Any
|
Training results object. |