d313500942 | ||
---|---|---|
Example | ||
Pod | ||
SampleScreenshots | ||
_Pods.xcodeproj | ||
.gitignore | ||
CONTRIBUTING.md | ||
LICENSE-IMAGE.md | ||
LICENSE.md | ||
ProjectOxfordFace.podspec | ||
README.md |
README.md
Microsoft Face API: iOS Client Library & Sample
This repo contains the iOS client library & sample for the Microsoft Face API, an offering within Microsoft Cognitive Services, formerly known as Project Oxford.
The Client Library
The easiest way to consume the iOS client library is via CocoaPods. To install via Cocoapods
- Install Cocoapods - Follow the getting started guide to install Cocoapods.
- Add the following to your Podfile :
pod 'ProjectOxfordFace'
- Run the command
pod install
to install the latest ProjectOxfordFace pod. - Add
#import <ProjectOxfordFace/MPOFaceSDK.h>
to all files that need to reference the SDK.
The Sample
The sample app demonstrates the use of the Microsoft Face API iOS client library. The sample shows scenarios such as face detection, face verification, and face grouping.
Requirements
iOS must be version 9.0 or higher.
Building and running the sample
The sample app should already have the necessary Pods shipped with it. Open the ProjectOxfordFace.xcworkspace
in Xcode and build.
- First, you must obtain a Face API subscription key by following the instructions on our website.
- Once in Xcode, under the example subdirectory, navigate to the file
MPODemoConstants.h
and insert your subscription key for the Face API - To run the sample app, ensure that the target on top left side of Xcode is selected as
ProjectOxfordFace-Example
and select the play button or select Product > Run on the menu bar - Once the app is launched, click on the buttons to try out the different scenarios.
Microsoft will receive the images you upload and may use them to improve Face API and related services. By submitting an image, you confirm you have consent from everyone in it.
Having issues?
- Make sure you have selected
ProjectOxfordFace-Example
as the target. - Make sure you have included the subscription key in
MPOTestConstants.h
. - Make sure you have opened the
.xcworkspace
file and not the.xcodeproj
file in Xcode. - Make sure you have used the correct
Deployment Team
profile. - Make sure you are running iOS 9.0 or higher
Running and exploring the unit tests
Unit tests that demonstrate various Microsoft Cognitive Services scenarios such as detection, identification, grouping, similarity, verification, and face lists are located at Example/Tests
.
To run the unit tests, first insert your subscription key in MPOTestConstants.h
and then select the test navigator pane in Xcode to display all of the tests which can be run.
Contributing
We welcome contributions. Feel free to file issues and pull requests on the repo and we'll address them as we can. Learn more about how you can help on our Contribution Rules & Guidelines.
You can reach out to us anytime with questions and suggestions using our communities below:
- Support questions: StackOverflow
- Feedback & feature requests: Cognitive Services UserVoice Forum
This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.
Updates
- 8/2016: Library and sample updated for July 2016 Face API changes
License
All Microsoft Cognitive Services SDKs and samples are licensed with the MIT License. For more details, see LICENSE.
Sample images are licensed separately, please refer to LICENSE-IMAGE.
Developer Code of Conduct
Developers using Cognitive Services, including this client library & sample, are expected to follow the “Developer Code of Conduct for Microsoft Cognitive Services”, found at http://go.microsoft.com/fwlink/?LinkId=698895.