I will try it tonight. One more question, I am running Ricoh on private wifi. When I start streaming all my programs connected to that network start responding very slow. The current resolution is 2k, I wanted to try different resolutions what are the parameters?
Iāve been trying to implement YOLO in realtime webcam with a Theta Z1 on a computer without access to CUDA.
For now I got it to compile and running but the frame rate is absolutely dead. Something like 0.07 fpsā¦
I think Iām not using my GPU because this also happens when Iām analyzing previously downloaded files so there is also room for improvement there. However, and the reason why Iām here, is because Iāve also noticed that although gst_viewer is very fast, when I use v4l2loopback and OpenCV it slows it down immensely.
So I find this discussion here about trying to use a plugin to use gstreamer directly and I tried it.
This is what I did:
I downloaded nickels plugin, and compiled it.
I copied the gstthetauvc.so plugin file to my directory
I ran the test and I got the following
Factory Details:
Rank none (0)
Long-name Theta UVC video source
Klass Generic
Description Reads live video from THETA S/V/Z1
Author Koji Takeo nickel110@icloud.com
And finally I tried to run my program to see if I noticed any changes. Normally I would have to start and assign loopback but I didnāt this time. This is what I got:
[ WARN:0] global /home/husarion/opencv_build/opencv/modules/videoio/src/cap_gstreamer.cpp (2056) handleMessage OpenCV | GStreamer warning: Embedded video playback halted; module v4l2src0 reported: Internal data stream error.
[ WARN:0] global /home/husarion/opencv_build/opencv/modules/videoio/src/cap_gstreamer.cpp (1034) open OpenCV | GStreamer warning: unable to start pipeline
[ WARN:0] global /home/husarion/opencv_build/opencv/modules/videoio/src/cap_gstreamer.cpp (597) isPipelinePlaying OpenCV | GStreamer warning: GStreamer: pipeline have not been created
[ WARN:0] global /home/husarion/opencv_build/opencv/modules/videoio/src/cap_v4l.cpp (890) open VIDEOIO(V4L2:/dev/video0): canāt open camera by index
Floating point exception (core dumped)
Do you know if I missed any step? Iām unsure where I should change VideoCapture pipeline as shown by Craig. So I think atleast that is missing
My biggest problem right now is that I donāt know what to do next. Where do I put that thetauvcsrc ! decodebin ! autovideoconvert ! video/x-raw,format=BGRx ! queue ! videoconvert ! video/x-raw,format=BGR ! queue ! appsink
Iām a beginner to all this ā¦ My instinct was to check the python scripts for the detections themselves. For example I have one that detects faces and it has a part dedicated to capturing the video with the following using opencv: #To capture video from webcam.
cap = cv2.VideoCapture(0)
I am having the same issue as the original post of this thread with my Jetston NX + Theta Z1
I have a Jetson NX fresh install Jetson NX Developer Kit SD Card Image w/ Jetpack 4.5.1 (ubuntu 18.04)
when i connect Z1 to Jetson and power on (photo mode)
ubuntu@jetson-nx1:~/libuvc-theta-sample/gst$ lsusb | grep -i ricoh
Bus 001 Device 007: ID 05ca:036d Ricoh Co., Ltd
when i put into live mode (see the word live under the camera icon)
ubuntu@jetson-nx1:~/libuvc-theta-sample/gst$ lsusb | grep -i ricoh
Bus 001 Device 008: ID 05ca:2715 Ricoh Co., Ltd
ubuntu@jetson-nx1:~/libuvc-theta-sample/gst$ cd ~/v4l2loopback
ubuntu@jetson-nx1:~/v4l2loopback$ lsmod | grep loopback
ubuntu@jetson-nx1:~/v4l2loopback$ sudo depmod -a
[sudo] password for ubuntu:
ubuntu@jetson-nx1:~/v4l2loopback$ sudo modprobe v4l2loopback
ubuntu@jetson-nx1:~/v4l2loopback$ lsmod | grep loopback
v4l2loopback 42831 0
ubuntu@jetson-nx1:~/v4l2loopback$ ls /dev/video*
/dev/video0
ubuntu@jetson-nx1:~/v4l2loopback$ v4l2-ctl --list-devices --list-formats
Dummy video device (0x0000) (platform:v4l2loopback-000):
/dev/video0
ioctl: VIDIOC_ENUM_FMT
ubuntu@jetson-nx1:~/v4l2loopback$ cd -
/home/ubuntu/libuvc-theta-sample/gst
ubuntu@jetson-nx1:~/libuvc-theta-sample/gst$
ubuntu@jetson-nx1:~/libuvc-theta-sample/gst$ ./gst_viewer -l
No : Product : Serial
0 : RICOH THETA Z1 : 14xxxxxxxxx
ubuntu@jetson-nx1:~/libuvc-theta-sample/gst$ ./gst_viewer
Can't open THETA
ubuntu@jetson-nx1:~/libuvc-theta-sample/gst$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.5 LTS
Release: 18.04
Codename: bionic
ubuntu@jetson-nx1:~/libuvc-theta-sample/gst$ gst-inspect-1.0 --gst-version
GStreamer Core Library version 1.14.5
Iām at a loss of what iām missing. Iāve gone through this thread trying to find what nugget i might have missed and not finding anything similar to my issue
Thank you Craig,
Yes, i tried multiple options video0, video1, and even video7 (after doing modprobe v4l2loopback video_nr=7 just for grins). i did a āmake cleanā, āvi the .c fileā and rebuild with āmakeā . The fact that i dont see theta info in the printouts has me wondering if the driver is correctly seeing the camera.
ubuntu@jetson-nx1:~$ v4l2-ctl --list-devices --list-formats
Dummy video device (0x0000) (platform:v4l2loopback-000):
/dev/video0
ioctl: VIDIOC_ENUM_FMT
ubuntu@jetson-nx1:~$ v4l2-ctl --list-formats-ext
ioctl: VIDIOC_ENUM_FMT
ubuntu@jetson-nx1:~$ v4l2-ctl -d 0 -D
Driver Info (not using libv4l2):
Driver name : v4l2 loopback
Card type : Dummy video device (0x0000)
Bus info : platform:v4l2loopback-000
Driver version: 4.9.201
Capabilities : 0x85208003
Video Capture
Video Output
Video Memory-to-Memory
Read/Write
Streaming
Extended Pix Format
Device Capabilities
Device Caps : 0x05208003
Video Capture
Video Output
Video Memory-to-Memory
Read/Write
Streaming
Extended Pix Format
ubuntu@jetson-nx1:~$
Focus on gst_viewer first without v4l2loopback In the example above, do you have it set to /dev/video0 in the c code?
There are several other people on this thread that have it running on the Jetson Xavier NX with the same OS.
When you run gst_viewer, the camera ID needs to be 05ca:2715.
Can you run lsusb |grep -i ricoh immediately before running ./gst_viewer. detach all other USB cameras from the Jetson and just use /dev/video0 for now.
Yup, i went through that already. I have tested 3 different USB/USB-C cables
i tested the cable to my mac and performed the firmware upgrade to v2.0 a couple days ago
I installed the live-streaming app/drivers on my windows10 laptop.
When i goto Media ā Open ā Capture Device (popup comes up) ā Video Device Name pull down āRICOH THETA Z1ā. I click Play and get a popup error āThe capture device RICOH THETA Z1 does not support the required parametersā, but iām able to hear sound.
However, if you have it working on the Mac, you donāt need to get it working on Windows. That was just to see whether the Z1 could stream to any device.
I donāt have a Xavier NX, so I canāt precisely replicate your test. At the playlist below, I tested it with Jetson Nano.
My original tests were on JetPack 4.4 (Ubuntu 18.04), Jetson Nano B01. I used a microSD card. I think it only makes a difference if you save the frames to local storage. To just run the camera, the microSD card seems fine.
Thereās no open issues on the GitHub repo, so I feel we may be able to solve this one eventually. However, itās not obvious what the solution is.
I can try to install JetPack 4.5.1 on the Nano, but it may take me several days as I need to reconfigure my office. I moved the monitor, desk, all the gear I was using for the Nano into a closet when relatives came to visit. I was planning to take set up the Nano again anyway.
Just so we have a reference, is this is the device you are using with JetPack 4.5.1?
Maybe someone else on the forum can spot the problem. There are several people that are using the Jetson Xavier, though I think most of the tests were done with JetPack 4.4. That Xavier is a really cool device. So much power in a small package.
to clarify, i never tested the video streaming from the mac, only coping images and upgrade the firmware. will test it again with OBS, but usually VLC will play anything. Just tested on a different Win10 laptop and same issue, no video
i loaded on a different win10 laptop with OBS and i only see the āRICOH THETA Z1ā listed for the device options. Within your video you state you need to use the 4K optionā¦I dont have that option. Could my Z1 be faulty?
I have a Xavier as well and my ultimate device i plan to integrate on my quadruped robot, but wanted to get this working on this NX first.
On Windows, you need to use a software device driver. You need to install the Windows device from the web site listed. Download | RICOH THETA
I suggest you verify that the Z1 can stream to either a Mac or windows 10 machine. If it cannot stream, suggest you call the official RICOH customer support and consider a replacement, hopefully under warranty. Contact | RICOH THETA
Can you take a picture or short video (with a mobile phone or web cam) of the Jetson you are using plugged into the THETA camera in live mode? If itās a video, you may need to put the file on Google Drive or some other storage and put the link here.
The camera is widely used on quadruped robots for prototyping or small-volume robots.
Thanks so much for your infomation.
I have a jetson nano board and I want to push theta z1 stream from the board to a url,
so in gst_viewer.c, I changed ādecodebin ! device=/dev/video0 sync=falseā to ānv3dsink device=/dev/video0 sync=falseā and run ā./gst_loopbackā, it works fine!
What version of JetPack are you running on the Nano? Someone else is having a problem with getting the camera recognized on JetPack 4.5.1 on Jetson NX.
Verified streaming to YouTube with ffmpeg. Should work with other cloud-based services.
I have been trying to live stream from a Theta V on a Jetson Nano. I have followed your guide and I have made ./gst_viewer work. But When I try ./gst_loopvback, the terminal output āError: Internal data stream error.ā
I have installed v4l2loop and the kernel module has been loaded.