-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
trouble with converted a custom yolov5s.pt #4261
Comments
ncnn is open source, you can debug with source code. |
I tried pnnx as follows: But I got the following messages:
BTW: I trained my model using the main repository of yolov5 ([https://github.com/ultralytics/yolov5]) |
I tried to convert YOLOX to NCNN by PNNX, I also met this issue |
针对onnx模型转换的各种问题,推荐使用最新的pnnx工具转换到ncnn pip install pnnx
pnnx model.onnx inputshape=[1,3,224,224] 详细参考文档 |
我也是一样的 |
ch) root@wjmqtuiaofmgpalu-snow-78c7b646d-5vb4w:/data/miniconda/envs/torch/lib/python3.10/site-packages/pnnx# ./pnnx /data/coding/best.pt inputshape=[1,3,224, |
Hi, I am having trouble with a converted custom yolov5s.pt to ncnn:
I have trained a custom yolov5s.pt object detector with two classes, say my_yolov5s.pt. Then, I converted it to my_yolov5s.onnx using the yolov5/export.py:
python export.py --weights my_yolov5s.pt --include onnx --simplify
Later, I tried to convert the model into ncnn using onnx2ncnn.exe:
onnx2ncnn.exe my_yolov5s.onnx my_yolov5s.param my_yolov5s.bin
Up to this point, everything went smoothly. However, while I am trying to inference using ncnn version of my model, it crashes at
ex.extract("output0", out)
I am attaching the screenshot of the Exception message. I appreciate any help or suggestions.
The text was updated successfully, but these errors were encountered: