Giter VIP home page Giter VIP logo

yolov5_ncnn's Introduction

𝗛𝗲𝗹𝗹𝗼!

  • Java Kotlin C C++ Objective-C Swift Python HTML5 CSS JavaScript TypeScript Rust Dart Golang
  • PyTorch Numpy React Vue Svelte
  • VSCode Android Studio Xcode PyCharm CLion IntelliJ IDEA WebStorm
  • Windows Linux Android iOS macOS
  • Raspberry Pi

teng's GitHub Stats Top Langs

┌───┐   ┌───┬───┬───┬───┐ ┌───┬───┬───┬───┐ ┌───┬───┬───┬───┐ ┌───┬───┬───┐
│Esc│   │ F1│ F2│ F3│ F4│ │ F5│ F6│ F7│ F8│ │ F9│F10│F11│F12│ │P/S│S L│P/B│  ┌┐    ┌┐    ┌┐            │
└───┘   └───┴───┴───┴───┘ └───┴───┴───┴───┘ └───┴───┴───┴───┘ └───┴───┴───┘  └┘    └┘    └┘            │
┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───────┐ ┌───┬───┬───┐ ┌───┬───┬───┬───┐          │
│~ `│! 1│@ 2│# 3│$ 4│% 5│^ 6│& 7│* 8│( 9│) 0│_ -│+ =│ BacSp │ │Ins│Hom│PUp│ │N L│ / │ * │ - │   ┌──────┼──────┐
├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─────┤ ├───┼───┼───┤ ├───┼───┼───┼───┤   │     ┌┴┐     │
│ Tab │ Q │ W │ E │ R │ T │ Y │ U │ I │ O │ P │{ [│} ]│ | \ │ │Del│End│PDn│ │ 7 │ 8 │ 9 │   │   │     └┬┘     │
├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┤ └───┴───┴───┘ ├───┼───┼───┤ + │   ├──────┴──────┤
│ Caps │ A │ S │ D │ F │ G │ H │ J │ K │ L │: ;│" '│ Enter  │               │ 4 │ 5 │ 6 │   │   │             │
├──────┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────────┤     ┌───┐     ├───┼───┼───┼───┤   │             │
│ Shift  │ Z │ X │ C │ V │ B │ N │ M │< ,│> .│? /│  Shift   │     │ ↑ │     │ 1 │ 2 │ 3 │   │   │             │
├─────┬──┴─┬─┴──┬┴───┴───┴───┴───┴───┴──┬┴───┼───┴┬────┬────┤ ┌───┼───┼───┐ ├───┴───┼───┤ E││   │             │
│ Ctrl│    │Alt │         teng          │ Alt│ Fn │    │Ctrl│ │ ← │ ↓ │ → │ │   0   │ . │←─┘│   │     teng    │
└─────┴────┴────┴───────────────────────┴────┴────┴────┴────┘ └───┴───┴───┘ └───────┴───┴───┘   └─────────────┘

yolov5_ncnn's People

Contributors

cmdbug avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

yolov5_ncnn's Issues

custom yolov4-tiny can inference but no output on yolov5-ncnn-android

大神好,我想用自己訓練的yolov4-tiny 在 android-ncnn 檢測目標
以下是我的yolov4-tiny-opt.param
螢幕快照 2021-01-22 下午7 16 01

這是我的模型訓練過程
我用WongKinYiu的yolov4-csp訓練了六個類別的yolov4-tiny
以下是程式碼的網址
https://github.com/WongKinYiu/ScaledYOLOv4/tree/yolov4-csp
參考這個issue
WongKinYiu/ScaledYOLOv4#41
以及更改cfg檔(classes=6 & yolo層輸出的filter=33)
成功訓練出pytorch版本的yolov4-tiny (6-category)
並用ncnn中的darknet2ncnn與ncnnoptimize轉換成ncnn的模型與優化
使用您的android_YOLOV5_NCNN實現推論
但在執行下面這行
ex.extract("output", blob);
一直都沒有輸出結果,想請教大神我可能是哪裡出了問題

新人求教

请问直接下载本代码 进入安卓手机,解压安装就可以?

你好,在build的时候报以下错误。。。

Build command failed.
Error while executing process C:\Users\Administrator\AppData\Local\Android\Sdk\cmake\3.10.2.4988404\bin\ninja.exe with arguments {-C C:\Users\Administrator\Desktop\ncnn\YOLOv5_NCNN-master\android_YOLOV5_NCNN\app.cxx\cmake\debug\x86 yolov5}
ninja: Entering directory `C:\Users\Administrator\Desktop\ncnn\YOLOv5_NCNN-master\android_YOLOV5_NCNN\app.cxx\cmake\debug\x86'

