vipstone / faceai Goto Github PK
View Code? Open in Web Editor NEW一款入门级的人脸、视频、文字检测以及识别的项目.
License: MIT License
一款入门级的人脸、视频、文字检测以及识别的项目.
License: MIT License
Traceback (most recent call last):
File "face_recog.py", line 15, in
face_recognition.load_image_file(path + "/" + fn))[0])
IndexError: list index out of range
[ WARN:0] terminating async callback
请问这里是哪里出了问题吗?文件夹里面放了两张图片可以运行,但是增加图片之后报错,始终找不到问题,为什么list[0]错误呢?
谢谢你的项目分享,你能给我点帮助么?还是源码需要进行一点修改才能准确的检测到多张人脸
检测出68个特征点后,改变点的坐标,能不能反向生成新图?
C:\Users\Administrator>pip3 install face_recognition
Collecting face_recognition
Using cached https://files.pythonhosted.org/packages/3f/ed/ad9a28042f373d4633f
c8b49109b623597d6f193d3bbbef7780a5ee8eef2/face_recognition-1.2.3-py2.py3-none-an
y.whl
Collecting dlib>=19.7 (from face_recognition)
Using cached https://files.pythonhosted.org/packages/df/aa/6a9bb2a763107bb2606
d6ee1aa65fcd3b51375a9ef6436e9c9280b0dd63c/dlib-19.15.0.tar.gz
Requirement already satisfied: numpy in f:\program files\anaconda3\lib\site-pack
ages (from face_recognition) (1.14.3)
Requirement already satisfied: face-recognition-models>=0.3.0 in f:\program file
s\anaconda3\lib\site-packages (from face_recognition) (0.3.0)
Requirement already satisfied: Click>=6.0 in f:\program files\anaconda3\lib\site
-packages (from face_recognition) (6.6)
Requirement already satisfied: Pillow in f:\program files\anaconda3\lib\site-pac
kages (from face_recognition) (3.3.1)
Building wheels for collected packages: dlib
Running setup.py bdist_wheel for dlib ... error
Complete output from command "f:\program files\anaconda3\python.exe" -u -c "im
port setuptools, tokenize;file='C:\Users\ADMINI1\AppData\Local\Temp\p1\AppData\Local\Temp\pip-wheel-cdrpikq0 --p
ip-install-z6wr0c9k\dlib\setup.py';f=getattr(tokenize, 'open', open)(file)
;code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exe
c'))" bdist_wheel -d C:\Users\ADMINI
ython-tag cp35:
running bdist_wheel
running build
running build_py
package init file 'dlib_init_.py' not found (or not a regular file)
running build_ext
Traceback (most recent call last):
File "C:\Users\ADMINI~1\AppData\Local\Temp\pip-install-z6wr0c9k\dlib\setup.p
y", line 118, in get_cmake_version
out = subprocess.check_output(['cmake', '--version'])
File "f:\program files\anaconda3\lib\subprocess.py", line 626, in check_outp
ut
**kwargs).stdout
File "f:\program files\anaconda3\lib\subprocess.py", line 693, in run
with Popen(*popenargs, **kwargs) as process:
File "f:\program files\anaconda3\lib\subprocess.py", line 947, in init
restore_signals, start_new_session)
File "f:\program files\anaconda3\lib\subprocess.py", line 1224, in execute
child
startupinfo)
FileNotFoundError: [WinError 2] 系统找不到指定的文件。
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\ADMINI1\AppData\Local\Temp\pip-install-z6wr0c9k\dlib\setup.p1\AppData\Local\Temp\pip-install-z6wr0c9k\dlib\setup.p
y", line 257, in
'Topic :: Software Development',
File "f:\program files\anaconda3\lib\site-packages\setuptools_init_.py",
line 129, in setup
return distutils.core.setup(**attrs)
File "f:\program files\anaconda3\lib\distutils\core.py", line 148, in setup
dist.run_commands()
File "f:\program files\anaconda3\lib\distutils\dist.py", line 955, in run_co
mmands
self.run_command(cmd)
File "f:\program files\anaconda3\lib\distutils\dist.py", line 974, in run_co
mmand
cmd_obj.run()
File "f:\program files\anaconda3\lib\site-packages\wheel\bdist_wheel.py", li
ne 202, in run
self.run_command('build')
File "f:\program files\anaconda3\lib\distutils\cmd.py", line 313, in run_com
mand
self.distribution.run_command(command)
File "f:\program files\anaconda3\lib\distutils\dist.py", line 974, in run_co
mmand
cmd_obj.run()
File "f:\program files\anaconda3\lib\distutils\command\build.py", line 135,
in run
self.run_command(cmd_name)
File "f:\program files\anaconda3\lib\distutils\cmd.py", line 313, in run_com
mand
self.distribution.run_command(command)
File "f:\program files\anaconda3\lib\distutils\dist.py", line 974, in run_co
mmand
cmd_obj.run()
File "C:\Users\ADMINI
y", line 127, in run
cmake_version = self.get_cmake_version()
File "C:\Users\ADMINI~1\AppData\Local\Temp\pip-install-z6wr0c9k\dlib\setup.p
y", line 123, in get_cmake_version
"\n*******************************************************************\n")
RuntimeError:
CMake must be installed to build the following extensions: dlib
Failed building wheel for dlib
Running setup.py clean for dlib
Failed to build dlib
Installing collected packages: dlib, face-recognition
Running setup.py install for dlib ... error
Complete output from command "f:\program files\anaconda3\python.exe" -u -c "
import setuptools, tokenize;file='C:\Users\ADMINI1\AppData\Local\Temp1\AppData\Local\Temp\pip-record-3xa50wt
\pip-install-z6wr0c9k\dlib\setup.py';f=getattr(tokenize, 'open', open)(_file
_);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'e
xec'))" install --record C:\Users\ADMINI
q\install-record.txt --single-version-externally-managed --compile:
running install
running build
running build_py
package init file 'dlib_init_.py' not found (or not a regular file)
running build_ext
Traceback (most recent call last):
File "C:\Users\ADMINI~1\AppData\Local\Temp\pip-install-z6wr0c9k\dlib\setup
.py", line 118, in get_cmake_version
out = subprocess.check_output(['cmake', '--version'])
File "f:\program files\anaconda3\lib\subprocess.py", line 626, in check_ou
tput
**kwargs).stdout
File "f:\program files\anaconda3\lib\subprocess.py", line 693, in run
with Popen(*popenargs, **kwargs) as process:
File "f:\program files\anaconda3\lib\subprocess.py", line 947, in init
restore_signals, start_new_session)
File "f:\program files\anaconda3\lib\subprocess.py", line 1224, in _execut
e_child
startupinfo)
FileNotFoundError: [WinError 2] 系统找不到指定的文件。
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\ADMINI~1\AppData\Local\Temp\pip-install-z6wr0c9k\dlib\setup
.py", line 257, in
'Topic :: Software Development',
File "f:\program files\anaconda3\lib\site-packages\setuptools_init_.py"
, line 129, in setup
return distutils.core.setup(attrs)
File "f:\program files\anaconda3\lib\distutils\core.py", line 148, in setu
p
dist.run_commands()
File "f:\program files\anaconda3\lib\distutils\dist.py", line 955, in run_
commands
self.run_command(cmd)
File "f:\program files\anaconda3\lib\distutils\dist.py", line 974, in run_
command
cmd_obj.run()
File "f:\program files\anaconda3\lib\site-packages\setuptools\command\inst
all.py", line 61, in run
return orig.install.run(self)
File "f:\program files\anaconda3\lib\distutils\command\install.py", line 5
39, in run
self.run_command('build')
File "f:\program files\anaconda3\lib\distutils\cmd.py", line 313, in run_c
ommand
self.distribution.run_command(command)
File "f:\program files\anaconda3\lib\distutils\dist.py", line 974, in run_
command
cmd_obj.run()
File "f:\program files\anaconda3\lib\distutils\command\build.py", line 135
, in run
self.run_command(cmd_name)
File "f:\program files\anaconda3\lib\distutils\cmd.py", line 313, in run_c
ommand
self.distribution.run_command(command)
File "f:\program files\anaconda3\lib\distutils\dist.py", line 974, in run_
command
cmd_obj.run()
File "C:\Users\ADMINI1\AppData\Local\Temp\pip-install-z6wr0c9k\dlib\setup1\AppData\Local\Temp\pip-install-z6wr0c9k\dlib\setup
.py", line 127, in run
cmake_version = self.get_cmake_version()
File "C:\Users\ADMINI
.py", line 123, in get_cmake_version
"\n*****************************************************************\n
")
RuntimeError:
*******************************************************************
CMake must be installed to build the following extensions: dlib
*******************************************************************
----------------------------------------
Command ""f:\program files\anaconda3\python.exe" -u -c "import setuptools, token
ize;file='C:\Users\ADMINI1\AppData\Local\Temp\pip-install-z6wr0c9k\d1\AppData\Local\Temp\pip-record-3xa50wtq\install-record.txt --s
lib\setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace
('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" install --record
C:\Users\ADMINI
ingle-version-externally-managed --compile" failed with error code 1 in C:\Users
\ADMINI~1\AppData\Local\Temp\pip-install-z6wr0c9k\dlib\
C:\Users\Administrator>
Traceback (most recent call last):
File "E:\users\administrator\eclipse-workspace2\faceai-master\hjz\img2txt.py", line 6, in
text = pytesseract.image_to_string(Image.open(path), lang='chi_sim')
File "F:\Program Files\Anaconda3\lib\site-packages\pytesseract\pytesseract.py", line 294, in image_to_string
return run_and_get_output(*args)
File "F:\Program Files\Anaconda3\lib\site-packages\pytesseract\pytesseract.py", line 202, in run_and_get_output
run_tesseract(**kwargs)
File "F:\Program Files\Anaconda3\lib\site-packages\pytesseract\pytesseract.py", line 178, in run_tesseract
raise TesseractError(status_code, get_errors(error_string))
pytesseract.pytesseract.TesseractError: (1, 'Error opening data file F:\Tesseract-OCR\/tessdata/chi_sim.traineddata Please make sure the TESSDATA_PREFIX environment variable is set to your "tessdata" directory. Failed loading language 'chi_sim' Tesseract couldn't load any languages! Could not initialize tesseract.')
作者用的python开发工具是什么啊?
可能配置不同,Mac安装求指导
可以研读一下
安装numpy
pip install numpy
安装whl
pip install wheel
安装OpenCV
pip install opencv-python
和作者的代码复制下来的,为什么识别女生的图片总是显示男生
Congrats for this amazing project, but would be very useful if there is a version in english because this is the language of the world. Thanks
在用opencv采集图像的时候, 要判断人是正对着屏幕, 或者侧脸对着屏幕, 这个怎么判断呢, 希望是人脸越是正对着摄像头越好
大华的摄像头 rtsp 协议的
Traceback (most recent call last):
File "E:\users\administrator\eclipse-workspace2\faceai-master\faceai\detectionOpencv.py", line 21, in
gray, scaleFactor=1.2, minNeighbors=3, minSize=(32, 32))
cv2.error: OpenCV(3.4.3) D:\Build\OpenCV\opencv-3.4.3\modules\objdetect\src\cascadedetect.cpp:1698: error: (-215:Assertion failed) !empty() in function 'cv::CascadeClassifier::detectMultiScale'
如题。
代码是复制粘贴作者的,能识别,但是特别卡,不知道为啥
电脑配置是APU 2200G
内存 金士顿8*2
用的2200g自带的集显,
是因为显卡的缘故吗
蔡徐kun 的照片被识别成女的,怎么说?
最近在学pytorch的人脸检测,有实现迁移实现pytorch版的嘛
It might be useful to write the ReadME of the repo in English for ease of understanding.
It looks pretty useful.
我看到原始的repo除了这个模型还有simple cnn 0.66 和 xception,请问为什么最后选择这个模型呢?
性别识别大部分都是识别到女生
在原本的代码下运行会报错,参照表型识别将代码更改为:
for (x, y, w, h) in faces:
gray_face = gray[(y):(y + h), (x):(x + w)]
gray_face = cv2.resize(gray_face, (64, 64))
gray_face = gray_face / 255.0
gray_face = np.expand_dims(gray_face, 0)
gray_face = np.expand_dims(gray_face, -1)
gender_label_arg = np.argmax(gender_classifier.predict(gray_face))
gender = gender_labels[gender_label_arg]
cv2.rectangle(img, (x, y), (x + h, y + w), color, 2)
img = chineseText.cv2ImgAddText(img, gender, x + h, y, color, 30)
目前不太清楚性别识别大部分识别为女性是否跟代码更改有关联,望指教
tesseract4.0怎么训练手写字体
RuntimeError: Unsupported image type, must be 8bit gray or RGB image.
为什么会出现这个问题
如题,谢谢!
哪里可以下载这个呢?谢谢!
识别显示的标签只能是数字英文的,中文的话会显示成?????,请问该如何解决
face_recognition在windows上安装容易出错,况且在整个项目中使用到这个模块的部分也比较简单,建议去除该模块,自己写一个比较人脸相似度的方法来做识别。
'Filepath looks like a hdf5 file but h5py is not available.'
ImportError: Filepath looks like a hdf5 file but h5py is not available. filepath=G:\Python\Djangoface_recognitionmaster\faceRec\static\classifier\gender_models\simple_CNN.81-0.96.hdf5
请问大哥知道怎么弄一下嘛
Recognize faces in live video using your webcam - Faster Version (Requires OpenCV to be installed)
很慢,怎么解决?一卡一卡的 可以用gpu加速或者 运用多核cpu吗
你好,很感谢你的付出,让我对图像处理有了基础的认识,想问下作者什么时候能出关于训练的教程,谢谢
`
face = np.expand_dims(face, 0)
face = face / 255.0
gender_label_arg = np.argmax(gender_classifier.predict(face))
`
请问这几个维度的函数在性别识别中的作用是?为什么face/255.0?
初学者一枚,感谢各位指教
您好,我目前想做一些关于ROI的视频传输的系统,但是在实现上需要一些理论支持!
在读取视频流的时候,判读取的视频数据包是不是属于圈定出来的ROI区域,然后再做后续处理!不知道openCV是否有解决办法,或者其他工具是否支持!
具体的一个用途,举个例子就是:当在视频传输过程中,如果需要主动丢包,我会优先丢弃非ROI区域,但是在读取视频数据包的时候,我怎么知道这些数据包里哪一部分是指代ROI区域呢?
或者最简单的是,我人为圈定中心20X20的区域,我在读取数据包的时候如何知道该数据包是否是20*20的区域呢?
Python 3.6.5 (v3.6.5:f59c0932b4, Mar 28 2018, 16:07:46) [MSC v.1900 32 bit (Intel)] on win32
Type "copyright", "credits" or "license()" for more information.
==================== RESTART: D:\Python\Python36-32\1.py ====================
Erom .PIL import Imad
import pytesseract图
path = "img\text-img-png"国
text .= .pytesseract.image to_string (Image .op
"chi sim'7)国
Print (text)
pip install ChineseText貌似没有啊,大佬们给点提示吧
作者大大,图片上色是使用的什么模型呢?教程什么时候能出呢?
模型如何训练呢?方便加一个qq:1840658279 后续我们可以建一个群。
请问如何在嵌入式设备上使用?
处理器:ARM
编程环境:C语言
操作系统:linux或RT-thread交叉编译
谢谢!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.