Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

codeDroid1/faceDetectionCNN

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

4 Commits

Repository files navigation

Face Detection and Face Extraction

Face Detection and Extraction using pretrained CNN model.

with face detection

Face Detection

face-detected

Extracted Face

face-detected

Installation

Download Anaconda

pip install keras
pip install mtcnn
pip install keras_vggface

Usage

def highlight_faces(image_path, faces):
 # display image
 image = plt.imread(image_path)
 plt.imshow(image)
 ax = plt.gca()
 # for each face, draw a rectangle based on coordinates
 for face in faces:
 x, y, width, height = face['box']
 face_border = Rectangle((x, y), width, height,
 fill=False, color='red')
 ax.add_patch(face_border)
 plt.show()

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

MIT

About

Face detection in Python using pretrained CNN model

Topics

Resources

License

Stars

Watchers

Forks

Languages

AltStyle によって変換されたページ (->オリジナル) /