当前位置:网站首页>MTCNN人脸检测
MTCNN人脸检测
2022-07-06 09:14:00 【imxlw00】
MTCNN可实现两个任务——人脸检测与人脸关键点检测。
MTCNN已经集成到了python的库中。
安装
注意:安装前需要确认以下依赖:
python >= 3.4
opencv >= 4.1
Keras>=2.0.0
pip install mtcnn

人脸检测
from mtcnn import MTCNN
import cv2
img=cv2.imread("../datas/face/ldh2.jpg")
img = cv2.cvtColor(img, cv2.COLOR_BGR2RGB)
detector = MTCNN()
face =detector.detect_faces(img)
print(face)
[
{‘box’: [162, 72, 226, 281],
‘confidence’: 0.9999822378158569,
‘keypoints’: {‘left_eye’: (236, 190), ‘right_eye’: (335, 179), ‘nose’: (296, 248), ‘mouth_left’: (254, 291), ‘mouth_right’: (331, 282)}}
]
效果图

边栏推荐
- [recommended by bloggers] background management system of SSM framework (with source code)
- Kept VRRP script, preemptive delay, VIP unicast details
- 解决安装Failed building wheel for pillow
- Pytorch基础
- Codeforces Round #771 (Div. 2)
- 01 project demand analysis (ordering system)
- Case analysis of data inconsistency caused by Pt OSC table change
- csdn-Markdown编辑器
- 学习问题1:127.0.0.1拒绝了我们的访问
- Codeforces Round #753 (Div. 3)
猜你喜欢

Use dapr to shorten software development cycle and improve production efficiency

Django运行报错:Error loading MySQLdb module解决方法

Unable to call numpy in pycharm, with an error modulenotfounderror: no module named 'numpy‘

Kept VRRP script, preemptive delay, VIP unicast details

Machine learning notes week02 convolutional neural network

Learn winpwn (3) -- sEH from scratch

When you open the browser, you will also open mango TV, Tiktok and other websites outside the home page

Neo4j installation tutorial

Classes in C #

Deoldify project problem - omp:error 15:initializing libiomp5md dll,but found libiomp5md. dll already initialized.
随机推荐
QT creator test
软件测试与质量学习笔记3--白盒测试
Summary of numpy installation problems
Why can't I use the @test annotation after introducing JUnit
[recommended by bloggers] asp Net WebService background data API JSON (with source code)
Request object and response object analysis
Install mysql5.5 and mysql8.0 under windows at the same time
MySQL master-slave replication, read-write separation
02 staff information management after the actual project
【博主推荐】C#MVC列表实现增删改查导入导出曲线功能(附源码)
[free setup] asp Net online course selection system design and Implementation (source code +lunwen)
Ansible practical Series II_ Getting started with Playbook
安装numpy问题总结
Remember the interview algorithm of a company: find the number of times a number appears in an ordered array
L2-004 这是二叉搜索树吗? (25 分)
L2-007 家庭房产 (25 分)
Introduction and use of automatic machine learning framework (flaml, H2O)
JDBC原理
Test objects involved in safety test
AcWing 242. A simple integer problem (tree array + difference)