ninja: error: 'C:/Users/Administrator/Desktop/ncnn/YOLOv5_NCNN-master/android_YOLOV5_NCNN/app/src/main/cpp/opencv/x86/libopencv_java4.so', needed by 'C:/Users/Administrator/Desktop/ncnn/YOLOv5_NCNN-master/android_YOLOV5_NCNN/app/build/intermediates/cmake/debug/obj/x86/libyolov5.so', missing and no known rule to make it

测试

您好,请问我在测试项目时会提示找不到libopencv_java4.so

自己从头到尾转换了一下yolov5s.pt到yolov5s.param和yolov5s.bin文件,在android studio中替换后没有检测结果,并且几秒钟后会退回到主界面,会是什原因呢?

2021-03-10 17:08:28.596 5661-5661/? I/com.wzt.yolov5: Not late-enabling -Xcheck:jni (already on)
2021-03-10 17:08:28.639 5661-5661/? I/com.wzt.yolov5: Unquickening 12 vdex files!
2021-03-10 17:08:28.643 5661-5661/? W/com.wzt.yolov5: Unexpected CPU variant for X86 using defaults: x86
2021-03-10 17:08:28.648 5661-5661/? I/ndk_translation: Initialized NDK translation (armv7l), version 0.2.2
2021-03-10 17:08:28.921 5661-5661/com.wzt.yolov5 D/ApplicationLoaders: Returning zygote-cached class loader: /system/framework/android.test.base.jar
2021-03-10 17:08:29.066 5661-5661/com.wzt.yolov5 D/NetworkSecurityConfig: No Network Security Config specified, using platform default
2021-03-10 17:08:29.066 5661-5661/com.wzt.yolov5 D/NetworkSecurityConfig: No Network Security Config specified, using platform default
2021-03-10 17:08:29.070 5661-5661/com.wzt.yolov5 I/MultiDex: VM with version 2.1.0 has multidex support
2021-03-10 17:08:29.070 5661-5661/com.wzt.yolov5 I/MultiDex: Installing application
2021-03-10 17:08:29.070 5661-5661/com.wzt.yolov5 I/MultiDex: VM has multidex support, MultiDex support library is disabled.
2021-03-10 17:08:29.071 5661-5661/com.wzt.yolov5 D/Camera2Initializer: CameraX initializing with Camera2 ...
2021-03-10 17:08:29.078 5661-5661/com.wzt.yolov5 I/CameraManagerGlobal: Connecting to camera service
2021-03-10 17:08:29.096 5661-5661/com.wzt.yolov5 D/CameraRepository: Added camera: 0
2021-03-10 17:08:29.109 5661-5697/com.wzt.yolov5 D/UseCaseAttachState: Active and online use case: [] for camera: 0
2021-03-10 17:08:29.110 5661-5661/com.wzt.yolov5 D/CameraRepository: Added camera: 1
2021-03-10 17:08:29.113 5661-5697/com.wzt.yolov5 D/UseCaseAttachState: Active and online use case: [] for camera: 1
2021-03-10 17:08:29.127 5661-5700/com.wzt.yolov5 D/libEGL: loaded /vendor/lib/egl/libEGL_emulation.so
2021-03-10 17:08:29.130 5661-5700/com.wzt.yolov5 D/libEGL: loaded /vendor/lib/egl/libGLESv1_CM_emulation.so
2021-03-10 17:08:29.133 5661-5700/com.wzt.yolov5 D/libEGL: loaded /vendor/lib/egl/libGLESv2_emulation.so
2021-03-10 17:08:29.202 5661-5661/com.wzt.yolov5 W/com.wzt.yolov5: Accessing hidden method Landroid/view/View;->computeFitSystemWindows(Landroid/graphics/Rect;Landroid/graphics/Rect;)Z (greylist, reflection, allowed)
2021-03-10 17:08:29.202 5661-5661/com.wzt.yolov5 W/com.wzt.yolov5: Accessing hidden method Landroid/view/ViewGroup;->makeOptionalFitsSystemWindows()V (greylist, reflection, allowed)
2021-03-10 17:08:29.365 5661-5698/com.wzt.yolov5 D/HostConnection: HostConnection::get() New Host Connection established 0xf1a179a0, tid 5698
2021-03-10 17:08:29.370 5661-5698/com.wzt.yolov5 D/HostConnection: HostComposition ext ANDROID_EMU_CHECKSUM_HELPER_v1 ANDROID_EMU_native_sync_v2 ANDROID_EMU_native_sync_v3 ANDROID_EMU_native_sync_v4 ANDROID_EMU_dma_v1 ANDROID_EMU_direct_mem ANDROID_EMU_host_composition_v1 ANDROID_EMU_host_composition_v2 ANDROID_EMU_vulkan ANDROID_EMU_deferred_vulkan_commands ANDROID_EMU_vulkan_null_optional_strings ANDROID_EMU_vulkan_create_resources_with_requirements ANDROID_EMU_YUV_Cache ANDROID_EMU_async_unmap_buffer ANDROID_EMU_vulkan_ignored_handles ANDROID_EMU_vulkan_free_memory_sync ANDROID_EMU_vulkan_shader_float16_int8 ANDROID_EMU_vulkan_async_queue_submit GL_OES_EGL_image_external_essl3 GL_OES_vertex_array_object GL_KHR_texture_compression_astc_ldr ANDROID_EMU_host_side_tracing ANDROID_EMU_async_frame_commands ANDROID_EMU_gles_max_version_3_0
2021-03-10 17:08:29.372 5661-5698/com.wzt.yolov5 W/OpenGLRenderer: Failed to choose config with EGL_SWAP_BEHAVIOR_PRESERVED, retrying without...
2021-03-10 17:08:29.386 5661-5698/com.wzt.yolov5 D/EGL_emulation: eglCreateContext: 0xf1a18260: maj 3 min 0 rcv 3
2021-03-10 17:08:29.404 5661-5698/com.wzt.yolov5 D/EGL_emulation: eglMakeCurrent: 0xf1a18260: ver 3 0 (tinfo 0xf1d32430) (first time)
2021-03-10 17:08:29.419 5661-5698/com.wzt.yolov5 I/Gralloc4: mapper 4.x is not supported
2021-03-10 17:08:29.446 5661-5698/com.wzt.yolov5 D/HostConnection: createUnique: call
2021-03-10 17:08:29.446 5661-5698/com.wzt.yolov5 D/HostConnection: HostConnection::get() New Host Connection established 0xf1a173f0, tid 5698
2021-03-10 17:08:29.446 5661-5698/com.wzt.yolov5 D/goldfish-address-space: allocate: Ask for block of size 0x100
2021-03-10 17:08:29.446 5661-5698/com.wzt.yolov5 D/goldfish-address-space: allocate: ioctl allocate returned offset 0x3fda03000 size 0x2000
2021-03-10 17:08:29.450 5661-5698/com.wzt.yolov5 D/HostConnection: HostComposition ext ANDROID_EMU_CHECKSUM_HELPER_v1 ANDROID_EMU_native_sync_v2 ANDROID_EMU_native_sync_v3 ANDROID_EMU_native_sync_v4 ANDROID_EMU_dma_v1 ANDROID_EMU_direct_mem ANDROID_EMU_host_composition_v1 ANDROID_EMU_host_composition_v2 ANDROID_EMU_vulkan ANDROID_EMU_deferred_vulkan_commands ANDROID_EMU_vulkan_null_optional_strings ANDROID_EMU_vulkan_create_resources_with_requirements ANDROID_EMU_YUV_Cache ANDROID_EMU_async_unmap_buffer ANDROID_EMU_vulkan_ignored_handles ANDROID_EMU_vulkan_free_memory_sync ANDROID_EMU_vulkan_shader_float16_int8 ANDROID_EMU_vulkan_async_queue_submit GL_OES_EGL_image_external_essl3 GL_OES_vertex_array_object GL_KHR_texture_compression_astc_ldr ANDROID_EMU_host_side_tracing ANDROID_EMU_async_frame_commands ANDROID_EMU_gles_max_version_3_0

