problem with opencvstream

March 14, 2023, 03:54

zerefslayer

Hi I using a raspberrypi 4 b where I need to stream video from picam and the video will stream on the specific server that I create but when I run the coding it always show this error and I already stuck right now here the error message : Warning! No module named 'sounddevice' Warning! No module named 'tensorflow' Traceback (most recent call last): File "/home/spartanpi/Desktop/spartan/opencvstream.py", line 2, in <module> import pyshine as ps # pip3 install pyshine==0.0.9 apa File "/home/spartanpi/.local/lib/python3.9/site-packages/pyshine/__init__.py", line 8, in <module> from .convenience import putBText File "/home/spartanpi/.local/lib/python3.9/site-packages/pyshine/convenience.py", line 42, in <module> from socketserver import ThreadingMixIn File "/home/spartanpi/Desktop/spartan/socketserver.py", line 7, in <module> server_socket.bind((LOCALHOST,port)) OSError: [Errno 98] Address already in use

zerefslayer

if you want to see my coding here is it :

robaku

Hi! I was struggling with similar problem but with libcamera. Main goal was to get lowest possible latency and working opencv in background. I decided to use tcp output (stream) -> multiplexer server -> android client. Final latency was around 300ms from Raspberry pi to Android phone. I dont have open source solution for multiplexer server yet, but i can send you a rady to use template with integrated libcamera and openCV. Its working pretty good like i sad. Here is a link to github: https://github.com/modelingevolution/libcamera-apps-cv and here to tutorial: https://www.modelingevolution.com/libcamera-apps-cv-tutorial

robaku

Enjoy! 🙂