GithubHelp home page GithubHelp logo

Comments (19)

TNTWEN avatar TNTWEN commented on August 15, 2024

What's your OpenVINO version?
And could you show me the command when you run object_detection_demo_yolov4_async.py?

from openvino-yolov4.

TNTWEN avatar TNTWEN commented on August 15, 2024

It seems that you use the wrong model file's path
-m .xml

from openvino-yolov4.

Viki-researcher avatar Viki-researcher commented on August 15, 2024

It seems that you use the wrong model file's path
-m .xml
First of all, I really appreciate your reply

my openvivo version is w_openvino_toolkit_p_2021.2.185.exe!
my run command is "python object_detection_demo_yolov4_async.py -i cam -m frozen_darknet_yolov4_model.xml -d CPU"

i describe my all operation first.
env:windows tf1.15
1.i run convert_weights_pb.py with my custom weight.
2.i run master brance openvino-master to run mo.py
my yolov4.json is:
[
{
"id": "TFYOLOV3",
"match_kind": "general",
"custom_attributes": {
"classes": 5,
"anchors": [15, 36, 30, 45, 19, 82, 33,106, 65, 81, 33,227, 27,515, 204, 82, 86,244],
"coords": 4,
"num": 9,
"masks":[[0, 1, 2], [3, 4, 5], [6, 7, 8]],
"entry_points": ["detector/yolo-v4/Reshape", "detector/yolo-v4/Reshape_4", "detector/yolo-v4/Reshape_8"]
}
}
]
3.finally,i run "python object_detection_demo_yolov4_async.py -i cam -m frozen_darknet_yolov4_model.xml -d CPU"
but get the that error information
which version should i change? Looking forward to your reply!

from openvino-yolov4.

TNTWEN avatar TNTWEN commented on August 15, 2024

First ,you should use this demo:https://github.com/TNTWEN/OpenVINO-YOLOV4/tree/master/pythondemo/2021.2

And according to the error information:
net = ie.read_network(args.model, os.path.splitext(args.model)[0] + ".bin")

It just fail to find frozen_darknet_yolov4_model.xml and frozen_darknet_yolov4_model.bin.Make sure you set true IRmodel path!

from openvino-yolov4.

Viki-researcher avatar Viki-researcher commented on August 15, 2024

First ,you should use this demo:https://github.com/TNTWEN/OpenVINO-YOLOV4/tree/master/pythondemo/2021.2

And according to the error information:
net = ie.read_network(args.model, os.path.splitext(args.model)[0] + ".bin")

It just fail to find frozen_darknet_yolov4_model.xml and frozen_darknet_yolov4_model.bin.Make sure you set true IRmodel path!

thanks~
the demo :https://github.com/TNTWEN/OpenVINO-YOLOV4/tree/master/pythondemo/2021.2 used ngraph module only in linux,so i must install 2020.4 openvino in windows,i will try again.

from openvino-yolov4.

TNTWEN avatar TNTWEN commented on August 15, 2024

??
I have tested :https://github.com/TNTWEN/OpenVINO-YOLOV4/tree/master/pythondemo/2021.2 on windows

Obviously!Windows supports ngraph
image

net = ie.read_network(args.model, os.path.splitext(args.model)[0] + ".bin") is just an error loading the model

And you could try C++ demo C:\Program Files (x86)\Intel\openvino_2021.2.185\inference_engine\demos\multi_channel\object_detection_demo_yolov3

from openvino-yolov4.

TNTWEN avatar TNTWEN commented on August 15, 2024

Use right IRmodel path!
image
image

from openvino-yolov4.

Viki-researcher avatar Viki-researcher commented on August 15, 2024

Use right IRmodel path!
image
image

thanks for your reply,according your method ,i seem to solved some problem! and get right result in show picture.
the first issue maybe use a bad xml and bin file! i generate xml and bin again by "C:\Program Files (x86)\Intel\openvino_2021.2.185\deployment_tools\model_optimizer/mo.py" rather than in the github openvino-master version:openvino-master\model-optimizer/mo.py".it can work now,hope it can help others.

but there have some other problem

1.can i use my virtual env?i run it in my virtual env ,but i don't get the output of my env python version, my env python version is python=3.6.2. although it can work...!
image
but if i don't activate my virtual ,it it will output python version
image
2.it too slow when i use the gpu:
python object_detection_demo_yolov3_async.py -i ./img/3.jpg -m frozen_darknet_yolov4_model.xml -d GPU
I waited for a long time before the result show, and it seem don't use the gpu,my device is 1660ti,cuda 10.0,cudnn 7.6.5
and when i use the -i cam command,it only show the first frame pisture,such as:
image
image

do you know want possible problem?
Thanks again for your reply!

from openvino-yolov4.

TNTWEN avatar TNTWEN commented on August 15, 2024

it only show the first frame pisture
https://github.com/TNTWEN/OpenVINO-YOLOV4/tree/master/pythondemo/2021.2
download it again. I have solved it 2 hours ago.