ocr-ncnn报错。。。

android_YOLOV5_NCNN/app/src/main/cpp/ocr/RRLib.cpp:223: error: undefined reference to 'cv::_InputArray::_InputArray(cv::MatExpr const&)'

大佬,玩你部署的ocr-lite的时候,报这个错。。帮忙看下

安卓编译成功,在手机上运行打开图片报错,调用摄像头没有问题

你好,我在运行您的项目时 使用摄像头是没有问题的

当我使用 ChineseOCR 选择图片报了以下的错误,应该是图片没有正确 get

这里我去看240行,然后断点调试,出现了下面这个信息,权限问题??,由于我不熟悉安卓的开发,这里便不知改如何修改了,希望可以得到您@WZTENG 的帮助!!

环境: 真机小米8, 安卓10

我训练了yolov5自己的模型,类别是1,在转成ncnn替换了YOLOv5_NCNN-master\iOS_YOLOv5NCNN\YOLOv5NCNN\res\

我训练了yolov5自己的模型,类别是1,在转成ncnn替换了YOLOv5_NCNN-master\iOS_YOLOv5NCNN\YOLOv5NCNN\res\yolov5.bin 和yolov5.param之后执行demo报错
2021-01-18 11:00:43.932899+0800 NCNN Demo[9473:20535076] new YoloV5
layer Shape_246 not exists or registered
我用的是最新版本的yolov5,version3训练的,我想知道作者yolov5demo用的是那个版本的?还有一个就是我修改了训练类别,这个直接替换文件还需要做什么操作吗?

