Skip to content
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

Problem with ZED and YOLO3 on Jetson TX2 #949

Open
alessand01 opened this issue Jul 6, 2018 · 8 comments
Open

Problem with ZED and YOLO3 on Jetson TX2 #949

alessand01 opened this issue Jul 6, 2018 · 8 comments

Comments

@alessand01
Copy link

Hi,
I'm having some problems in processing a stream from a ZED camera with yolo3 (darknet) on a TX2.
I have done lots of tests and at the moment I'am trying to detect objects in an image loaded from the filesystem: the network can't find any objects if the ZED is opened (no need to call the grab function to produce this malfunctioning). Everything works well if I do not open the ZED.

Loading yolo3-tiny everything works well also with the ZED 'open'.

Any suggestion?
Thanks!

@alessand01
Copy link
Author

Hi,
I have rebuilt darknet without CUDNN (using GPU, OPENCV and OPENMP) and now it works. Is it possible that the use of CUDNN causes problems with ZED SDK?

The stereolabs support said that could be necessary to share with the ZED SDK the CUDA context of the application. Is it possible?

Thanks!

@erwincoumans
Copy link

erwincoumans commented Aug 19, 2018

I can into the same issue, running yolo v3 on TX2 hangs with ZED camera.
It seems to work well using yolov3-tiny weights/cfg, not with the regular weights.

@vidda13
Copy link

vidda13 commented Aug 29, 2018

Hi. I am facing the same issue now too. Did anyone get yolov3 running ?

@nesnes
Copy link

nesnes commented Sep 5, 2018

If it's a CUDA context issue, using the same context in yolo and the ZED SDK should solve the issue.
I'm don't know about yolo, but the ZED SDK offers the two possibilities:

Someone had a similar issue in python, and his solution was to swap the current context depending on the function to call: here

This guy seems to got it working recently, it might worth letting a comment to check what he used. Notice that he uses a laptop, is this a Jetson-specific issue?https://www.youtube.com/watch?v=EgaUq_dWclQ

@adujardin
Copy link

Hi,
I found a similar issue (even on desktop), the program was running but no objects were found if I opened the ZED, and working fine otherwise. A solution that seems to work is to call cuda_set_device(0/*gpu_index*/); after the ZED is opened.
Like :

  1. Open the ZED
  2. Call cuda_set_device
  3. Init and run the network

It may indeed be a context issue, but I still don't know exactly what's happening.

However, the difference between yolov3-tiny and regular yolov3 might come from the memory, it may be too much for the TX2.

@yuye1992
Copy link

Hi,
I want to use yolo3 on tx2, but when I load the yolo3 model, the program was killed when it is only loaded to the 102 layer. Is it insufficient memory?

@shuxiao9058
Copy link

Hi,
I want to use yolo3 on tx2, but when I load the yolo3 model, the program was killed when it is only loaded to the 102 layer. Is it insufficient memory?

Do you fixed the error?

@adujardin
Copy link

@yuye1992 @shuxiao9058 For the memory usage issue, you should make sure that the config file is correct, specifically in yolo3.cfg :

# Testing
# batch=1
# subdivisions=1
# Training
batch=64
subdivisions=16

It should be

# Testing
batch=1
subdivisions=1
# Training
#batch=64
#subdivisions=16

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants