在Ubuntu中实现人脸识别登录的完整步骤

 更新时间:2020年06月28日 08:32:58   作者:Codsir  
这篇文章主要给大家介绍了关于在Ubuntu中实现人脸识别登录的完整步骤,文中通过示例代码介绍的非常详细,对大家的学习或者工作具有一定的参考学习价值,需要的朋友们下面来一起学习学习吧

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

3、测试

打开一个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

4、屏幕锁屏后,enter进入输密码界面,程序就会识别出人,直接解锁。

5、其它命令

Usage:

howdy [-U user] [-y] command [argument]

Command Description
add Add a new face model for an user
clear Remove all face models for an user
config Open the config file in your default editor
disable Disable or enable howdy
list List all saved face models for an user
remove Remove a specific model for an user
snapshot Take a snapshot of your camera input
test Test the camera and recognition methods
version Print the current version number

总结

到此这篇关于在Ubuntu中实现人脸识别登录的文章就介绍到这了,更多相关Ubuntu人脸识别登录内容请搜索脚本之家以前的文章或继续浏览下面的相关文章希望大家以后多多支持脚本之家!

相关文章

  • Linux如何关闭远程ssh密码登录

    Linux如何关闭远程ssh密码登录

    这篇文章主要介绍了Linux如何关闭远程ssh密码登录问题,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,望不吝赐教
    2023-08-08
  • Linux中find命令的用法汇总

    Linux中find命令的用法汇总

    Linux下find命令在目录结构中搜索文件,并执行指定的操作。Linux下find命令提供了相当多的查找条件,功能很强大。由于find具有强大的功能,所以它的选项也很多,其中大部分选项都值得我们花时间来了解一下。下面我们就来简单汇总下其用法
    2017-03-03
  • Linux下环境变量配置方法小结(.bash_profile和.bashrc的区别)

    Linux下环境变量配置方法小结(.bash_profile和.bashrc的区别)

    这篇文章主要介绍了Linux下环境变量配置方法小结(.bash_profile和.bashrc的区别),本文给大家介绍的非常详细,对大家的学习或工作具有一定的参考借鉴价值,需要的朋友可以参考下
    2020-04-04
  • win2003下PHP使用preg_match_all导致apache崩溃问题的解决方法

    win2003下PHP使用preg_match_all导致apache崩溃问题的解决方法

    这篇文章主要介绍了win2003下PHP使用preg_match_all导致apache崩溃问题的解决方法,详细的分析了问题产生原因以及解决方案,需要的朋友可以参考下
    2014-07-07
  • LAMP服务器性能优化技巧之Linux主机优化

    LAMP服务器性能优化技巧之Linux主机优化

    LAMP服务器性能优化技巧之Linux主机优化:由于LAMP的发展迅速,如今LAMP已经成为Web服务器的标准。如何才能优化LAMP服务器的性能?
    2012-02-02
  • 在Linux环境下采用压缩包方式安装JDK 13的方法

    在Linux环境下采用压缩包方式安装JDK 13的方法

    JDK(Java Development Kit)是Sun公司(后被Oracle收购)推出的面向对象程序设计语言的开发工具包,拥有这个工具包之后我们就可以使用Java语言进行程序设计和开发。这篇文章主要介绍了在Linux环境下采用压缩包方式安装JDK 13,需要的朋友可以参考下
    2019-10-10
  • CentOs下手动升级node版本的方法

    CentOs下手动升级node版本的方法

    这篇文章主要介绍了CentOs下手动升级node版本的方法,非常不错,具有一定的参考借鉴价值,需要的朋友可以参考下
    2018-11-11
  • Ubuntu 18.04通过命令禁用/开启触控板

    Ubuntu 18.04通过命令禁用/开启触控板

    这篇文章主要介绍了Ubuntu 18.04通过命令禁用/开启触控板,本文给大家介绍的非常详细,具有一定的参考借鉴价值,需要的朋友可以参考下
    2019-11-11
  • 你可能会用到的16个Linux命令

    你可能会用到的16个Linux命令

    这篇文章主要跟大家分享了一些在日常你可能会用到的16个Linux命令,文中通过示例代码和图文介绍的非常详细,对大家具有一定的参考学习价值,需要的朋友们下面来一起看看吧。
    2017-04-04
  • Linux Centos7系统端口占用问题的解决方法

    Linux Centos7系统端口占用问题的解决方法

    这篇文章主要给大家介绍了关于Linux Centos7系统端口占用问题的解决方法,文中通过示例代码介绍的非常详细,对大家的学习或者工作具有一定的参考学习价值,需要的朋友们下面随着小编来一起学习学习吧。
    2018-01-01

最新评论