Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does your python file named "openface-real-time" uses single image for each person? #11

Closed
HananAhmadHunain opened this issue Nov 20, 2019 · 4 comments

Comments

@HananAhmadHunain
Copy link

HananAhmadHunain commented Nov 20, 2019

I am not an expert but from the following code what i have concluded is that you can only use 1 image per employee.
As you cannot put multiple images of same person under same name.
I am trying to built a facial recognition system and i can train the person before hand with 50 images.
Kindly tell me about this so i can change code according to my need.

`
#put your employee pictures in this path as name_of_employee.jpg
employee_pictures = "database/"

employees = dict()

for file in listdir(employee_pictures):
employee, extension = file.split(".")
img = preprocess_image('database/%s.jpg' % (employee))
representation = model.predict(img)[0,:]

employees[employee] = representation

print("employee representations retrieved successfully")
`

@serengil
Copy link
Owner

This is one shot learning example and this is not an issue. All face recognition applications handles this a one shot learning. Otherwise, adding a new person requires to change your model.

@DinaIbrahim132
Copy link

hi , thanks alot for your effort ..
i put one picture for all person in database path as name_of_employee.jpg
but every time i run it recognize as unkown
i don't know why .. can you help me ,please ?

@serengil
Copy link
Owner

serengil commented Feb 6, 2020

Could your share your data set? BTW, are face photos cropped?

@DinaIbrahim132
Copy link

thank you very much .. it worked well .. but i want replace webcam into image .. can you help me ,please ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants