howdy: Error when adding a face (since Ubuntu 20.04)
Since I upgraded to Ubuntu 20.04, Howdy does no longer work. I reinstalled Howdy (this worked), but when I try to add a face I get this error (after entering the name):
Traceback (most recent call last):
File "/usr/local/bin/howdy", line 95, in <module>
import cli.add
File "/usr/lib/security/howdy/cli/add.py", line 99, in <module>
video_capture = VideoCapture(config)
File "/usr/lib/security/howdy/recorders/video_capture.py", line 45, in __init__
self._create_reader()
File "/usr/lib/security/howdy/recorders/video_capture.py", line 115, in _create_reader
self.internal = cv2.VideoCapture(
AttributeError: module 'cv2' has no attribute 'VideoCapture'
Exception ignored in: <function VideoCapture.__del__ at 0x7f05e9543700>
Traceback (most recent call last):
File "/usr/lib/security/howdy/recorders/video_capture.py", line 55, in __del__
self.internal.release()
AttributeError: 'NoneType' object has no attribute 'release'
I double checked that I selected the right camera (the IR one, not the normal webcam) during the Howdy installation.
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 24 (2 by maintainers)
For newbies:
I checked which device was the IR camera using ffmpeg. Mine was /dev/video2.
ffmpeg -f v4l2 -list_formats all -i /dev/video2The command spits a lot of output, but the last line says “Greyscale”:[video4linux2,v4l2 @ 0x562d4bfa59c0] Raw : gray : 8-bit Greyscale : 340x340Next, I ran
sudo howdy configand changed the value of “device_path” to “/dev/video2”.After that, “
sudo howdy add” ran correctly. I tested with “sudo howdy test”. (Actually, on my system, I need “sudo QT_X11_NO_MITSHM=1 howdy test”.)If you care, I’ve got a Dell XPS 13 9370.
you can try
sudo howdy configthen changes,device_path = /dev/video0it works for me in ubuntu 18.04 LTSSimilar issue on fresh install of Pop!_OS 20.04 (ubuntu). Is this related or do I make a separate bug report?
I got it figured out, for anyone with the same issue, make sure the “video2” in howdy config is replaced with the correct one for you pc, mine was video0
I got fig
I suggest having the camera setup the way it was before (asked if it was the correct camera) but done when adding a face but only for the first time. I also suggest adding an argument for that as well.