APP下载

结合卷积神经网络与OpenCV的人脸表情识别

2021-04-13张悦欣付晓峰

电脑知识与技术 2021年5期
关键词:深度学习

张悦欣 付晓峰

摘要:针对实时人脸表情识别模型训练慢、识别速度慢的问题,提出一种OpenCV和卷积神经网络结合进行实时表情识别的方法。人脸表情是多个局部区域特征的集合,而卷积神经网络提取出的特征能更多地关注局部,因此采取卷积神经网络的方式进行模型的训练。所提网络在全连接层中加入了Dropout,能有效预防过拟合现象的发生,并且提升模型泛化能力。实验结果表明此模型的可行性,在fer2013数据集上的准确率达到71.6%。基于以上方法再结合OpenCV構建一个实时表情识别系统,系统实时识别表情的速度为0.4s。所构建的系统相比于现有的其他系统,具有训练速度较快、准确率较高、识别速度较快等优点。

关键词:OpenCV; 卷积神经网络; 表情识别; 情感分类; 深度学习

Abstract:Aiming at the problems of slow training and slow recognition speed of real-time facial expression recognition model, a method for real-time expression recognition by combining OpenCV and convolutional neural network is proposed. Facial expression is a collection of features of multiple local regions, and the features extracted by the convolutional neural network can pay more attention to the locality. Therefore, this paper adopts the method of convolutional neural network to train the model. The network in this paper adds Dropout to the fully connected layer, which can effectively prevent the occurrence of overfitting and improve the model generalization ability. The experimental results show the feasibility of this model, and the accuracy rate on the fer2013 data set reaches 71.6%. Based on the above method and then combined with OpenCV to construct the real-time expression recognition system in this paper, the system's real-time expression recognition speed is 0.4s. Compared with the existing system, the system in this paper has the advantages of faster training speed, higher accuracy and faster recognition speed.

Key words:OpenCV; convolutional neural network; facial expression recognition; emotion classification; deep learning

面部表情是人们用来表达自己内心情绪的方式之一,对比语言能更具象直观地表达人类的心情。随着人工智能技术和计算机技术的日益进步,人们日益向往智能化的人机交互方式[1]。如果计算机能认识和识别人类的情感,将能更好地为人类服务。因此人脸表情识别在机器人、心理学、医学、智能监控及3D合成动画[2]等方面都有很大的应用价值。

目前表情识别的应用方法有LBP、SVM[3]和深度学习[4]等。近几年来,深度学习逐渐走进越来越多人的视线,成了人们研究的热点,卷积神经网络[5]也成为其中较为热门的方法,并取得了越来越好的成绩,比如VGGNet[6]、CNN16等。但结合实时摄像进行表情识别的仍然不是很多,用时存在识别时间较长等问题。……

登录APP查看全文

猜你喜欢

深度学习
从合坐走向合学:浅议新学习模式的构建
面向大数据远程开放实验平台构建研究
基于自动智能分类器的图书馆乱架图书检测
搭建深度学习的三级阶梯
有体验的学习才是有意义的学习
电子商务中基于深度学习的虚假交易识别研究
利用网络技术促进学生深度学习的几大策略
MOOC与翻转课堂融合的深度学习场域建构
大数据技术在反恐怖主义中的应用展望
深度学习算法应用于岩石图像处理的可行性研究