This topic describes the details of the face similarity comparison model, including the features, input format, output format, and test data.
- Overview
The face similarity comparison model uses the ResNet50 framework. For more information, see Deep Residual Learning for Image Recognition.
- Input format
The input data must be in the JSON format. It contains the imagea and imageb fields. The value of each field is the image content that is encoded in the Base64 format. An error is returned if an image contains more than one face.
{ "imagea": "Base64-encoded image content" "imageb": "Base64-encoded image content" }
- Output format
The output data must be in the JSON format. The following table describes the fields in the output data.
Field Description Shape Type similarity The similarity between the two faces provided by the imagea and imageb fields. A value of 100 indicates that the two faces are of the same person. A value smaller than 80 indicates that the two faces are not of the same person. [] INT request_id The unique ID of the request. [] STRING success Indicates whether the request was successful. [] BOOL error_code The request error code. [] INT error_msg The request error message. [] STRING { "request_id": "d4e4348a-6101-43d1-9203-dbe8f531****", "success": true, "similarity": 99 }
- Test data
- Face images of the same person: Positive sample A and Positive sample B
- Face image of another person: Negative sample