Aim: Using image data, predict the gender and age range of an individual in python. Test the data science model using your own image.
OpenCV
OpenCV is an open-source computer vision and machine learning software library. OpenCV was built to provide a common infrastructure for computer vision application and to accelerate the use of machine perception in commercial products. Being a BSD-licensed product, OpenCV makes it easy for businesses to utilize and modify the code.
Python Library
Deepface is lightweight face recognition and facial attribute analysis framework for python. It is a hybrid face recognition framework wrapping state-of-the-art models.
for installation use the following command:
pip install deepface
All the libraries in this are basically based on Keras and TensorFlow. We can use the feature like Face Recognition, Large scale face recognition, there are also face recognition models available in that. We can do a Facial Attribute analysis also.
Installation process of deepface
importing an image from files and showing it
Using Deepface.analyze library find the gender and approx age of the image, and display image with the age and gender using plt.show command.
Python code: Link
No comments:
Post a Comment