Hardocded SimplePose Mean and Norm values, can you explain them

Hello, I was wondering if anyone can give any information about the hard coded values of MEAN and NORM about Simple Pose model, for both person and pose detector, this values are:

  • Person Detector
 float norm[3] = {1 / 255.f, 1 / 255.f, 1 / 255.f};
 float mean[3] = {0, 0, 0};
  • Pose Detector
const float mean_vals[3] = {0.485f * 255.f, 0.456f * 255.f, 0.406f * 255.f};
const float norm_vals[3] = {1 / 0.229f / 255.f, 1 / 0.224f / 255.f, 1 / 0.225f / 255.f};

Thank you!

Why need convert from RGB to BGR

Hello, i noticed that preprocess() in NanoDet.cpp, there is a line of code :
in = ncnn::Mat::from_android_bitmap_resize(env, image, ncnn::Mat::PIXEL_RGBA2BGR, input_size, input_size);
I want to know why we need to convert RGB to BGR, ncnn's default channel order is BGR ? Thanks in advance !

How to use a different model file (.pt)

We're trying to use Yolov4 and yolov5 but with a different model file. We have a .pt file.

Is it possible for us to replace the model file to test it with this project?

关于lambda表达式

作者没有使用lambda表达式吗?
请问提示替换为lambda表达式该如何解决?

怎么样去掉OPENCV啊?

按您的例子直接打开这个YOLOV5的自定义层的例子,一进去就闪退,看YoloV5CustomLayer.h 里面写了:
ncnn 与 opencv 库冲突,需要重新编译 ncnn 或去掉 opencv 。(该项目保留 opencv ,如果需要两者都支持请看下面说明)
请问怎么样去掉OPENCV啊?

yolov5.param问题

你好,我自己训练,通过官方的export导出onnx,通过onnxsim简化,有700多层,你的只有300多层,可以指点下吗?

How to only build the object detection part ?

The full apk is more than 200MB that is too big for my situation, so what should i do to only build the object detection part (i.e yolov5 yolov4-tiny) with minimal changes in the codes ? Thanks !

Android手机运行闪退

您好,作者,尝试过几台Android手机,运行就闪退了。分别是红米note4,和小米6,Android系统是6.0以上的。权限有手动打开。

yolov5s的onnx转ncnn模型的问题

大佬好,目前yolov5基于Release v3版本的模型文件从onnx转ncnn的时候文件只有17M,模型被截断了,ncnn加载模型文件的时候会失败(返回-1),请问这可能是什么原因呀?

关于yolov4-tiny

作者您好!我注意到您的代码中yolov4-tiny包含后处理过程,我现在想重新训练yolov4-tiny的权重,所以想请教一下您是选用的是哪个版本的yolov4-tiny(看您首页给的链接是u版的yolov3?)

有关环境的配置问题

这个项目运行环境是win10还是Linux?如果是在win10上,请问在win10上需要安装ncnn吗?

安装失败

在android studio AVD模拟器上可以运行,但是在mumu模拟器和真机上安装失败,把sdk和ndk版本降低就一堆错,请问有啥解决路径吗

关于yolov5-customLayer

请问up主可以上传一份关于yolov5-CustomLayer编译的ncnn库吗?我这里一直弄不好,非常感谢您!!

iOS demo运行时报错

你好,我在跑IOS demo的时候遇上了这个问题,想问一下这个问题是少了什么东西嘛
Screenshot 2021-01-10 at 03 51 24
我的ncnn.framework opencv2.framework openmp.framework都有了
Screenshot 2021-01-10 at 19 58 22

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.