airockchip / rknn_model_zoo

Apache License 2.0
1.06k stars 195 forks source link

python yolov8.py error #200

Open lxy1015 opened 1 month ago

lxy1015 commented 1 month ago

/home/cas/Desktop/rknn_model_zoo/py_utils/onnx_executor.py:12: FutureWarning: In the future np.bool will be defined as the corresponding NumPy scalar. if getattr(np, 'bool', False): Model-../model/yolov8n.onnx is onnx model, starting val position.shape: (1, 84, 8400) Traceback (most recent call last): File "yolov8.py", line 265, in boxes, classes, scores = post_process(outputs) File "yolov8.py", line 124, in post_process boxes.append(box_process(input_data[pair_per_branch*i])) File "yolov8.py", line 104, in box_process grid_h, grid_w = position.shape[2:4] ValueError: not enough values to unpack (expected 2, got 1)

zen-xingle commented 1 month ago

Follow https://github.com/airockchip/rknn_model_zoo/blob/main/examples/yolov8/README.md to export/get the onnx model for the demo provided in this repo.

lxy1015 commented 1 month ago

Follow https://github.com/airockchip/rknn_model_zoo/blob/main/examples/yolov8/README.md to export/get the onnx model for the demo provided in this repo.

I want to ask how to export the onnx format available for rknn from the pt/pth file? Or can I only use the provided onnx model by official?