在Ubuntu上实现人脸识别登录

摘要:
请输入“设备_路径”配置值。异常ignoredin:$sudoapt getinstallv4l utils#查看相机路径$v4l2 ctl--列出设备USB2.0相机:
  1. 安装Howdy: howdy项目地址

    sudo add-apt-repository ppa:boltgolt/howdy
    sudo apt update
    sudo apt install howdy
    
  2. 添加自己的face

    sudo howdy add
    

    报错:

    Enter a label for this new model [Initial model] (max 24 characters): tiger
    Camera path is not configured correctly, please edit the 'device_path' config value.
    Exception ignored in: <bound method VideoCapture.__del__ of <recorders.video_capture.VideoCapture object at 0x7f6bc5be02b0>>
    Traceback (most recent call last):
      File "/lib/security/howdy/recorders/video_capture.py", line 55, in __del__
        self.internal.release()
    AttributeError: 'VideoCapture' object has no attribute 'internal'
    
    

    解决方案:

    $ sudo apt-get install v4l-utils
    # 查看摄像头路径
    $ v4l2-ctl --list-devices
    USB 2.0 Camera: USB Camera (usb-0000:03:00.0-14):
    	/dev/video0
    $ sudo howdy config
    # 接下来更改config中的device_path = /dev/video0
    
    
    
    $ sudo howdy add
    Adding face model for the user tiger
    Enter a label for this new model [Initial model] (max 24 characters): tiger
    
    Please look straight into the camera
    Scan complete
    
    Added a new model to tiger
    
    1. 测试

      打开一个terminal

    $ sudo -i
    Identified face as tiger
    
    $ sudo howdy test
    
    Opening a window with a test feed
    
    Press ctrl+C in this terminal to quit
    Click on the image to enable or disable slow mode
    
    
    Closing window
    
    
    1. 屏幕锁屏后,enter进入输密码界面,程序就会识别出人,直接解锁

    2. 其它命令

      Usage:

      howdy [-U user] [-y] command [argument]
      
      CommandDescription
      addAdd a new face model for an user
      clearRemove all face models for an user
      configOpen the config file in your default editor
      disableDisable or enable howdy
      listList all saved face models for an user
      removeRemove a specific model for an user
      snapshotTake a snapshot of your camera input
      testTest the camera and recognition methods
      versionPrint the current version number

免责声明:文章转载自《在Ubuntu上实现人脸识别登录》仅用于学习参考。如对内容有疑问,请及时联系本站处理。

上篇Sublime Text最舒服的主题mybatis3 @SelectProvider下篇

宿迁高防,2C2G15M,22元/月;香港BGP,2C5G5M,25元/月 雨云优惠码:MjYwNzM=

相关文章

马走日字--回溯法

   马走日字问题,在n*m的棋盘中,马只能走"日"字。马从位置(x,y)出发,把棋盘的每一格都走一次且只走一次。找出所有路径。    这个问题可以用回溯法解,每一步都有八种可能的走法,设马当前在(x,y)点,则它的可能走到:   (x+1,x+2),(x+1,x-2),(x-1,x+2),(x-1,x-2),(x+2,x+1),(x+2,x-1),(x-...

Android平台Overlay机制

Android overlay 机制允许在不修改packages中apk的情况下,来自定义 framework和package中的资源文件,实现资源的定制。来达到显示不同的UI得目的(如MIUI)。 以下几类能够通过该机制定义: (1),Configurations (string, bool, bool-array) (2),Localization...

CCF-201512-3-画图

问题描述 试题编号: 201512-3 试题名称: 画图 时间限制: 1.0s 内存限制: 256.0MB 问题描述: 问题描述   用 ASCII 字符来画图是一件有趣的事情,并形成了一门被称为 ASCII Art 的艺术。例如,下图是用 ASCII 字符画出来的 CSPRO 字样。   ..____.___...

5.多项式回归与模型泛化

(一)什么是多项式回归 还记得线性回归法吗?线性回归法有一个很大的局限性,那就是需要数据是有一定的线性关系的,但是现实中的很多数据是没有线性关系的。多项式就是用来解决这个问题的,可以处理非线性数据 在线性回归中,我们是假设数据具有线性关系的,因此我们在简单线性回归中,将直线的方向设置为y=ax+b的形式,那么我们求出a和b即可。 而对于有些数据,我们虽...

HTML5 创建热点图

通过HTML5 canvas画布创建简单的热点图,当鼠标划过时产生热点,停留时间越长,热点亮度越高。 下面是HTML部分: <!DOCTYPE html> <html> <head></head> <style type="text/css"> #heatmap { b...

投影变换 到 uv坐标 xy/w 齐次坐标

float3 vScreenPos = In.ClipPos.xyz; vScreenPos /= In.ClipPos.w; vScreenPos.xy += 1.f; vScreenPos.xy *= 0.5f; vScreenPos.y = 1.f - vScreenPos.y; 这个是shader里从vertex最后那个pos 里取 uv的算法 p...