Git Product home page Git Product logo

facetools's Introduction

FaceTools

功能:一键人脸预处理工具,适用于在人脸识别,人脸表情识别,人脸分析等基于人脸的工作中,归一化人脸数据使用

##具有: 1、人脸检测 2、人脸关键点检测 3、人脸对齐 这三个预处理操作

##使用方法:

由于是调用在windows下的.exe 二进制软件, 所以本工具仅限于在Windows下执行。

参照main.py中, 指定需要预处理的图像文件夹、检测到的人脸图像的保存文件夹、对齐后的图像人脸文件夹路径等系列参数,调用test()函数即可。

使用实例:

if __name__ == "__main__" :
    '''
    @param: 提供的参数:1,图像的文件名位置,2,需要保留的文件位置,3,图像的格式列表
    '''
    ImagePath=r'D:\Test\Val' #原始的图像路径
    savePathDetect=r'D:\Test\Val_detect'#保存中间检测到的图像的路径
    savePathAligned=r'D:\Test\Val_aligned'#对齐后的人脸图像的保存路径
    test(ImagePath,savePathDetect,savePathAligned,tag_recover=True,savesize=[128,128])

其中,tag_recover 参数在人脸图像中人脸大小相差比较大的时候使用,如果人脸图像大小大致已经是抠出来的并且大小已经相同,就没有必要在设置这个参数了。

常见问题:

1,无法生成result.bin ? 解决:检查路径名称上是否有空格。

欢迎提出改进意见。

facetools's People

Contributors

riweichen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

facetools's Issues

2个exe文件执行不了

windows 32位:

我下载了这些文件,并调整好 main 函数的内容:
image

其他文件没有修改下执行2个exe文件。发现执行不了,这是什么原因?

image

用来处理LFW人脸库的时候 老是提示下面的错误而终止 求解决~~

Done make file list. step(1/6)
Begin Face Detection task. step(2/6)
Image Number = 1
No.0
Done Face Detection task.step(2/6)
Begin Box file Clean and Replace. step(3/6)
Done Box file Clean and Replace. step(3/6)
Begin Face Point Detection. step(4/6)
Done Face Point Detection. step(4/6)
Begin write Points files. step(5/6)
1
5
Traceback (most recent call last):
File "main.py", line 145, in
test(ImagePath,PathDetect,PathAligned,CropedPath,tag_recover=True,savesize=[128,128])
File "main.py", line 115, in test
textutil.writePoint2File(replacelist,imagepointlist,points)
File "D:\cnn\FaceTools-master\FaceTools-master\textutil.py", line 88, in writePoint2File
fn=fid.readline().split()[0]# image filename
IndexError: list index out of range

How to deal with the rgb images?

When I use this tools to deal with the CASIA rgb images, always have the warning" ......\skimage\util\dtype.py:110 userwarning:possible precision loss when converting from float64 to unit8 " how to deal with the warning?

step3 has a problem.what should I do to solve it? change np.int32 to np.float??

Begin Box file Clean and Replace. step(3/6)
Traceback (most recent call last):
File "main.py", line 131, in
test(ImagePath,savePathDetect,savePathAligned,savePathCroped,tag_recover=True,savesize=[64,64])
File "main.py", line 61, in test
textutil.cleanbox(fileinput=bboxlist,detectlistfile=detectlist,misslistfile=misslist)
File "C:\Users\cml\Desktop\FaceTools-master\textutil.py", line 129, in cleanbox
newline=retain_max_face(line)
File "C:\Users\cml\Desktop\FaceTools-master\textutil.py", line 103, in retain_max_face
areas=np.empty((num_detect,),dtype=np.int32)#保留的是图像的面积
TypeError: 'float' object cannot be interpreted as an integer

time problem

hi, I use your tools, I don't know if you do this waste how long? almost beyond one day ,
as for me, CPU i5 ,RAM 8G, use webface for test
it waste too long to get alignment faces, so it really waste time ? how long you did process all faces?

ImportError: numpy.core.multiarray failed to import

您好,我在使用FaceTools工具对人脸数据库进行对齐处理时,遇到下面的问题:
ImportError: numpy.core.multiarray failed to import

Traceback (most recent call last):
File "D:\facealign\FaceTools-master\main.py", line 18, in
import aligment
File "D:\facealign\FaceTools-master\aligment.py", line 8, in
import cv2
ImportError: numpy.core.multiarray failed to import
请问该怎么解决?

problem:aligment

After the alignment of the picture has not changed,as with the original picture。。。

why?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.