Openvino GPU is Intel's GPU ,not Nvidia GPU,like this:
image

GPU need FP16 IRmodel.
If you want to use yolov4 +intel GPU+FP16 Please use OpenVINO2020.4 . (Details:#10 POINT 11)
If you want to use yolov4-tiny/yolov4-tiny-3l+intel GPU+FP16 .Any OpenVINO version(after2020.4) is OK.

from openvino-yolov4.

TNTWEN avatar TNTWEN commented on August 15, 2024

For faster yolov4 ,you could try:https://github.com/TNTWEN/Pruned-OpenVINO-YOLO

Pruned yolov4:
The weight file is pruned from 245M to less than 1M
image

Runnning on I5 8250U CPU 11FPS:
image

Very awesome!!
Welcome to have a try!You can star this repos and it will continue to be updated

from openvino-yolov4.

Viki-researcher avatar Viki-researcher commented on August 15, 2024

For faster yolov4 ,you could try:https://github.com/TNTWEN/Pruned-OpenVINO-YOLO

Pruned yolov4:
The weight file is pruned from 245M to less than 1M
image

Runnning on I5 8250U CPU 11FPS:
image

Very awesome!!
Welcome to have a try!You can star this repos and it will continue to be updated

I have read it a few days ago~,i may be try it after i run object_detection_demo_yolov3_async.py in windows succeseful.
i'm try run object_detection_demo_yolov3_async.py in pycharm,but the ngraph module is occur error.
image
i have copy openvino python ngraph and openvino module into my own env site-packge.
image
image
i set these environment variables
image
what should i do to import ngraph in pycharm successful!thanks

from openvino-yolov4.

TNTWEN avatar TNTWEN commented on August 15, 2024

There is no need to do so at all.
Even in pycharm,you can run the program on the terminal.It is already enough.
I have developed many other applications based on openvino demo before.Terminal can completely meet my demand under Win and Ubuntu

from openvino-yolov4.

Viki-researcher avatar Viki-researcher commented on August 15, 2024

the -i cam parameter still seem to be some problem. when i close current show-img window, it was able detect next frame img.

from openvino-yolov4.

TNTWEN avatar TNTWEN commented on August 15, 2024

In the development process, we usually install multiple versions at the same time.We can flexibly switch between multiple versions in the terminal.Every update OpenVINO adds many new packages,So there is no need to change the environment that openvino has packaged.It's just a waste of time.
image

from openvino-yolov4.

TNTWEN avatar TNTWEN commented on August 15, 2024

the -i cam parameter still seem to be some problem. when i close current show-img window, it was able detect next frame img.

You never use opencv before?
This is how opencv realizes video display
You can't exit the program by clicking the close button
Python demo has already told you how to exit the program
image

from openvino-yolov4.

Viki-researcher avatar Viki-researcher commented on August 15, 2024

In the development process, we usually install multiple versions at the same time.We can flexibly switch between multiple versions in the terminal.Every update OpenVINO adds many new packages,So there is no need to change the environment that openvino has packaged.It's just a waste of time.
image

thank you, i get it!

from openvino-yolov4.

Viki-researcher avatar Viki-researcher commented on August 15, 2024

the -i cam parameter still seem to be some problem. when i close current show-img window, it was able detect next frame img.

You never use opencv before?
This is how opencv realizes video display
You can't exit the program by clicking the close button
Python demo has already told you how to exit the program
image

Sorry, maybe I didn't express myself clearly~ What I mean is that it detect next frame by press tab?rather than detect next img with cam video streaming?

from openvino-yolov4.

TNTWEN avatar TNTWEN commented on August 15, 2024

the -i cam parameter still seem to be some problem. when i close current show-img window, it was able detect next frame img.

You never use opencv before?
This is how opencv realizes video display
You can't exit the program by clicking the close button
Python demo has already told you how to exit the program
image

Sorry, maybe I didn't express myself clearly~ What I mean is that it detect next frame by press tab?rather than detect next img with cam video streaming?

You can simply understand it as the asynchronous mode of openvino video processing
While processing the previous frame, prepare for the next one. Instead of waiting for the previous frame to be processed completely before reading the next frame. This helps to reduce latency and improve FPS performance

from openvino-yolov4.

Viki-researcher avatar Viki-researcher commented on August 15, 2024

the -i cam parameter still seem to be some problem. when i close current show-img window, it was able detect next frame img.

You never use opencv before?
This is how opencv realizes video display
You can't exit the program by clicking the close button
Python demo has already told you how to exit the program
image

Sorry, maybe I didn't express myself clearly~ What I mean is that it detect next frame by press tab?rather than detect next img with cam video streaming?

You can simply understand it as the asynchronous mode of openvino video processing
While processing the previous frame, prepare for the next one. Instead of waiting for the previous frame to be processed completely before reading the next frame. This helps to reduce latency and improve FPS performance

ok,Thank you very much for your professional answer!

from openvino-yolov4.

Related Issues (20)

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.