Giter Club home page Giter Club logo

Comments (3)

xiang-wuu avatar xiang-wuu commented on July 27, 2024

you have to exclude the detect layer while exporting from pytorch to onnx, you are trying to export end-to-end model.

from ncnn-android-yolov7.

jhony2507 avatar jhony2507 commented on July 27, 2024

Hi xiang-wu,

Thanks for your quick feedback. I've corrected my error, but I'm still having problems with the model.
After exporting the custom weights to nccn and running the application, I realized that net doesn't do any detection (the anchor boxes are never shown), the application works like a camera.
Below is the step by step that I am using.

a) My network is used to detect fruit diseases. It comprises about 20,000 images, with 9 classes and achieves a mAP of approximately 87% in yolov7-tiny

b) .PT --> onnx
python export.py --weights yolo-papaya-tiny.pt --simplify --topk-all 100 --iou-thres 0.50 --conf-thres 0.15 --img-size 448 448 --max-wh 448

c) onnx --> ncnn

./onnx2ncnn yolo-papaya-tiny.onnx yolo-papaya-tiny.param yolo-papaya-tiny.bin

d) After conversion, the weights are renamed and transferred to the application folder

If you have the time and inclination to point me out where I'm going wrong, I'd be very grateful.
I am also attaching the weights after converting to ncnn

ncnn - yolo-papaya-tiny.zip
Origin-yolo-papaya-tiny.zip

from ncnn-android-yolov7.

UnrealSam avatar UnrealSam commented on July 27, 2024

you have to exclude the detect layer while exporting from pytorch to onnx, you are trying to export end-to-end model.

能加个邮箱吗?我们有些问题想要咨询,我的邮箱在主页介绍那里

from ncnn-android-yolov7.

Related Issues (19)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.