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

Camera demo has some issue with C920 nor ZED #8

Closed
Jiroh opened this issue Aug 31, 2021 · 3 comments
Closed

Camera demo has some issue with C920 nor ZED #8

Jiroh opened this issue Aug 31, 2021 · 3 comments

Comments

@Jiroh
Copy link

Jiroh commented Aug 31, 2021

Setup on Jetson Xavier AGX; Jetpack4.5.1, Pytorch==1.8.0, Torchvision==0.9.0, etc.
YOLOP works on demo.py by images and mp4 video.
"python tools/demo.py --source 0" has stop working and following all output with C920.
jetson@xavier-agx:~/YOLOP$ python3 tools/demo.py --source 0
['/home/jetson/YOLOP/tools', '/usr/lib/python36.zip', '/usr/lib/python3.6', '/usr/lib/python3.6/lib-dynload', '/home/jetson/.local/lib/python3.6/site-packages', '/home/jetson/.local/lib/python3.6/site-packages/torchvision-0.9.0-py3.6-linux-aarch64.egg', '/home/jetson/.local/lib/python3.6/site-packages/Pillow-8.3.1-py3.6-linux-aarch64.egg', '/home/jetson/.local/lib/python3.6/site-packages/scipy-1.4.1-py3.6-linux-aarch64.egg', '/usr/local/lib/python3.6/dist-packages', '/usr/lib/python3/dist-packages', '/usr/lib/python3.6/dist-packages', '/home/jetson/YOLOP']
=> creating runs/BddDataset/_2021-08-31-15-38
Using torch 1.8.0 CPU

[ WARN:0] global /home/nvidia/host/build_opencv/nv_opencv/modules/videoio/src/cap_gstreamer.cpp (933) open OpenCV | GStreamer warning: Cannot query video position: status=0, value=-1, duration=-1
1/1: 0... success (inf frames 2304x1536 at 2.00 FPS)

0%| | 0/1 [00:00<?, ?it/s]/home/jetson/.local/lib/python3.6/site-packages/torch/nn/functional.py:3455: UserWarning: Default upsampling behavior when mode=bilinear is changed to align_corners=False since 0.4.0. Please specify align_corners=True if the old behavior is desired. See the documentation of nn.Upsample for details.
"See the documentation of nn.Upsample for details.".format(mode)
0%| | 0/1 [00:05<?, ?it/s]
Traceback (most recent call last):
File "tools/demo.py", line 174, in
detect(cfg,opt)
File "tools/demo.py", line 127, in detect
img_det = show_seg_result(img_det, (da_seg_mask, ll_seg_mask), _, _, is_demo=True)
File "/home/jetson/YOLOP/lib/utils/plot.py", line 57, in show_seg_result
img[color_mask != 0] = img[color_mask != 0] * 0.5 + color_seg[color_mask != 0] * 0.5
IndexError: boolean index did not match indexed array along dimension 0; dimension is 1536 but corresponding boolean dimension is 1284

@olivia23333
Copy link
Collaborator

Could you give some details about the shape of color_mask, color_seg and img? Thank you!

@Jiroh
Copy link
Author

Jiroh commented Aug 31, 2021 via email

@Riser6
Copy link
Collaborator

Riser6 commented Sep 1, 2021

Thank you for the comment. There is no image from attached ZED camera nor Logicool C920 camera. C920 indicate blue light that camera try to get images. But software is shutdown with attached output. From: olivia23333 @.> Sent: Tuesday, August 31, 2021 5:37 PM To: hustvl/YOLOP @.> Cc: Jiroh @.>; Author @.> Subject: Re: [hustvl/YOLOP] Camera demo has some issue with C920 nor ZED (#8) Could you give some details about the shape of color_mask, color_seg and img? Thank you! - You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub <#8 (comment)> , or unsubscribe <https://github.com/notifications/unsubscribe-auth/AASGMTVQUJ4VD5PNXQ6XF4TT7 SID3ANCNFSM5DDOL5UA> . Triage notifications on the go with GitHub Mobile for iOS <https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&m t=8&pt=524675> or Android <https://play.google.com/store/apps/details?id=com.github.android&referrer=u tm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub> . <https://github.com/notifications/beacon/AASGMTTZMZWEJPT6GTRAUDDT7SID3A5CNFS M5DDOL5UKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOGYXJ7JI .gif>
Sorry for that! Maybe you can test demo with the built-in camera in your computer. Actually, we don't use zed camera for demo test, which require extra interface code. Maybe the same for C920 camera.

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

3 participants