yolonas_object_detection
YOLONASObjectDetection
¶
Bases: ObjectDetectionBaseOnnxRoboflowInferenceModel
Source code in inference/models/yolonas/yolonas_object_detection.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 |
|
weights_file: str
property
¶
Gets the weights file for the YOLO-NAS model.
Returns:
Name | Type | Description |
---|---|---|
str |
str
|
Path to the ONNX weights file. |
predict(img_in, **kwargs)
¶
Performs object detection on the given image using the ONNX session.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
img_in
|
ndarray
|
Input image as a NumPy array. |
required |
Returns:
Type | Description |
---|---|
Tuple[ndarray]
|
Tuple[np.ndarray]: NumPy array representing the predictions, including boxes, confidence scores, and class confidence scores. |
Source code in inference/models/yolonas/yolonas_object_detection.py
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 |
|