allo- / virtual_webcam_background

Use a virtual webcam background and overlays with body-pix and v4l2loopback
GNU General Public License v3.0
306 stars 48 forks source link

virtual_webcam.py errors out immediately #45

Closed callegar closed 4 years ago

callegar commented 4 years ago

Hi, I am getting this:

./virtual_webcam.py 
2020-10-13 13:35:23.162215: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcudart.so.10.1'; dlerror: libcudart.so.10.1: cannot open shared object file: No such file or directory; LD_LIBRARY_PATH: /usr/local/lib:/home/callegar/lib:/home/callegar/lib32
2020-10-13 13:35:23.162238: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.
Reloading config.
2020-10-13 13:35:24.086735: W tensorflow/stream_executor/platform/default/dso_loader.cc:59] Could not load dynamic library 'libcuda.so.1'; dlerror: libcuda.so.1: cannot open shared object file: No such file or directory; LD_LIBRARY_PATH: /usr/local/lib:/home/callegar/lib:/home/callegar/lib32
2020-10-13 13:35:24.086756: W tensorflow/stream_executor/cuda/cuda_driver.cc:312] failed call to cuInit: UNKNOWN ERROR (303)
2020-10-13 13:35:24.086771: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (jakmandolino): /proc/driver/nvidia/version does not exist
Traceback (most recent call last):
  File "./virtual_webcam.py", line 101, in <module>
    fakewebcam = FakeWebcam(config.get("virtual_video_device"), width, height)
  File "/home/callegar/PythonEnvs/Py-Virtualcam/lib/python3.8/site-packages/pyfakewebcam/pyfakewebcam.py", line 54, in __init__
    fcntl.ioctl(self._video_device, _v4l2.VIDIOC_S_FMT, self._settings)
OSError: [Errno 22] Invalid argument

It is my understanding that the software should work even without CUDA or nvidia GPUs, and the first errors are innocuous. Is this correct? The last error, conversely is critical. Any idea where this could come from?

I have the real webcam set to video2, checked with webcamoid and the virtual one to a video device that seems free.

allo- commented 4 years ago

tensorflow should fall back to CPU mode (or you can explicitely install tensorflow-cpu). Your error seems to be that the virtual video device cannot be accessed.

callegar commented 4 years ago

Solved, sorry for the noise. I had the device that was evidently being locked by something. Restarting the desktop fixed the issue.

allo- commented 4 years ago

Good to hear it's working for you now.

I added a basic troubleshooting wiki page with the hints, which can be extended for other problems.