pjreddie / darknet

Convolutional Neural Networks
http://pjreddie.com/darknet/
Other
25.7k stars 21.33k forks source link

Tiny yolo on jetson tx2 #307

Open aprentis opened 6 years ago

aprentis commented 6 years ago

Hi everybody! I've trained yolo model for my own class of images. It works pretty good, but now I want to use this network on my nvidia jetson tx1 and TX2 .

So. Is it possible to use to use my weights file with tinyYolo model, which is much faster then traditional yolo model? Or should I train a new tiny model on my data to use it on jetson? Maybe I should use "small" model?

AlexeyAB commented 6 years ago

Hi, you should train a new tiny model.

xhuvom commented 6 years ago

the tiny-yolo.weights model (for COCO) provided on the website doesn't mention mAP. However, running ./darknet detector demo cfg/coco.data cfg/tiny-yolo.cfg tiny-yolo.weights detects nothing. But the tiny-voc model works fine with the mentioned mAP. I can't understand why is this!! Is it hard to detect 80 object classes with 15 layer network? @AlexeyAB

Fred-Erik commented 6 years ago

I think it's just because the weights file format has been changed, so you would have to learn a new model on COCO yourself.

lzane commented 6 years ago

@aprentis Did you try tiny yolo model on TX2? Could you please tell me how's the performance. I've train my own tiny yolo model with just two classes and only get 7 or 8 fps on my TX2 with Max-N mode. I wonder if I did something wrong?

Fred-Erik commented 6 years ago

@lzane I didn't try the demo mode you I can't tell you the FPS but when I use the test mode I get "Predicted in 0.042975 seconds" in Max-P mode, so that's about 20 FPS. But I have also forced my TX2 to not scale back when not in use using ~/jetson_clocks.sh, I noticed that makes quite a difference.

lzane commented 6 years ago

@Fred-Erik Thanks, I'll try to run ~/jetson_clocks.sh before testing.

lzane commented 6 years ago

I pull AlexeyAB/darknet and try demo mode with my TX2 in Max-N mode, and it reach 21FPS. Thank you very much.

On Dec 15, 2017, 12:26 AM +0800, Fred-Erik notifications@github.com, wrote:

@lzane I didn't try the demo mode you I can't tell you the FPS but when I use the test mode I get "Predicted in 0.042975 seconds" in Max-P mode, so that's about 20 FPS. But I have also forced my TX2 to not scale back when not in use using ~/jetson_clocks.sh, I noticed that makes quite a difference. — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

Fred-Erik commented 6 years ago

Okay! Have you also tried running jetson_clocks.sh and using Max-P mode? Do you get even higher FPS then?

lzane commented 6 years ago

@Fred-Erik No, But I don't think it will get higher FPS. The Max-N mode is more powerful than Max-P Model.

Look at the following table from http://www.jetsonhacks.com/2017/03/25/nvpmodel-nvidia-jetson-tx2-development-kit/

Mode Mode Name Denver 2 Frequency ARM A57 Frequency GPU Frequency
0 Max-N 2 2.0 GHz 4 2.0 GHz 1.30 Ghz
1 Max-Q 0   4 1.2 Ghz 0.85 Ghz
2 Max-P Core-All 2 1.4 GHz 4 1.4 GHz 1.12 Ghz
3 Max-P ARM 0   4 2.0 GHz 1.12 Ghz
4 Max-P Denver 2 2.0 GHz 0   1.12 Ghz
Fred-Erik commented 6 years ago

Ah I see! But when I compare between Max-N mode and after running jetson_clocks.sh, it does get about 10 times faster from 3 FPS to about 27 FPS. So I'm curious if AlexeyABs fork would perform even better.

lzane commented 6 years ago

Do you mean that you have faster FPS in Max-P mode than Max-N mode??? how can?

I have try AlexeyABs’ repo and reach about 24FPS with playing window on TX2 in Max-N mode.


Zane Lee 李泽帆

website: https://www.lzane.com github: https://www.github.com/lzane

On Dec 15, 2017, 9:14 PM +0800, Fred-Erik notifications@github.com, wrote:

Ah I see! But when I compare between Max-N mode and after running jetson_clocks.sh, it does get about 10 times faster from 3 FPS to about 27 FPS. So I'm curious if AlexeyABs fork would perform even better. — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

hahakid commented 6 years ago

only 5Hz for 1080P on Tx1