Share via

Azure Face client library for Python Samples

These are code samples that show common scenario operations with the Azure Face client library. The async versions of the samples (the python sample files appended with _async) show asynchronous operations.

Several Azure Face Python SDK samples are available to you in the SDK's GitHub repository. These samples provide example code for additional scenarios commonly encountered while working with Face:

Prerequisites

Setup

  1. Install the Face client library for Python with pip:
pip install azure-ai-vision-face
  1. Clone or download this sample repository
  2. Open the sample folder in Visual Studio Code or your IDE of choice.

Running the samples

  1. Open a terminal window and cd to the directory that the samples are saved in.
  2. Set the environment variables specified in the sample file you wish to run.
  3. Follow the usage described in the file, e.g. python sample_face_detection.py

Next steps

Check out the API reference documentation to learn more about what you can do with the Azure Face client library.