From the course: Code Clinic: Swift

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Solution overview

Solution overview - Swift Tutorial

From the course: Code Clinic: Swift

Start my 1-month free trial

Solution overview

- [Narrator] Here's the overview of my solution for the facial recognition problem. I have a simple app that asks you to pick a photo. And when you do, you can choose one of four pre-selected photos. If you choose the photo and hit Find Faces, then it finds the facial rectangles, face contours, medium lines, eyes, nose, and mouth. It presents those to the user. Stop the app and go over to Xcode, and quickly overview the code, because there are about 170 lines of code in this file. So instead of using a third-party framework, I've opted to go with the Vision framework, because it's built into iOS 11. Before using the Vision framework, I copy images from the application bundle into the Photo Library. The user can then select one of those photos. And then, based on that photo, the user can click the button to find faces within the image. That uses the Vision framework to create a request and a request handler to handle facial data. That data is then sent into the showLandmarks method for…

Contents