当前位置:网站首页>Face_ Attendance statistics of recognition face recognition
Face_ Attendance statistics of recognition face recognition
2022-07-04 17:50:00 【Wu_ Candy】
The pre condition environment preparation is as follows :Pycharm+python3.6+sklearn+face_recognition+dlib
Step1:KNN Introduction to the algorithm
K Nearest neighbor (k-Nearest Neighbor,KNN) The core idea of classification algorithm is if a sample is in the feature space k The most similar ( That is, the closest in the feature space ) Most of the samples belong to a certain category , Then the sample also belongs to this category .KNN The algorithm can be used for multi classification ,KNN The algorithm can be used not only for classification , It can also be used for regression . By finding a sample of k The nearest neighbor , Assign the average value of the properties of these neighbors to the sample , As a predictor .
KNeighborsClassifier stay scikit-learn stay sklearn.neighbors In the bag .
KNeighborsClassifier It's easy to use , The three step :
1) establish KNeighborsClassifier object
2) call fit function
3) call predict Function to predict .
Step2: Look at the directory structure of the project as follows
Step3: Look at the training data
Step4: Look at the test data
Step5: Look at the attendance data calculated by the model
Open as shown in the following figure :
Step6: Two core py File parsing
KNN_Recognition_easy.py Statistics of attendance through the model py file .
KNN_Train_easy.py Model generation through training data py file . The code is as follows :
Program entrance :
call main()
Call down successively :
predict()
getvalueToKey()
strTotime()
prase_filename_date()
writeExcel()
边栏推荐
- [proteus simulation] printf debugging output example based on VSM serial port
- Flask 轻量web框架
- 超大规模数仓集群在大型商业银行的落地实践
- shell脚本的替换功能实现
- leetcode:421. The maximum XOR value of two numbers in the array
- 【Unity UGUI】ScrollRect 动态缩放格子大小,自动定位到中间的格子
- 一加10 Pro和iPhone 13怎么选?
- 上网成瘾改变大脑结构:语言功能受影响,让人话都说不利索
- 【Hot100】32. 最长有效括号
- Image retrieval
猜你喜欢
La 18e Conférence internationale de l'IET sur le transport d'électricité en courant alternatif et en courant continu (acdc2022) s'est tenue avec succès en ligne.
居家打工年入800多万,一共五份全职工作,他还有时间打游戏
为啥有些线上演唱会总是怪怪的?
Recast of recastnavigation
NFT liquidity market security issues occur frequently - Analysis of the black incident of NFT trading platform quixotic
Wuzhicms code audit
Using win10 scheduling task program to automatically run jar package at fixed time
解读数据安全治理能力评估框架2.0,第四批DSG评估征集中
整理混乱的头文件,我用include what you use
Zebras are recognized as dogs, and the reason for AI's mistakes is found by Stanford
随机推荐
[proteus simulation] printf debugging output example based on VSM serial port
RecastNavigation 之 Recast
The company needs to be monitored. How do ZABBIX and Prometheus choose? That's the right choice!
【Unity UGUI】ScrollRect 动态缩放格子大小,自动定位到中间的格子
【Hot100】31. 下一个排列
为啥有些线上演唱会总是怪怪的?
大规模服务异常日志检索
Cann operator: using iterators to efficiently realize tensor data cutting and blocking processing
curl 命令妙用
【测试开发】软件测试——基础篇
leetcode:421. The maximum XOR value of two numbers in the array
[unity ugui] scrollrect dynamically scales the grid size and automatically locates the middle grid
Oppo Xiaobu launched Obert, a large pre training model, and promoted to the top of kgclue
超标量处理器设计 姚永斌 第6章 指令解码 摘录
Is BigDecimal safe to calculate the amount? Look at these five pits~~
How to choose one plus 10 pro and iPhone 13?
新享科技发布小程序UniPro小优 满足客户移动办公场景
Master the use of auto analyze in data warehouse
Two methods of MD5 encryption
Win32 API access route encrypted web pages